Repository navigation
Conversation
…REAL HTTP routes Proves composition R10 (validate -> issue -> accept -> sealed read-back -> real price change -> MC 9 child) against the real gateway store (initStore/ getRepos), real kernel/capability rows, the real CsdRegistry, and the real agentPlanRoutes/reservationRoutes + accept seam/deal-binding/PlanPresentation, over one durable BudgetReservationStore sharing getStore()'s sqlite handle. Found and closed a real gap: loadBuiltinCsds() (packages/spec/src/csd/ registry.ts:397-406) omits document-print-and-mail.csd.json, so the shared getCsdRegistry() singleton can't map a capability type to it today. Proven with an `undefined` assertion, then closed the same way POST /api/csd would: registering the real CSD JSON via the real .register() method. Also deviates from the literal evidenceFor spec: keying evidenceTypeId on primitive.id alone collides for document-print-and-mail's tier1-3 (two primitives share id "machine.execution_log", differing only by `bind`), and the real compiler's uniqueness-per-(evidenceTypeId,tier) check (composition- commitment.ts:220) refuses the plan. Keyed on primitive.bind ?? primitive.id instead, matching how this codebase's own existing stand-in EVIDENCE maps already do it. implementer-delta Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This was referenced Sep 29, 2026
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Draft, test-only, stacked on #415. The composition path end to end over REAL SQLite rows, through the REAL HTTP routes. The product pack's return asks for "one end-to-end trace proving the lane's contribution against real state, not fixtures". Until now the traces held live rows as in-memory arrays.
What is real
initStore,getRepos,getStore), a real SQLite database migrated by the realcreateStore.productionAgentPlanDeps().revalidationruns unchanged, both for/api/agent-plans/validateand inside the accept seam. It is the real mapping from DB rows to live terms, over the real CSD registry (getCsdRegistry()).agentPlanRoutesandreservationRoutes, the accept seam, the deal binding andpresentPlan. Layer B andsealedcome from the code; nothing is asserted by hand.BudgetReservationStoreover the SAME SQLite handle, with the real consume protocol,sealedDealPreimageandparseSealedDeal.The trace (one test, 6 steps; the artifact is written when
PCC_REAL_TRACE_OUTis set)consumedwith the same digest;stale, with a price diff and the new live price;The artifact is
/mnt/sparkbulk/pcc-reconciliation/returns/pcc-composition-real-state-trace.json.What is still a labelled stand-in, and why
requestTermsandpayerFor: gateway-owned, not built (#3503).evidenceFor: derived from the real CSD JSON tiers, one requirement per primitive, keyed onbind ?? id. Evidence owns the canonical mapping. Keying onidalone collides: this CSD declaresmachine.execution_logtwice, and the compiler refuses duplicate(evidenceTypeId, tier).⚠ Gap found: the reference vertical's CSD is not registered in production
loadBuiltinCsds()(packages/spec/src/csd/registry.ts) never registersdocument-print-and-mail.csd.json, aworkflow-kind CSD. So in production,getCsdRegistry().findUrlByType("document-print-and-mail")isundefined: the print leg of the reference vertical cannot resolve its CSD, and validate or accept would answerincompatible.register(), the same callPOST /api/csdmakes.Tests
reservations-routeandagent-plans-routein the same run: 28/28. No singleton leaks between files.Written by a sonnet subagent (implementer-delta) to the lane's spec, and reviewed and re-run by the lane.
pcc-composition 8a0f4de0, goal pcc-reconciliation.
🤖 Generated with Claude Code