llamaIndex - 💡(How to fix) Fix [Feature Request]: Azure Document Intelligence for IRS tax forms (1040 / W-2 / Schedule C/E/K-1)

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
RAW_BUFFERClick to expand / collapse

Feature Description

A production-tested LlamaIndex reader for extracting structured key-value pairs from IRS tax form PDFs using Azure Document Intelligence.

I have already built and open-sourced this: 👉 https://github.com/zavera/llama-index-readers-azure-tax-forms

Implements BaseReader with:

  • load_data(file_path) and load_data_from_bytes([(id, bytes)])
  • Supports: Form 1040, W-2, Schedule C, Schedule E, Schedule K-1, 1065, 1120, 1120-S
  • 4-stage recovery chain: direct → page-split → DPI-reduce → rotation block
  • asyncio.Semaphore gate — prevents 429 throttling under parallel loads
  • Exponential back-off with ±20% jitter, honours Retry-After header
  • Field normalisation for known Azure DI output quirks
  • Form type inference from extracted key names
  • File-bounded audit logger (no PII in stdout)

Requesting this be considered for llama-index-integrations/readers/

Reason

There is currently no LlamaIndex reader for structured IRS tax form extraction. Existing approaches (generic PDF loaders) return raw text without key-value structure, making financial document RAG pipelines unreliable.

Azure Document Intelligence extracts labelled fields (e.g. "Adjusted gross income | 75000") which map directly to LlamaIndex Documents and produce accurate retrieval results for financial queries.

Value of Feature

Financial services, higher education (FAFSA/financial aid), tax preparation, and accounting firms all process IRS tax forms at scale. A structured KV reader enables accurate RAG over financial documents — a high-demand vertical that is currently underserved in the LlamaIndex ecosystem. This implementation is production-tested, MIT licensed (Callisto Tech), includes unit tests, CI, and a sample generator using official IRS templates.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING