Skip to main content

Verification-Driven Cross-Repository Scaffolding

The Problem

Grace operates across 3 repositories (stratt-hq, choco-hq, cho-co) with different tech stacks, URI schemes, and organisational structures. Writing agent context that accurately represents all three without drift is non-trivial.

The Approach

Read source of truth from each repo before writing any cross-referencing documentation:
  • STRATT: constants.ts (domains, types, statuses), council.yaml files (3 councils), commands/ directory (21 files)
  • Choco HQ: contracts/ (43 APIs), docker-compose.yaml (services), requirements/ (171 reqs)
  • cho-co: web/ (Next.js), cmd/ (Go CLI), sdk/ (TS + Go)

The Key Numbers

Every count in agent files was verified against the filesystem:
  • 7 packages (ls packages/ | grep -v units | grep -v node_modules)
  • 3 councils (ls -d councils/*/)
  • 43 units (find packages/units -name "*.yaml" | wc -l)
  • 21 commands (ls packages/cli/src/commands/)
  • 16 agent designations (cross-referenced against 3 council.yaml files)

The Learning

Counts from memory are unreliable. Counts from the filesystem are ground truth. When building orchestration layers, verify every number before committing it to documentation that agents will rely on for routing decisions.