This prompt is designed for data engineers, compliance analysts, and audit teams who need to extract footnotes and annotations from tables embedded in financial filings, regulatory reports, and legal documents. Footnotes in these documents often qualify cell values, disclose assumptions, indicate restatements, or reference external sources. Missing a footnote connection can lead to misinterpretation of the data and downstream errors in reports, dashboards, and automated decisions. Use this prompt when you have already extracted the table body and need to capture the footnote layer: the marker symbols, the full footnote text, and the precise mapping back to the cells they annotate. This prompt assumes the table content and surrounding footnote text are available as structured or semi-structured text input. It does not perform OCR or initial table extraction.
Prompt
Footnote and Annotation Extraction from Tables Prompt

When to Use This Prompt
Identify the right conditions, inputs, and users for the footnote extraction prompt, and recognize when it will fail.
The ideal input is a pre-extracted table structure—such as a JSON array of rows and cells—paired with the full text block of footnotes located below or beside the table. The prompt works best when footnote markers are consistent (e.g., superscript numbers, letters, or symbols like *, †, ‡) and the footnote text follows a predictable pattern of marker followed by explanation. Do not use this prompt when the table extraction itself is unreliable, when footnotes are embedded as images without OCR, or when the document lacks explicit marker-to-text linkage. In those cases, you need upstream table extraction, OCR, or document structure parsing before this prompt can add value. This prompt is also not a substitute for human review in high-stakes filings where a missed footnote could have material regulatory or financial consequences.
Before deploying this prompt, verify that your pipeline can isolate the table region and the footnote region as separate text blocks. If footnotes are interleaved with body text or split across page breaks, you'll need a pre-processing step to reassemble them. After running the prompt, validate the output by checking that every footnote marker in the table has a corresponding entry in the extracted annotations, and that no footnote text is mapped to a non-existent marker. For regulated use cases, route low-confidence mappings to a human reviewer and log the prompt's input, output, and validation results for auditability. The next section provides the copy-ready prompt template you can adapt for your document processing pipeline.
Use Case Fit
Where the Footnote and Annotation Extraction prompt works reliably and where it introduces unacceptable risk. Use these cards to decide if this prompt fits your document pipeline before committing engineering time.
Good Fit: Regulatory Filings with Explicit Markers
Use when: documents contain superscript numbers, asterisks, daggers, or bracketed markers that map unambiguously to footnote text below the table. Why it works: the model can trace explicit visual cues to corresponding text blocks without inferring relationships. Guardrail: pre-process PDFs to preserve superscript positioning and character-level bounding boxes before sending to the model.
Bad Fit: Implicit Qualifiers Without Markers
Avoid when: tables use parenthetical qualifiers, color coding, or inline caveats without explicit footnote markers. Risk: the model invents marker-to-text mappings or misses qualifications entirely because no visual anchor exists. Guardrail: route documents without explicit markers to a separate clause-aware extraction prompt that treats qualifiers as inline metadata rather than footnotes.
Required Input: Bounding Box Annotations
What to watch: sending raw text without spatial information forces the model to guess which footnote belongs to which cell. Guardrail: always include cell coordinates, page position data, or visual crop references alongside extracted text. The prompt should receive structured table data with spatial metadata, not a plain text dump.
Operational Risk: Multi-Page Footnote Continuation
Risk: footnotes that span page breaks may be truncated or misattributed when pages are processed independently. Guardrail: run a multi-page table continuation detection prompt first to reassemble the full table and footnote block before extraction. Validate that every marker in the table has a corresponding footnote in the assembled text.
Operational Risk: Ambiguous Marker Reuse
Risk: documents that reuse the same marker symbol across multiple tables or reset numbering per section cause cross-table contamination. Guardrail: scope extraction to one table at a time and pass explicit table boundaries. Add a post-extraction validation step that checks every mapped footnote falls within the same page range as its parent table.
Bad Fit: Handwritten or Stamped Annotations
Avoid when: footnotes are handwritten margin notes, rubber stamps, or image-only callouts without OCR-friendly text. Risk: the model hallucinates footnote content from visual patterns or ignores non-text annotations entirely. Guardrail: route image-heavy documents through a scanned document OCR cleanup prompt first, and flag any annotation regions that fail OCR confidence thresholds for human review.
Copy-Ready Prompt Template
A ready-to-use prompt for extracting footnotes and annotations from tables, mapping markers to cells, and outputting a linked annotation structure.
This prompt template is designed to extract footnote markers and their corresponding annotation text from tables embedded in financial, regulatory, or technical documents. It goes beyond simple text extraction by mapping each marker (e.g., superscript numbers, asterisks, daggers) to the specific table cell it annotates, then linking that marker to the full footnote text found elsewhere on the page or in a dedicated notes section. The output is a structured, auditable record that prevents the common failure mode of losing qualifying information when tables are ingested into databases or analytics pipelines.
textYou are an expert document analyst specializing in financial and regulatory table extraction. Your task is to extract all footnotes and annotations from the provided table, map each marker to its source cell, and link it to the full annotation text. ## INPUT Table image or structured text: [TABLE_DATA] Surrounding page text or footnote section: [PAGE_CONTEXT] ## INSTRUCTIONS 1. Identify every footnote marker within the table cells (e.g., superscript numbers, letters, asterisks, daggers, or other symbols). 2. For each marker, record the exact cell location using row and column headers or a grid coordinate (e.g., "Row 3, Column '2023 Revenue'"). 3. Locate the corresponding full annotation text in [PAGE_CONTEXT]. Match markers precisely; do not guess. 4. If a marker's annotation cannot be found in [PAGE_CONTEXT], flag it as "unresolved" with a confidence score of 0. 5. Classify each annotation by type: [ANNOTATION_TYPES], e.g., "qualification", "assumption", "restatement", "definition", "source", "other". 6. Do not paraphrase or summarize the annotation text. Extract it verbatim. ## OUTPUT_SCHEMA Return a single JSON object with the following structure: { "table_identifier": "string, a unique label for the table (e.g., 'Table 3: Revenue by Segment')", "extraction_confidence": "number between 0 and 1, overall confidence in the extraction", "annotations": [ { "marker": "string, the exact marker symbol or text (e.g., '1', '*', '†')", "cell_location": { "row_index": "number, 0-based row index", "column_index": "number, 0-based column index", "row_header": "string or null, the row label if available", "column_header": "string or null, the column label if available" }, "annotation_text": "string, the verbatim footnote text", "annotation_type": "string, one of the types listed in [ANNOTATION_TYPES]", "is_resolved": "boolean, true if the annotation was found in [PAGE_CONTEXT]", "confidence": "number between 0 and 1, confidence in this specific annotation mapping" } ], "unresolved_markers": [ { "marker": "string", "cell_location": { "row_index": "number", "column_index": "number", "row_header": "string or null", "column_header": "string or null" }, "reason": "string, brief explanation of why it could not be resolved" } ] } ## CONSTRAINTS - Do not invent footnote text. If the annotation is not in [PAGE_CONTEXT], mark it as unresolved. - Preserve the exact wording, punctuation, and formatting of the annotation text. - If a single marker references multiple annotations (e.g., '1,2'), create a separate entry for each. - If the table has no footnotes, return an empty annotations array and set extraction_confidence to 1.
To adapt this prompt for your pipeline, replace the square-bracket placeholders with actual data before each inference call. [TABLE_DATA] should contain the table in a structured format (Markdown, HTML, or a cropped image passed to a multimodal model). [PAGE_CONTEXT] must include the full text of the page or the dedicated 'Notes to Financial Statements' section where the footnote text resides; incomplete context is the primary cause of unresolved markers. [ANNOTATION_TYPES] should be customized to your domain—a financial analyst might use 'accounting policy', 'restatement', and 'estimate uncertainty', while a clinical reviewer might use 'exclusion criterion', 'adverse event', and 'protocol deviation'. After extraction, always run a validation step that checks for orphaned markers and compares the count of extracted annotations against the count of markers visible in the source table.
Prompt Variables
Inputs the prompt needs to work reliably. Validate each before sending.
| Placeholder | Purpose | Example | Validation Notes |
|---|---|---|---|
[TABLE_CONTEXT] | Full page text or OCR output surrounding the target table | Page 47 of 10-K filing with preceding paragraph about revenue recognition | Must contain the table body and at least 200 characters of surrounding text. Null or empty input should abort before model call. |
[TABLE_MARKUP] | Structured representation of the table with cell coordinates | JSON grid with row/col indices, cell text, and bounding boxes from PDF parser | Validate that row count and column count are consistent. Reject if cell count is zero or if merged-cell spans create alignment gaps. |
[FOOTNOTE_REGION] | Text block below or beside the table containing footnote definitions | Text starting with '1 Includes restated...' through end of footnote section | Must be non-empty. If no footnote region detected, set to null and skip extraction rather than hallucinating footnotes from body text. |
[MARKER_PATTERN] | Regex or symbol set used to identify footnote markers in cells | Superscript digits, asterisks, daggers, or bracketed numbers like [a] [1] | Default to common patterns: superscript digits, *, †, ‡, §, ¶, bracketed alphanumerics. Allow override for domain-specific conventions. |
[OUTPUT_SCHEMA] | Target JSON schema for the linked annotation structure | Array of {cell_ref, marker, footnote_text, confidence} objects | Validate schema before prompt assembly. Reject if required fields are missing or if schema allows unlinked footnote text without cell references. |
[CONFIDENCE_THRESHOLD] | Minimum confidence score for automatic acceptance of a marker-to-footnote link | 0.85 | Must be a float between 0.0 and 1.0. Links below threshold should route to human review queue with the cell image crop and candidate footnote text. |
[DOCUMENT_SECTION_ID] | Unique identifier for the source document section to enable traceability | filing-2025-q3-10k-note-12-table-3 | Must be non-empty and unique within the batch. Used to namespace cell references and prevent cross-document footnote collisions in downstream audit logs. |
Implementation Harness Notes
How to wire the footnote extraction prompt into a production document pipeline with validation, retries, and human review gates.
This prompt is designed as a single step in a larger table extraction pipeline. It assumes you have already isolated a table region from a PDF page and extracted its cell-level content with positional metadata. The prompt takes that structured table data plus the surrounding page text as input and returns a linked annotation structure. Do not send raw PDF bytes or OCR text dumps directly to this prompt—it requires pre-parsed table cells with row/column coordinates and marker positions to function correctly.
Wire the prompt into your pipeline after table cell extraction and before data ingestion. The input should include the full table grid with cell text and coordinates, plus a text buffer of 200-300 words above and below the table to capture footnotes that may appear outside the table boundary. Validate the output against three checks before accepting it: (1) every footnote marker found in table cells must have a corresponding entry in the annotations array, (2) no annotation should reference a marker that does not appear in the table, and (3) each annotation must include a non-empty source_text field that can be traced back to the input context. If any check fails, retry once with the validation errors appended to the prompt as feedback. If the retry also fails, route the table to a human review queue with the original table image crop and the partial extraction results.
For model selection, use a model with strong instruction-following and structured output capabilities. GPT-4o and Claude 3.5 Sonnet both handle the multi-step reasoning required to match superscript markers, roman numerals, asterisks, and other footnote symbols to their definitions. Set temperature to 0 or near-zero to minimize marker mismatches. If your pipeline processes high-volume financial filings, consider caching the prompt prefix that contains the output schema and instructions, as it will remain static across thousands of table extractions. Log every extraction with the input table ID, output annotation count, validation pass/fail status, and any human review decisions for auditability. For regulated documents, retain the raw model response and validation report alongside the final structured output.
Expected Output Contract
Defines the JSON schema for the extracted footnote and annotation structure. Each field includes the expected data type, whether it is required, and a concrete validation rule that can be implemented in an application harness.
| Field or Element | Type or Format | Required | Validation Rule |
|---|---|---|---|
annotations | array | Schema check: root must be an array. Parse check: must not be empty if [INPUT] contains any footnote markers. | |
annotations[].marker | string | Regex check: must match the marker pattern found in the source document (e.g., '^[a-z]$', '^\d+$', '^[*†‡]'). Must not be null or empty. | |
annotations[].marker_location | object | Schema check: must contain 'page', 'row_index', and 'column_index' fields. 'row_index' and 'column_index' must be non-negative integers. | |
annotations[].annotation_text | string | Content check: must not be an empty string. Length check: should be greater than 5 characters. Source grounding check: text must be a verbatim or near-verbatim match for the footnote text in [INPUT]. | |
annotations[].annotation_location | object | Schema check: must contain 'page' (integer) and 'bounding_box' (object with x, y, width, height). 'page' must be a positive integer. | |
annotations[].linked_cells | array | Schema check: each item must be an object with 'row_index' and 'column_index' (integers). Parse check: array must not be empty; each marker must link to at least one cell. | |
annotations[].confidence | number | Range check: must be a float between 0.0 and 1.0. If null, the application should treat it as 1.0. If below 0.8, route to human review. | |
annotations[].qualifies_value | boolean | Type check: must be a boolean. Logic check: if true, the annotation_text should contain language that modifies the cell value (e.g., 'restated', 'as adjusted'). |
Common Failure Modes
Footnote extraction fails silently and often. These are the most common production failure modes and the specific guardrails that catch them before downstream systems ingest broken data.
Footnote Marker Not Detected
What to watch: Superscript symbols, asterisks, daggers, and numeric markers are missed by the model, especially when they are small, faint, or placed near cell borders. The footnote text is extracted but orphaned with no cell mapping. Guardrail: Post-extraction reconciliation that counts extracted markers against extracted footnote texts. Flag any footnote text with zero linked cells and any cell containing a marker character that has no corresponding footnote entry.
Marker-to-Cell Misattribution
What to watch: The model links a footnote to the wrong row or column, especially in dense tables where markers appear close together or when a footnote applies to an entire column header rather than a single cell. Guardrail: Require the model to output bounding-box or positional evidence for each marker-to-cell link. Run a spatial proximity check: if a marker is closer to a different cell than the one claimed, route to human review.
Multi-Marker Collision on One Cell
What to watch: A single cell contains multiple footnote markers (e.g., "123.4ab") but the model extracts only one or concatenates footnote texts incorrectly. Guardrail: Validate that the count of distinct markers extracted from a cell matches the count of footnote texts linked to that cell. If counts diverge, flag the cell for re-extraction with explicit multi-marker instructions.
Footnote Text Truncation at Page Break
What to watch: Footnote text that continues onto the next page is cut off mid-sentence. The model treats the page boundary as the end of the footnote. Guardrail: Check whether any extracted footnote text ends without sentence-terminating punctuation and whether the next page begins with lowercase text that appears to continue a footnote. Run a continuation-detection pass before finalizing the annotation structure.
Footnote Belonging to Entire Row or Column Ignored
What to watch: A footnote marker placed on a column header or row label that qualifies every value in that row or column is mapped only to the header cell, not propagated to the affected data cells. Guardrail: Include a propagation rule in the prompt: when a marker appears on a header, explicitly link the footnote to all data cells in that row or column. Validate by checking that header-linked footnotes appear in the annotation list for every cell under that header.
Hallucinated Footnote Content
What to watch: The model generates plausible-sounding footnote text that does not appear in the source document, especially when the table references concepts that imply a footnote should exist. Guardrail: Require verbatim extraction with character-level fidelity. Run a string-containment check: every extracted footnote text must be findable in the source page text. Flag any footnote that cannot be located in the original document for human review.
Evaluation Rubric
Score each dimension on a pass/fail or numeric scale before shipping the footnote extraction prompt. Run these tests against a golden set of 10-15 annotated table pages containing footnotes, asterisks, daggers, and parenthetical qualifiers.
| Criterion | Pass Standard | Failure Signal | Test Method |
|---|---|---|---|
Footnote Marker Detection | All footnote markers (asterisk, dagger, superscript number, superscript letter) in table cells are identified with zero false positives on punctuation that is not a footnote marker. | Markers missed entirely; regular punctuation (commas, periods in numbers) incorrectly flagged as footnote markers. | Run against 10 tables with known marker positions. Compare detected marker count and positions to ground truth. Require precision >= 0.98 and recall >= 0.95. |
Marker-to-Cell Mapping | Each detected marker is correctly mapped to the exact cell (row index, column index) where it appears. No marker is assigned to an adjacent or header cell. | Marker assigned to wrong row or column; marker assigned to header when it belongs to data cell; one marker mapped to multiple cells. | For each marker in ground truth, verify the returned [row_index] and [column_index] match. Require exact match rate >= 0.97. |
Footnote Text Extraction | Full footnote text is extracted for each marker, including multi-sentence footnotes and footnotes that wrap across lines. No truncation at line breaks. | Footnote text cut off mid-sentence; only first line captured; footnote text from wrong marker extracted; table body text incorrectly treated as footnote. | Compare extracted footnote text strings to ground truth using normalized edit distance. Require character-level accuracy >= 0.95 per footnote. |
Footnote Location Grounding | Each footnote's source location in the document is cited with page number and approximate region (below table, end of page, end of document). | Footnote text extracted but source location missing or wrong page cited; footnote attributed to wrong table when multiple tables appear on one page. | Verify [source_page] and [source_region] fields against annotated ground truth. Require page accuracy >= 0.98 and region label match >= 0.90. |
Multi-Marker Disambiguation | When a cell contains multiple footnote markers (e.g., value has both asterisk and dagger), each marker is separately identified and linked to its distinct footnote text. | Multiple markers in one cell treated as single marker; footnote texts concatenated into one blob; markers split incorrectly across adjacent cells. | Test on 5+ tables with multi-marker cells. Require per-marker extraction accuracy >= 0.95 and correct one-to-one marker-to-text linkage for all markers in multi-marker cells. |
Null Handling for Unmarked Cells | Cells without footnote markers return null or empty array for the footnote field. No hallucinated markers or footnote text generated for clean cells. | Footnote text invented for cells with no marker; marker hallucinated on blank cells; null returned as string 'null' instead of JSON null. | Count false positive footnote assignments across 200+ unmarked cells in test set. Require false positive rate = 0. Audit null type representation in JSON output. |
Output Schema Compliance | Output strictly matches the defined [OUTPUT_SCHEMA] with all required fields present, correct types, and no extra top-level keys. Array of footnote objects with marker, cell_location, footnote_text, source_page, source_region. | Missing required fields; footnote_text as object instead of string; cell_location missing row or column; extra undocumented fields in output; array wrapped in unnecessary object. | Validate output against JSON Schema for every test case. Require 100% schema compliance. Flag any output that fails structural validation for repair or retry. |
Cross-Reference Consistency | When the same footnote marker appears in multiple cells (e.g., same dagger on several rows), all cells referencing that marker link to the same footnote text object or ID. No duplicated footnote text entries. | Same footnote text duplicated for each cell reference; inconsistent footnote text across cells sharing same marker; missing cross-reference linkage. | For tables with reused markers, verify that all cells with marker X point to a single canonical footnote entry. Require deduplication accuracy >= 0.98 and text consistency across references. |
Enabling Efficiency, Speed & Accuracy
Intelligent Analysis, Decision & Execution
We build AI systems for teams that need search across company data, workflow automation across tools, or AI features inside products and internal software.
Talk to Us
Search across company data
Give teams answers from docs, tickets, runbooks, and product data with sources and permissions.
Useful when people spend too long searching or get different answers from different systems.

