π€ AI Summary
This work addresses the lack of auditable construction records in existing code generation models, which hinders error tracing and localized repair. The authors propose a contract-annotated task graph approach that simultaneously outputs code and a responsibility-labeled construction trace, binding each taskβs implementation, provenance, verification evidence, and intervention history. Upon verification failure, a conservative locator maps evidence to specific graph nodes or dependency branches, enabling bounded repair only in affected regions while freezing and reusing the rest. This is the first method to treat responsibility-preserving task graphs as a unified output structure for both code generation and repair, establishing full traceability from decisions to code. Experiments show pass@1 rates of 82.5β83.0% on APPS and 75.0β82.0% on ClassEval; auditing reveals a task-to-code trace coverage of 0.9725, with 26 of 60 failure cases correctly localized and 17 successfully repaired to pass validation.
π Abstract
Code generators return programs, but typically do not preserve the construction record needed to connect a failure to the decision that produced the affected code or to delimit a justified repair. We present AuditCoder, which treats the program and an auditable construction trace as joint outputs. Before code generation, a contract-annotated task graph assigns stable responsibility identities that remain attached to each commitment, its owned implementation, provenance, validation evidence, and intervention history. When validation fails, a conservative locator maps heterogeneous evidence to a node or dependency branch---or abstains---and bounded repair regenerates only that region while reusing the frozen complement. On APPS, \method{} reaches $82.5$--$83.0\%$ \texttt{pass@1}, recovering much of the loss caused by unrepaired graph decomposition but trailing AgentCoder by $7.5$--$8.5$ points. On ClassEval, it reaches $75.0$--$82.0\%$, outperforming CoT + retry while remaining below AgentCoder. A separate audit of 200 APPS records yields $0.9725$ task-macro decision--code trace coverage; the locator identifies an evidence-supported node or branch for 26 of 60 failures, and 17 of those localized repairs pass. For tasks with stable, locally testable boundaries, the graph functions not only as a decomposition structure but also as a persistent index for validation and repair.