Decompose proofSummary.ts
`proofSummary.ts` is 2409 lines with 21 exported functions and 5 consumers. Learn Session 5 flagged it as "the canary for when proofSummary.ts needs decomposition." It has grown through 15+ pipeline scopes, each adding functions. A stranger opening this file sees a wall of code with no clear boundary between report parsing, health computation, and proof generation.
verdict PASSscore 24 / 24findings 5 (0 risk · 1 debt · 4 obs)duration 58mrejection cycles 0shipped May 24, 2026surface cli
Pipeline timeline
Intent to proven code in 58m across Think, Plan, Build, and Verify.
Think1m
Plan13m
Build16m
Verify7m
Assertion ledger
24 claims, each independently verified. Showing 8 — show all →
| ID | Says | Matcher | |
|---|---|---|---|
| A001 | Parser module exists and exports all parsing functions | verified | ok |
| A002 | Parser module exports both type definitions used by proof summaries | verified | ok |
| A003 | Health module exists and exports all computation functions | verified | ok |
| A004 | Health module exports all public constants | verified | ok |
| A005 | Health module exports all health-related type definitions | verified | ok |
| A006 | Core module re-exports all parser symbols for backward compatibility | verified | ok |
| A007 | Core module re-exports all health symbols for backward compatibility | verified | ok |
| A008 | No consumer file import statements were modified | verified | ok |
Findings 5 total
obspackages/cli/src/utils/proofSummary.ts→ monitor
proofSummary.ts still 1285 lines — reduced from 2330 but remains the largest util module
obspackages/cli/src/utils/proof-health.ts→ monitor
proof-health.ts at 893 lines is already above comfort threshold — health computation could decompose further
obspackages/cli/src/utils/proof-health.ts→ closed
MIN_ENTRIES_FOR_EFFECTIVENESS is the only non-exported constant in proof-health.ts — different visibility than the other 4 constants without an obvious reason in the code
debtpackages/cli/tests/utils/proof-parsers.test.ts→ closed
@ana tag ID collisions across features — proof-parsers.test.ts and proof-health.test.ts contain @ana tags from prior features that share the same IDs (A001-A017), making per-contract tag search unreliable
obs→ closed
Contract A010 value (2906 tests) is a snapshot that becomes stale when any other branch adds or removes tests — assertion is structurally fragile for refactoring specs
Integrity seal
scopesha256:c7f2e63443057...
contractsha256:0d4af14034c60...
plansha256:6e6bca7c84de1...
specsha256:be95861c4e9c9...
build-reportsha256:2712c5ddfc443...
build-datasha256:8fce9649b38cb...
verify-reportsha256:e349dd17c6534...
verify-datasha256:07af77ffecc44...
audit cmd$ ana proof audit decompose-proof-summary → all hashes match