Automate internal workflows
Use AI to route work, draft outputs, trigger actions, and keep approvals and logs in place.
Useful when repetitive work moves across multiple tools and teams.

Add AI to products and internal tools
Build assistants, guided actions, or decision support into the software your team or customers already use.
Useful when AI needs to be part of the product, not a separate tool.
Adapt This Prompt
How to adapt
Start with the base prompt and a single-page table sample. Use a frontier model (GPT-4o, Claude 3.5 Sonnet) with default temperature. Focus on getting the footnote-to-cell mapping correct before adding schema enforcement.
Simplify the output schema to:
json{ "footnotes": [ { "marker": "[MARKER]", "text": "[FOOTNOTE_TEXT]", "linked_cells": ["[CELL_REFERENCE]"] } ] }
Watch for
- Markers that appear in multiple cells but the model only links to one
- Footnotes without visible markers in the table body
- Superscript detection failures when markers are rendered as special characters
- Model inventing footnote text for markers it cannot locate on the page

About the author
Prasad Kumkar
CEO & MD, Inference Systems
Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.
His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.
Partnered with leading AI, data, and software stack.
How We Work
Custom AI workflows for your Business
One-fit-all AI don't work for modern businesses. At Inferensys, we aim to understand your business & custom requirements; which we use to define most efficient agentic workflows, the data, and the tools for your business.
01
Review the use case
We understand the task, the users, and where AI can actually help.
Read more02
Pick the right approach
We define what needs search, automation, or product integration.
Read more03
Build the first useful version
We implement the part that proves the value first.
Read more04
Improve from there
We add the checks and visibility needed to keep it useful.
Read moreThe first call is a practical review of your use case and the right next step.
Talk to Us