> ## Knowledge Base Index
> Fetch the complete knowledge base index at: https://support.contracthero.com/sitemap.xml
> Use this file to discover available pages before exploring further.
> Pure-Markdown content can be obtained by appending a '.md' suffix to the content URLs listed in the sitemap (without the trailing slash).

# Optimizing AI Prompts — Get Better Results from Contract Analysis

## Your benefit

ContractHero's AI reads your contracts and fills in data fields automatically -- terms, notice periods, custom fields. How well it works depends directly on how your prompt is written. A clear question tends to deliver better results than a vague instruction. The payoff: less manual correction and more reliable reports.

## How it works

The AI understands three types of prompts. A **clear, precise question** works best:

1. **Ask a question (recommended):** Write your prompt as a direct question.
* Example: *"What is the notice period in this contract?"*
* Example: *"When does the contract term end?"*

2. **Semantic description:** Describe what you're looking for without giving an instruction.
* Example: *"The remaining term of the contract"*

3. **Instruction:** Give the AI a direct command.
* Example: *"Extract the notice period"*

All three approaches work. However, the AI is optimized for question-answer pairs -- questions typically deliver the best results.

**Tips for optimal prompts:**

1. Go to **Settings > Data Fields** (or create a field directly in the contract view)
2. In the prompt field, write a **short, precise question** about the information you want to extract
3. Use terms that actually appear in the contract -- the AI works with the document's language
4. Avoid unnecessary repetition or contradictory information in your prompt

**What you DON'T need to include in the prompt:**

* **List options:** For list fields, the AI automatically recognizes the available values. You don't need to list or mention them.
* **Date format:** The format follows your account settings automatically. No need for "Enter the date in DD.MM.YYYY format."
* **Field type:** The AI already knows whether it's a text, date, or list field.

## Common questions

*Should I write prompts short or detailed?*
Both can be right. Short, precise prompts are ideal. But if you need a very specific value from a complex contract, some additional context can help. Key rule: don't repeat yourself and avoid contradictory information.

*Will my existing prompts still work?*
Yes. The AI processes all three prompt types (questions, descriptions, and instructions). Existing prompts don't need to be rewritten, but questions tend to deliver better results.

*Do I need different prompts for different contract categories?*
Not necessarily. But if you notice a prompt isn't working well for a specific contract type, it can help to create a tailored prompt for that category -- using terms that are common in those contracts.

*What is prompt improvement?*
ContractHero offers a built-in prompt optimization tool directly in the data field. Here's how it works:

1. Open a data field and click the **pencil icon** next to the prompt field
2. The AI analyzes your current prompt and suggests an **improved version**
3. The improved prompt is just a **suggestion** -- your original prompt stays unchanged
4. If you're happy with the suggestion, click **"Update"** to apply it

The prompt improvement tool also catches common mistakes -- for example, if you've listed dropdown options in your prompt or included unnecessary format instructions. In just a few clicks, you get an optimized prompt without needing to understand the technical details.

## Good to know

* The AI is continuously being improved. New OCR technology and enhanced analysis features deliver even more accurate results -- including for tables and scanned documents.
* The "Jump to Source" feature will soon show you exactly where in the document an extracted piece of information comes from.
* If synonyms are used differently across contract types (e.g., "term" vs. "contract duration"), it can help to include multiple terms in your prompt.