Repository navigation
Description
Summary
Add a use case to content/use-cases.md: Minigraf as a history store for formal verification results.
This is an idea, not a shipped tool. The goal is to describe it well enough that someone else could build it.
Where it goes
use-cases.md is grouped by deployment target (AI agents, mobile, browser). This idea fits none of them well. Suggest a new section, for example Developer tooling (ideas), that holds use cases with no official tool yet. The decision telemetry use case (#26) could go in the same section.
The idea
Verifiers such as Verus, Creusot, Kani, Dafny and Cpp-Verify prove properties of code. Most of them keep nothing between runs, or keep only a cache keyed by a hash of each proof obligation. A key-value file does that job fine. What gets thrown away is the history:
- Results across versions: which functions were proved, failed or unresolved at each commit, and when that changed.
- Dependencies between proofs: modular verification proves a caller using its callees' contracts. Some results also rest on contracts that are assumed, not proved (Cpp-Verify marks these with
[trusts=...]). Together these form a graph. - Counterexamples: the inputs that broke a proof, and the commit that fixed it.
- Solver behavior: proof time and timeouts per obligation over time.
Why Minigraf fits
The bi-temporal model maps cleanly:
- Transaction time: when the verifier ran.
- Valid time: the code version (commit) the result is about.
That allows questions no current verifier answers on its own:
- "When release 2.1 shipped, which proved functions relied on a trusted (unproved) contract?" Safety and certification audits ask this kind of question.
- "This contract changed. Which callers must be proved again?" This is reverse reachability over the dependency graph, a recursive rule.
- "Which obligations got slower over the last 50 commits?" This catches proof brittleness before it turns into a timeout.
How someone could build it
- No verifier needs to change. An adapter reads the verifier's machine-readable output after each CI run and writes facts. Cpp-Verify emits JSON Lines (
--diagnostics-format=json). Other tools have their own formats. - Store metadata as facts: function, obligation id, status, backend, duration, commit, counterexample values,
trustsand callee edges. - Keep large blobs (the obligation formulas) out of the graph. Store them elsewhere and reference them by hash.
- This is a natural test case for the v3 log writers that import raw facts.
Limits to state in the doc
- The solver's hot path never touches the database. Minigraf stores results, it does not help prove anything.
- Plain proof caches are better served by a key-value file.
- Heavy per-run metrics are time-series data. Minigraf should not become a metrics store.
- Few teams run formal verifiers today. The same adapter shape works for any CI result (tests, fuzz crashes, benchmarks), which is worth mentioning.
- AI agents now write Dafny and Verus proofs and retry many times. A record of failed attempts and their counterexamples is agent memory with an audit trail, which ties back to the AI agents section.
Suggested content
- One short section with the idea, the bi-temporal mapping, and two or three example queries
- A small fact schema sketch (attributes for a verification result)
- One recursive rule for "callers to re-prove when a contract changes"
- A clear note that this is an idea for others to build, with no official tool
Related
- Explore formal verification of storage encoding with Kani minigraf#627 (exploring Kani proofs for Minigraf's own storage encoding)
Generated by Claude Code
Activity
adityamukho commentedon Oct 19, 2026
Other use cases planned for the same developer tooling ideas section: #26, #27, #28, #29, #30, #31, #32, #33.
Generated by Claude Code
adityamukho commentedon Oct 19, 2026
Also for this section: #34 (git sidecar).
Generated by Claude Code