anatrace-core integration (provenance swap + behavioral attestation)
Replace Anatomia's hand-rolled transcript forensics with the published `anatrace-core` package, then build a behavioral-attestation layer on top of it. In the user's words: "properly use and test anatrace within anatomia... use the real anatrace package, test it, and even expand what we currently do by leveraging anatrace."
verdict PASSscore 26 / 26findings 13 (0 risk · 5 debt · 8 obs)duration 3h 15mrejection cycles 0shipped Jun 14, 2026surface cli
Pipeline timeline
Intent to proven code in 3h 15m across Think, Plan, and 2 Build→Verify phases.
Think34m
Plan23m
Build 175m
Verify 17m
Build 236m
Verify 211m
Assertion ledger
26 claims, each independently verified. Showing 8 — show all →
| ID | Says | Matcher | |
|---|---|---|---|
| A001 | Provenance counts come from the published anatrace engine, pinned to a known version | verified | ok |
| A002 | Anatomia no longer hand-parses agent transcripts | verified | ok |
| A003 | Each provenance record states which engine version produced it | verified | ok |
| A004 | Deriving the same session twice produces an identical record | verified | ok |
| A005 | A captured session records a fingerprint of the transcript it was derived from | verified | ok |
| A006 | An unreadable transcript still records who ran, never guessed numbers | verified | ok |
| A007 | Older proof records written before this change still load | verified | ok |
| A008 | Codex sessions now report the files they changed | verified | ok |
Findings 13 total
debtpackages/cli/tests/commands/proof-card-golden.test.ts→ monitor
Golden snapshot fixture INPUTS were changed (cache_read 80k→1M, 900k→1M; model gpt-5-codex→gpt-5) to keep the card within 80 columns once the wider real table-version label is shown — so the golden test no longer proves cost-invariance for unchanged inputs.
obspackages/cli/src/utils/forensics.ts→ monitor
captureProvenanceAtSave no longer calls deriveTranscript — it re-reads bytes and calls deriveCountsFromBytes directly so the transcript_hash attests the same bytes (read-once). deriveTranscript is now reachable only from tests. Intentional, but the read-bytes+basename+derive sequence is duplicated across the two functions.
debtpackages/cli/src/utils/forensics.ts→ monitor
AC13 totality (a core call throwing mid-capture must not break the save) has no explicit test that forces parseSession/deriveCounts to throw. Covered structurally by the outer try/catch in captureProvenanceAtSave and by the unreadable-transcript omit test, but not directly exercised.
obspackages/cli/tests/commands/work-proof-process.test.ts→ acknowledge
Stray indentation in the prov() shape helper: derive_version sits at 6 spaces while sibling keys are at 8. Lint passes (eslint indent not enforced inside this object literal) but it is inconsistent with the file.
obs→ closed
parseTestCounts best-effort regex (session-capture-C12) is resolved: the helper is deleted and test/failure counting is delegated to anatrace-core's command-tool-gated derive. Codex files_touched=0 build concern is also resolved (A008 now derives from a real patch_apply_end body).
+8more findings
Provenance
Who ran what, and what it cost. Recomputable estimates from the shared price table — subordinate to the verdict, never gating.
model claude-opus-4-8
| session | turns | tools | in | out | cache | cost |
|---|---|---|---|---|---|---|
| ana | 118 | 50 | 6.9k | 64.7k | 5.0M | $5.15 |
| plan | 85 | 36 | 6.7k | 92.0k | 3.8M | $5.34 |
| build | 270 | 125 | 13.9k | 127.2k | 19.0M | $14.16 |
| verify | 68 | 29 | 6.4k | 22.9k | 1.6M | $1.97 |
| build 2 | 295 | 150 | 10.5k | 110.1k | 19.6M | $15.08 |
| verify 2 | 76 | 34 | 6.5k | 23.6k | 1.5M | $1.83 |
| TOTAL 6 sessions | $43.53 (table 2026-06-14) | |||||
churn 25 files · +1648/−522
completeness ✓ complete (plan 1/1 · build 2/2 · verify 2/2)
Integrity seal
scopesha256:e52c193b8c21e...
contractsha256:59f34b3847157...
plansha256:f37f61b5a1682...
spec-1sha256:62b72a2bb2d97...
spec-2sha256:385d24894d461...
spec-3sha256:1903173ce13f8...
build-report-1sha256:a5e3830f27fe9...
build-data-1sha256:ce5198342dce1...
verify-report-1sha256:2468292d62463...
verify-data-1sha256:6f7ce7af07ef6...
build-report-2sha256:7cf9f05a2fe98...
build-data-2sha256:252222dab95f8...
verify-report-2sha256:d1ac9654bb249...
verify-data-2sha256:3e19da5c10cb5...
audit cmd$ ana proof audit anatrace-core-integration → all hashes match