Trace Integrity for LLM Data Agents: A Vision for Auditable Structured Reasoning in Real-World Systems
Organizations: WAI USA Research Labs
Abstract
Answer accuracy is an insufficient reliability signal for LLM data agents. In structured-data tasks, a benchmark-correct answer can be produced by an invalid trace. This paper introduces Trace Integrity, a deployment reliability criterion for evaluating whether the computation recorded behind an answer is explicit, executable, schema-valid, operator-faithful, replayable, answer-consistent, and auditable. We identify the Structure Gap as the deployment failure mode that makes Trace Integrity necessary: natural-language reasoning and free-form rationales do not reliably specify the operator-level programs required by real-world systems. We operationalize Trace Integrity with execution contracts, structured artifacts that bind user intent to schema elements, operator plans, assumptions, executable queries, verification status, and final-answer linkage. We also introduce CAIT (Correct Answer / Invalid Trace) Rate, which measures how often answer-only evaluation counts computationally unsupported outputs as successes. In an empirical demonstration on BIRD Mini-Dev, Direct SQL, Operation Summary + SQL, and Contract-First SQL achieve answer accuracies of 20%, 22%, and 24%, while their Trace Integrity Pass Rates are 39%, 43%, and 40% and their CAIT Rates remain high at 55%, 59.1%, and 45.8%, showing that answer accuracy, trace validity, and silent-failure risk are distinct evaluation signals. Real-world LLM data agents should, therefore, be evaluated not only by whether their outputs match a reference answer, but by whether those outputs are backed by auditable computation.
Figures & tables
| Dimension | Check | Deployment failure exposed |
| Explicit | The trace records the computational commitments needed to answer the request. | The answer gives a number but does not record the measure, grouping key, filter set, time window, or join path. |
| Executable | The trace contains a query, program, or structured plan that can be run or deterministically checked. | The system stores only a free-text rationale, leaving no executable artifact to validate or replay. |
| Schema-valid | Referenced tables, columns, join keys, and fields exist in the available schema. | The trace binds the request to customer.region when only office_region exists. |
| Operator-faithful | The operations preserve the user’s intended computation. | The trace uses SUM where the request requires a per-customer average, or groups by office rather than customer region. |
| Replayable | Re-execution under the same data snapshot and execution environment yields the same result. | The answer depends on hidden state, unlogged tool output, or an unspecified data snapshot. |
| Answer-consistent | The final response follows from the executed trace. | The query returns region A, but the natural-language response reports region B. |
| Method | Answer Accuracy | Execution Success | Trace Integrity Pass | Answer-Trace Consistency | CAIT Rate |
| Direct SQL | 20.0% | 84.0% | 39.0% | 84.0% | 55.0% |
| Operation Summary + SQL | 22.0% | 83.0% | 43.0% | 67.0% | 59.1% |
| Contract-First SQL | 24.0% | 82.0% | 40.0% | 82.0% | 45.8% |