Prompt writing tips

To achieve the best field extraction quality, you may need to add your own custom fields and/or adjust the description of certain fields.

Our interface is designed to make your interaction with the tool as simple as possible: just explain what you expect, and the tool will apply your instructions to the relevant extraction template.

Talk to the tool like an assistant

Use natural, complete sentences instead of short keywords. For example, instead of writing just total price, say: Add up the prices from all line items.

Don’t hesitate to share your business expertise: supplier lists, synonyms for the same value, typical field positions on your documents, or specific rules like: codes always start with the letter M, etc.

Also define general rules to handle edge cases

Service or product lines may appear twice in a row. They must be extracted separately, even if they look very similar. Every visible line must be extracted, including duplicates.

Each extracted line must include a price. Do not extract lines without a price.

Extract only billing lines. These refer to freight services for international shipments. Each line must always include a label and a price. Do not include headers or totals.

Always use the same units and currency format for amounts and prices.

Add examples

Examples significantly improve extraction quality and help format the output to your needs.

Field name: Service or product description

Description: For example: “Pre-carriage (excl. tax)”, “Relocation fees”, “Export handling/documentation charges”, “Ocean freight”, “AMS/ACI security fees”, “Fuel surcharge – pre-carriage”, “BUC – Bunker charge”, etc. Provide the full label including units and amounts.

Format: Text


Field name: Transport reference

Description: On invoices, it’s a 9-digit number starting with 61, located at the end. On credit notes, it appears after the “page 1” number, e.g., “41A0234141”, “21A0620427”, “610156703”.

Format: Text

Avoid common errors

If the tool encounters ambiguities, provide clear instructions.

Field name: Net amount (excl. tax) per line

Description: If multiple amounts appear on the line, extract the highest one. If multiple currencies are present, prioritize euros (EUR, €).

Format: Price


Field name: Recipient address

Description: If there are multiple addresses, use the one related to the transport reference with the greatest distance in km, or otherwise the last one listed. If the same address applies to multiple lines, repeat it for each sub-line. This field is rarely empty.

Format: Text


Field name: Document date

Description: Even in French documents, the date may follow the US format (MM/DD/YYYY). Be careful not to confuse the month and day.

Format: Date

Leverage the tool's intelligence

The tool can enrich, validate, and reformat extracted data automatically.

Field name: Issuing country

Description: Provide the country code using ISO 3166 standard.

Format: Text


Field name: Product category

Description: Categorize the product using the following options: fruits and vegetables, grains and legumes, dairy products, meats, fish and seafood, fats and oils, sweet products, salt, water, others.

Format: Text


Field name: Accounting category

Description: Specify if it’s fixed expenses, variable costs, salaries, machine maintenance, bank fees, taxes, insurance, subscriptions, or local charges.

Format: Text


Field name: Airport code

Description: Provide the ICAO code for the mentioned airport.

Format: Text


Field name: Lease transfer conditions summary

Description: Summarize in about 20 words the conditions for transferring the lease to a third party, if applicable.

Format: Text

Additional tips

AI doesn’t like blanks

Models tend to try and fill in everything. If you want to ignore certain lines (e.g., annexes), it’s better to give a clear instruction like: Return “Annex” rather than Do not extract.

Better to categorize than exclude

If an invoice includes line items, summaries or annexes that you don't want to use, it’s more effective to extract everything and add a multi-option categorization field such as: Invoice line, Subtotal line, Annex line, Summary line, Estimate line, etc., so you can filter results easily in your system.

Last updated

Was this helpful?