TRANSMISSION // 2612.01657v1

Could software be managed by its specification, not its code?

Source published

A feasibility study turns written rules into a graph and contracts for AI coding agents. Small tests suggest the workflow is possible, but broad maintenance benefits remain unproven.

AI-generated conceptual illustration for Could software be managed by its specification, not its code?
AI-generated conceptual illustration; not documentary evidence.

A code diff shows which lines changed, but not always which rule or behavior those lines represent. Henry Yeung’s preprint tests a different approach: organize a project’s rules in a graph, generate module contracts from it, and have AI agents write or update code from those contracts. Results from two rule-based test beds are mixed and limited; they do not establish that the approach is generally cheaper, safer, or easier to use.

From rules to code—and back to rules

When software changes, developers commonly review a diff: a list of added, removed, or edited lines. That can be hard to interpret when the important question is not “what text moved?” but “which requirement changed, and what parts of the program depend on it?”

Henry Yeung’s feasibility study explores whether a project could manage its intended behavior directly. The proposed chain is specification → graph → contracts → code. A rulebook and human decisions are turned into a typed knowledge graph—a structured map of rules, entities, states, actions, and their connections. The graph is built with help from an AI model and human review, not by a fully automatic or purely mechanical conversion. The paper reports more than ten rulings to address ambiguities or gaps; some decisions remain provisional or unresolved.

A script generates contracts describing each software module’s interfaces and behavior. Separate coding agents implement modules from those contracts, and rule tests check the results. For a proposed change, the graph can identify rules and modules that the workflow treats as affected. The goal is an “addressable” record of the change, linked to logic rather than just lines of code. The paper does not claim these graph or contract diffs are shorter than ordinary code diffs; in the examples, they are longer.

Two rule-based test beds

The main test bed was a rules engine for a commercial board game, covering 374 extracted rules and 116 rule tests. In the contract-based first-generation experiment, coders passed 86 of 116 tests before interface information was added to the graph, and 113 afterward. These figures describe coders working from contracts; they should not be read as a general comparison of cloud-model performance. Separately, an open-weight model, DeepSeek V4 Flash, passed 94 tests in one attempt and 103 after a repair loop that did not use the test suite.

The conventional first-generation comparison had an important asymmetry. Without interface names, the conventional coder passed none of the tests, in part because its module names could not be imported by the tests. When given an interface list taken from the graph’s API information, it passed 87 of 116. That helps show why explicit interfaces mattered in this setup, but the interface-list arm was not independent of information supplied by the graph.

For maintenance, researchers tested four rule changes. Success meant matching the reference patch’s exact pattern of passing and failing tests on 121 tests, including new acceptance tests—not simply passing the original 116. Contract-diff patching matched that pattern in all four cases. So did the full-source method, which sent the model all module code plus a change description. Contract-diff patching used 7,000–22,000 input tokens, versus about 126,000 for the full-source prompts, and sent no source code. This is a result from four changes on one small engine, with single runs. The full-source baseline is weak: keyword retrieval of two modules used fewer tokens but matched the reference pattern in only two of four cases. That result narrows the apparent advantage; it does not show that contract diffs generally outperform stronger ways of selecting relevant code.

A second test bed used combat rules from the D&D 5e System Reference Document 5.1. The contract pipeline passed 288 of 299 tests, compared with 243 after repair for the conventional build. But the contracts went through three versions, revised in response to failures on this test bed, which the paper says favors the contract approach. In maintenance, contract-diff patching used about one third as many input tokens as uploading all source, with no accuracy advantage. A keyword-retrieval maintenance arm matched the reference pattern in all 15 runs, as did the full-source arm; these results are from a different experiment from the four-change board-game comparison.

What the evidence can support

The experiments suggest that explicit interface definitions and rule-linked contracts can help agents coordinate work across modules in these settings. They also show that a contract-based workflow can reduce input tokens relative to uploading all source in the reported maintenance tests. The scale and design constrain what follows: the board-game maintenance result covers four changes on one engine, uses single runs, and compares against a full-source baseline that is not the only way to choose code for an agent. The second test bed shows no accuracy gain from contract-diff patching, and its contracts were tuned on its failures.

The study does not measure whether the method reduces defects, speeds debugging, makes code review easier, or lowers real CI/CD costs. Its “local-model” test used a hosted open-weight model, not a model running on the author’s computer. A proposed hyperbolic-embedding layer is not evaluated here. The work is an arXiv preprint, so its findings should be treated as preliminary; they are not evidence of peer review or broad agreement.

The narrow conclusion is that managing a specification graph and generating code from contracts was feasible in these rule-based test beds. Whether the extra specification work pays off in other software, with stronger baselines and repeated trials, remains an open question.

Reviewed cross-references

These connections were reviewed by a model, not independently fact-checked by a human. Similarity does not imply agreement; consult the original papers and the evidence below.

  • CodeTeam gives AI repository coding a team structure

    Shared method: Both use an explicit contract before code generation to coordinate implementation across modules: Yeung generates per-module contracts mechanically from a specification graph, while Wang et al. normalize a design sketch into a contract covering file ownership, interfaces and dependencies. Their workflows and benchmarks differ, so this is a shared design method, not evidence that either approach validates the other.

    Model review: · openai-codex/gpt-6-luna

    Evidence and provenance

    Selected excerpts, not complete papers. PDF extraction can omit figures or damage equations, tables and reading order; sources may be preprints.

    • 2612.01657v1 — Original paper

      Excerpt reference: static/papers/2612.01657v1.md:13-65
      Basis: Paper text
      Source file SHA-256: 60f703a9a79eb00582756630550953b6eb10f65ecc162d07a3c7e8ada215e70a

    • 2606.22082v2 — Original paper

      Excerpt reference: static/papers/2606.22082v2.md:13-52
      Basis: Paper text
      Source file SHA-256: 507b939f089e60f8a0fe1404aad872832d6ae6d8625db326d26c35f947809062

  • When ‘Verified’ AI Code Proves Less Than It Seems

    Supporting evidence: Both studies bound what acceptance tests establish about requirements: Yeung notes that the tests and graph derive from the same rulebook, limiting their independence; Vempaty et al. report that some structurally verified samples still fail hidden tests and distinguish verifier acceptance from specification fidelity. The latter uses formal-code benchmarks, not Yeung’s game-engine setup, so the findings support only the limited point that acceptance alone may not establish requirement correctness.

    Model review: · openai-codex/gpt-6-luna

    Evidence and provenance

    Selected excerpts, not complete papers. PDF extraction can omit figures or damage equations, tables and reading order; sources may be preprints.

    • 2612.01657v1 — Original paper

      Excerpt reference: static/papers/2612.01657v1.md:832-867
      Basis: Paper text
      Source file SHA-256: 60f703a9a79eb00582756630550953b6eb10f65ecc162d07a3c7e8ada215e70a

    • 2611.05590v1 — Original paper

      Excerpt reference: static/papers/2611.05590v1.md:13-60
      Basis: Paper text
      Source file SHA-256: 91af52a3c02604b73b2d97e93c93365f889e721f97f477472dcd3647c516414b

Automatically matched by shared topic keywords. These links do not imply that the sources agree or establish a consensus.