extract_from_submittal
Extracts text, structured fields, and tables from PDF submittals, returning confident, sourced data. Handles failures with actionable errors and partial results with warnings.
Instructions
Extract text, structured fields, and tables from a PDF submittal.
Returns consistent structured output with confidence and provenance.
On failure returns actionable error message; on partial failure (e.g. table
extraction fails) returns best-effort text and warnings. Output is kept
minimal: text_summary is provided when text is long; use full text when needed.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | both | |
| pdf_path | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | No | ||
| error | No | Actionable error message when extraction fails. Null on success. | |
| fields | No | ||
| tables | No | Extracted tables (if any). Empty or None when table extraction fails (fallback: text). | |
| metadata | Yes | ||
| warnings | No | Actionable warnings (e.g. table extraction failed, using text fallback). | |
| confidence | No | Overall extraction confidence (0.0-1.0). Lower when fallbacks or warnings apply. | |
| provenance | Yes | ||
| executed_at | Yes | ||
| text_summary | No | Truncated text preview (~500 chars) when full text is large; avoids dumping huge content into chat. | |
| text_truncated | No | True if full text was truncated; use expand_text option to get full content. |