AI extract.ai
Extract structured data from each input row using an AI model. Define the desired fields with output, or reuse a saved definition with model_id.
Use AI to extract meaningful structured data. extract.ai can be used recipe-first, where the output schema is defined in the recipe, or model-first, where a saved extract.ai model is called by model_id.
info
For saved extract.ai models, this is the preferred calling pattern compared with using extract.custom.
Parameters
| Name | Description | Accepted Values | Default | Required |
|---|---|---|---|---|
| I/O | ||||
input | Input column name, column index, or list of columns supplied together as DATA for each row. If omitted, all dataframe columns are supplied. | array, null | null | No |
output | Desired extraction. Use an object keyed by output column name for structured fields, a string for one prompted value, or an array of field names/definitions. Each field may use the schema options below. | string, array, object, null | null | No |
| Options | ||||
record_examples | Whole-record examples. Each example has a separate input value or record and the complete expected output record. Optional name and notes provide model-visible context. Use {name: ..., notes: ..., input: ..., output: ...}. Omitted nullable output fields are completed with null. Required non-null nested properties must be supplied. This differs from examples nested under one output field, which teach only that field. | array, object, null | null | No |
web_search | Enable OpenAI Responses web search; the model decides when searching helps. When true, every row also receives web_search_sources: a deduplicated list of {title, url} objects in source order, or an empty list when no source was used. This reserved column is automatic. Requires protocol responses. Defaults to false. | boolean | false | No |
instructions | Additional guidance applied to every input row. Use this for decision rules, evidence priorities, normalization requirements, or other behavior that applies to the complete extraction. | string, array, null | null | No |
| Formatting | ||||
output_format | How extracted fields are written. columns writes one dataframe column per field (default); dictionary keeps one object; concatenate joins fields into one string using char. | string, null; one of:
| null | No |
char | Separator used only when output_format is concatenate. Defaults to comma-space. | string | ", " | No |
| Execution | ||||
threads | Maximum number of row-level requests sent in parallel. The configured default is 32. | integer | — | No |
timeout | Maximum seconds for one HTTP attempt. The configured default is 12; deadline can end the overall call sooner. | number | — | No |
deadline | Total seconds allowed for the entire wrangle call, including queued work, retries, and backoff. The configured default is 15. | number | — | No |
| Errors | ||||
retries | Number of additional attempts after a retryable failure. The configured default is 1. Backoff and request timeouts remain bounded by deadline. | integer | — | No |
| Details | ||||
api_key | OpenAI API key used for this wrangle, normally supplied through a recipe variable. | string |