Deterministic citations mean a model can point at a source number but cannot write one. Kepler builds a citation registry from SEC filings and internal documents, runs all arithmetic in deterministic code, and removes uncited figures before the answer reaches the user.
What are deterministic citations in a financial AI system?
Deterministic citations are a design rule in which a language model selects and references a pre-registered fact, while separate code produces the numbers and a post-processing filter deletes any value that cannot be traced to a source. Kepler, a financial research platform, described this architecture at a 2026 AI Engineer session.
The starting point is a constraint finance people already accept. An analyst never shows a portfolio manager a figure that cannot be validated or traced. Kepler's chief executive, Vinoo Ganesh, opened the talk with a sentence of the kind an equity report contains, revenue up 12.4% to a stated total, and pointed out that each part of it has to be correct.
The problem is that large language models are probability machines. Ganesh argues the same randomness that makes them useful for open-ended work makes them unreliable where a number carries liability. Attaching a source after generation does not repair that, because the retrieved passage may be the wrong document and the number inside it may still be the wrong number.
Kepler's answer splits the job three ways. Retrieval finds the document, deterministic code written by humans performs the arithmetic, and a filter checks every figure against a citation registry before the answer is released.
Why retrieved sources are not enough on their own
Plain retrieval-augmented generation fails financial accuracy tests because retrieval can return an irrelevant document or a real document with the wrong figure attached to it, and the model has no reliable way to tell the difference. Ganesh described three recurring failure modes from Kepler's own evaluations.
The first is a wrong source. A search may surface a blog post or third-party opinion page instead of the filing, and the model treats it as evidence. The second is the right source with the wrong number. A figure like 17 in a 10-K could mean 17 million dollars, 17 million yen, 17 billion, or simply page 17, and the year and scale sit in a table header far from the value itself.
The third failure is arithmetic. Models do not compute growth rates, margins or multiples in a way that guarantees accuracy, even when they appear to show working. Kepler moves that work out of the model entirely.
These failures explain why the company treats citation as a property of the data rather than a formatting step applied at the end. A citation that cannot be resolved to a registered fact is treated as an error, not a stylistic gap.
How Kepler builds a citation registry from filings
Kepler pre-processes its document corpus and registers each extractable value as a citation, so that every number the system may later display already carries an identifier, a unit, a scale, a period and a link to its source. The company says it ran this over the full corpus of SEC filings, more than 30 million documents.
Registration is the part that makes later verification cheap. Each citation receives a unique identifier tied to metadata in a deterministic engine, and derived values reference the inputs they were computed from. Kepler also stores a separate display value, so the same fact can be shown in thousands of dollars, in yen, or in another unit without changing the underlying record.
Scale is where transcripts and filings diverge. Ganesh noted that structured data formats are not a complete answer: eXtensible Business Reporting Language, the tagging standard used in US filings, is the usual objection, but he said the tags are incorrect a meaningful share of the time, and internal memos, share drives and mailboxes carry no tags at all.
That is why the registry has to cover private documents as well as public ones. Kepler combines structured storage where the data already has structure with search over the rest, keeping the same citation guarantees across both.
Where models are allowed to act, and where code takes over
The model plans the research and chooses which tools to call, while deterministic software handles every number and every fact that reaches the user. Ganesh described the language model as the planner and the compute layer as the arithmetic.
Consider a question about a company's adjusted EBITDA. The plan has to locate facts across several 10-K filings, check whether an investor presentation or earnings call disclosed something newer, and check whether a restatement changed a prior figure. The model can reason about that sequence and select the right retrieval and computation tools.
What it cannot do is produce the resulting number from its own weights. Each number is an output of code that reads registered inputs, which is why the same query returns the same answer on repeat runs. Ganesh called this an idempotence guarantee: the pipeline is reproducible rather than sampled.
A useful distinction follows from this split. The model contributes judgment about what to look up. The platform contributes the values, their units and their provenance.
Hybrid search, re-ranking and tenant isolation on turbopuffer
Kepler runs retrieval across a namespace in turbopuffer, a vector and full-text search engine, combining embedding-based approximate nearest-neighbour search with BM25 keyword matching, then re-ranking the results before any number reaches the model. Ganesh described both stages at the AI Engineer session.
The retrieval strategy is to search wide and then re-rank. Kepler uses ZeroEntropy embedding models at 1,280 dimensions, pulls back a large candidate set, and applies reciprocal rank fusion to merge the lexical and vector result lists. A cross-encoder then re-scores the merged candidates.
The re-ranking stage is also where conflicting evidence gets handled. An earnings call transcript in which a presenter states a revenue figure may disagree with the 10-K. Ganesh treats that disagreement as useful information rather than a bug, because the two statements are separate facts that an analyst needs to deconflict.
Tenant isolation is enforced on every hit. Kepler re-authorizes each retrieved document in Postgres against the requesting user, and each query builder adds another filter as it runs, so a research desk's private material cannot surface in a colleague's or another firm's results. Only a scoped token issued by the identity provider can create the query, and user and authorization data come from a signed device.
What the filter refused in Kepler's own evaluations
Kepler's citation filter refused 10,981 figures when the system was evaluated against ordinary model output, and Ganesh said about 3,810 of those refused values were straightforwardly incorrect numbers rather than merely untraceable ones. Those figures come from the company's own evaluation and have not been independently reproduced.
The claim matters because the alternative architecture was not a straw man. Ganesh described connecting models such as Claude from Anthropic ChatGPT from OpenAI to a standard vector database and calling the result financial research. In his account, that setup produces numbers that look plausible and fail audit.
Kepler also reports that roughly one third of its citations are derived values, meaning results the model did not compute because deterministic code did the arithmetic. That share is a description of the registry's composition in Kepler's own pipeline, not a general benchmark.
| Layer | Owner | What it produces | Verification |
|---|---|---|---|
| Planning | Language model | Which tools and sources to use | Downstream citation check |
| Retrieval | turbopuffer, BM25 and vectors | Candidate passages | Cross-encoder re-rank, then authorization |
| Arithmetic | Deterministic code | Growth rates, margins, multiples | Recomputed from registered inputs |
| Filter | Post-processing | Final visible answer | Uncited figures removed |
The filter has a deliberate cost. When no registered match exists, the figure is stripped, which makes the platform less inventive than a general assistant. Ganesh was direct that Kepler is a poor fit for marketing copy or open-ended brainstorming.
What the architecture cannot guarantee
Kepler's guarantees cover citation and arithmetic, not investment judgment. Ganesh closed by separating what the platform can promise from what it cannot, and that boundary is the most useful part of the talk for anyone designing a similar system.
The platform can make the model cite numbers rather than write them, verify each citation, push arithmetic to a compute layer, isolate tenants and measure retrieval recall. It cannot turn that into an autonomous fund, and Ganesh said so explicitly rather than letting the audience infer it.
A citation also proves provenance, not correctness of interpretation. A number can be accurately traced to a filing and still be the wrong figure to use for a particular comparison, because scope, period and restatement status are judgment calls. Kepler handles restatements by tracking disclosure timing, but the analyst still decides what the comparison means.
Repair is the fuzzy edge. When a value cannot be traced, Kepler sometimes runs an agentic step to try to find its real source before stripping it. Ganesh declined to describe the details of that repair logic, so its accuracy is not something an outside reader can verify.
FAQ
- What does it mean for a model to cite numbers but not write them? The model chooses which registered fact answers the question and references its identifier, while separate deterministic code supplies the value. A post-processing filter removes any figure whose citation cannot be resolved, so text never carries a model-generated numeral.
- Why does plain RAG fail at numerical accuracy? Retrieval returns passages that may be irrelevant, outdated or missing the table header that gives a value its scale and period. Even with a correct document, the model may still compute a growth rate or margin incorrectly, because arithmetic is not a reliable part of language generation.
- Is XBRL enough to make financial figures machine-readable? No. XBRL, the structured tagging standard in US SEC filings, covers public filings only and is not always correct. Kepler's architecture also has to handle internal documents, presentation decks and transcripts that carry no structured tags.
- Does Kepler work with private documents as well as SEC filings? Yes. Ganesh said the same citation pipeline runs over sources such as SharePoint, Box, OneDrive and Outlook, because most investment decisions rely on internal material as much as on public filings.
- Is Kepler a replacement for an analyst? No. Ganesh said the platform does not create a hedge fund that replaces everyone. It removes the work of extracting figures from filings and moving them into spreadsheets, while interpretation and investment judgment stay with the analyst.
Turning a recorded talk into a written explainer
The architecture above only makes sense because someone explained the layers, the evaluation numbers and the limits out loud. That knowledge often lives in recorded sessions rather than in documentation, where it is hard to search and harder to cite.
If you have explained a system, a workflow or a lesson on video, that recording can become a structured written piece. Skala Blog takes a YouTube URL, transcribes the video, and generates an article draft you can review before publishing.
Related resources for developers building in this space include Crazystack Typescript, a TypeScript learning track from Gustavo Dev Doido, and the Bootcamp do Dev Doido for structured practice on the same stack.
Fork this article
Start a new branch from the same video, shaped your way. You keep the credit; the original keeps the attribution.
A fork in another language is filed as a translation of this article, so the two pages point at each other. You can unlink it later from the editor.
0/240
You are creating
- Format
- For
- Language
- Source
- Your angle
You will be asked to sign in before it is generated.
Buy credits