Skip to content

Document AI · Verifiable answers · SIH 2026 prototype

Stratum

An offline document-intelligence workbench that turns reports, spreadsheets and scanned pages into cited facts, reviewable answers and parliamentary reply drafts.

STRATUM arcade cover: a report page connects a highlighted evidence passage to a cited answer.
Conceptual project artwork, generated for this portfolio.

Document answers need more than a plausible paragraph

Annual reports, production statistics, spreadsheets, scanned directories and past parliamentary replies mix prose with exact values. A general chat answer can sound right while losing the unit, period or source cell behind a figure. Stratum is built around a stricter rule: a generated number should be traceable to evidence that a person can inspect.

The project was built for the Smart India Hackathon 2026 problem from CMPDI and Coal India. It runs as a local workbench with open-weight models on the operator’s machine. A related StratumOS repository offers a browser-based demonstration using a fixed sample library and hosted models, so that public demo should not be confused with the local deployment.

The ingestion pipeline separates evidence from facts

Stratum turns PDFs, spreadsheets and scanned pages into evidence records such as pages, tables, cells and bounding boxes. It can then extract facts with a value, unit, period and a pointer back to where the value came from. OCR and local vision support image-only pages and difficult scans.

That separation makes an answer easier to audit. A reader can click a number and return to the source page or cell, see which checks it passed, and review a flagged fact before it is used in an answer.

Models classify the request, while code protects the values

One of the strongest architecture choices is that the model maps a question to a structured query intent instead of writing SQL or returning numeric values from its own memory. The backend turns that intent into a parameterized lookup. For tables, the model can identify the relevant column or period, while code copies the actual digits from source cells.

A number guard checks generated text against the evidence. Validation covers units, plausible ranges, totals, stated growth, year-on-year changes and provisional versus final values. A failed check goes to a review queue with a reason, rather than quietly passing into the final answer.

  • The reply builder drafts structured answers for parts of a Lok Sabha or Rajya Sabha question and can produce annexure tables in a Word document.
  • Reports can include charts and source citations. Topic views summarize themes across the document library.

Measure correctness with denominators, not a green badge

The project includes a hand-checked gold set and tracks extraction exact match, routing accuracy, numeric correctness, citation correctness, unsupported-number rate and automation percentage. Each metric is paired with a denominator so a small test set does not look like a universal guarantee.

Stratum is still a prototype. Its checks reduce particular failure modes, but they do not establish that every extracted fact is correct or that every generated parliamentary reply is ready to submit. A domain expert still needs to review evidence, calculations and the final document.

INSPECT THE IMPLEMENTATION

Read the code and project notes

The details above describe the public repository and project status as reviewed for this portfolio. Follow the source to inspect the implementation, setup instructions and current limitations.

Stratum source, evaluation and design notes
PythonFastAPIDeepSeek HarnessQwenSQLite