Issue with Azure Document intelligence Ai (Foundry tool)

Muhammad Zahid 0 Reputation points
2026-10-28T07:08:17.71+00:00

We are experiencing an issue with Azure OCR when extracting financial statements in tabular format. Figures represented by a dash (-), indicating zero, appear to be skipped, causing the extraction process to incorrectly pick the comparative period's figure instead of the correct current-year value.

Example:

Particulars FY2025 FY2024
Cash and Cash Equivalents - 150,000
-------- -------- --------
Cash and Cash Equivalents - 150,000
Trade Receivables 250,000 200,000
Total Current Assets 250,000 350,000

Here, the dash under FY2025 represents zero. However, when the dash is skipped, the system may incorrectly extract 150,000 instead of 0 for FY2025.

We request that your technical team investigate this issue and advise how Azure OCR can preserve dash symbols as valid table-cell values to prevent incorrect extraction of financial figures.

Kind regards

Azure Document Intelligence in Foundry Tools

1 answer

Sort by: Most helpful
  1. AI answer

    2026-10-28T07:09:08.3833333+00:00

    Treat every table position by its rowIndex and columnIndex, preserve an unrecognized FY2025 cell as NULL, and convert it to zero only when the extracted content or an independent validation confirms a dash—never shift FY2024’s value into the missing cell.

    Azure Document Intelligence has a documented intermittent OCR-stage issue affecting all models in which - can be misrecognized or returned as 1. Custom-model training does not resolve it; Microsoft’s documented mitigation is field-specific post-processing using positional rules, regular expressions, and word confidence scores.^1^ A closely matching financial-table case also reports dashes becoming blank in 2023-and-later API versions.^2^

    Prevent the incorrect column shift

    1. Read tables[].cells[] from the Analyze response.
    2. Build the table using each cell’s rowIndex and columnIndex; do not assign values sequentially based on which OCR tokens were returned.
    3. Initialize every expected table position as NULL.
    4. Apply these financial-field rules:
      • Explicit "-" in a numeric cell → 0.
      • Isolated "1" where the printed document shows a dash or the value has low confidence → flag as a possible dash; do not silently accept it as 1.
      • Missing cell → retain NULL; do not copy the adjacent period.
      • Convert NULL to 0 only when a separate check confirms that the source cell contains a dash—for example, targeted image processing or human review.
    5. Validate totals. In the example, accepting FY2025 as 150,000 would conflict with both its column position and the stated total.

    A minimal coordinate-safe parser looks like this:

    def normalize_table(table, expected_columns):
        grid = {
            (r, c): None
            for r in range(table["rowCount"])
            for c in range(expected_columns)
        }
    
        for cell in table.get("cells", []):
            value = cell.get("content", "").strip()
            grid[(cell["rowIndex"], cell["columnIndex"])] = (
                0 if value == "-" else value or None
            )
    
        return grid  # Missing FY2025 remains None; FY2024 cannot shift left.
    

    For an extracted "1", use the corresponding word-level confidence and source position before substitution. With custom models using API 2024-11-30 (GA), table, row, and cell confidence scores are available; Microsoft recommends reviewing them from table to row to cell.^3^ Low-confidence or missing financial cells should be routed to validation rather than automatically populated.^4^

    Input-side workaround

    For affected PDFs, preprocess only the problematic pages or table regions into clear, high-resolution flattened images before analysis. The matching Q&A case lists enhancing dash visibility as a workaround.^2^ Compare the original-PDF and flattened-image results on a representative test set before changing production processing.

    The same Q&A answer mentions reverting to the 2022 API behavior if feasible. Treat that only as a controlled compatibility test: the current known-issue guidance does not identify an older API as the supported general resolution.

    Escalate for product investigation

    Because this occurs at the OCR stage across models, open an Azure support request and include:

    • Azure region, model ID/type, and API version.
    • Redacted original PDF plus the exact page.
    • Full Analyze JSON showing rowIndex, columnIndex, content, polygons, and confidence.
    • Expected versus actual cell matrix.
    • Whether the dash is omitted, returned as 1, or represented as an empty cell.
    • Results from both the original PDF and a flattened-image test.

    This gives the Document Intelligence team a reproducible sample while the application-side coordinate and validation rules prevent an FY2024 amount from being assigned to FY2025.


    References

    1. Azure Document Intelligence known issues and troubleshooting
    2. Document Intelligence Studio OCR Fails to Recognize Dash/Hyphen in PDF ...
    3. Document Intelligence custom neural model
    4. Interpret and improve accuracy and confidence scores
    AI-generated content may be incorrect. Read our transparency notes for more information.

    Was this answer helpful?

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.