Configuration Options
When creating a new Extraction Agent, the schema is the most important part. However, there are a few other options that can significantly impact the extraction process.
Extraction Mode
: The mode of extraction to use. Can be eitherFAST
,BALANCED
,MULTIMODAL
, orPREMIUM
. The default isBALANCED
. You can start here and switch toMULTIMODAL
/PREMIUM
for higher accuracy, if needed.FAST
mode is suitable for simpler documents with no OCR and limited tabular extraction and is the fastest mode.MULTIMODAL
mode is suitable for visually rich documents with a mix of text, tables, and images.PREMIUM
mode does OCR, complex table/header and layout detection and is suitable for documents that require the highest accuracy.System Prompt
: Any additional system level instructions for the extraction agent. Note that you should use the schema descriptions to pass field-level instructions, few-shot examples, formatting instructions, etc.Extraction Target
: Whether to use the schema on a per-page basis or on the entire document. For the per-page mode, the schema is applied to each page of the document and an array of results is returned.
Advanced Options/Extensions
These features are currently available under Advanced Settings
in the UI. These return schema-level metadata in the extraction_metadata
field of the response.
- Citations: Corresponding to every leaf-level field in the schema, this returns the page and verbatim text that the field is extracted from. Use the
ExtractConfig.cite_sources
argument from the SDK to enable this feature. - Reasoning: Corresponding to every leaf-level field in the schema, this returns a brief explanation for the extracted value based on the text provided or an error message in case the text does not contain enough information to extract the field. Use the
ExtractConfig.use_reasoning
argument from the SDK to enable this feature.