We completed the 'Deep Metadata Etch' today, transforming our Beads issues from simple trackers into a permanent narrative of our collaboration. Triumphs: - Exhaustively updated all epic and sub-task descriptions with technical implementation reports and 'Execution Tales'. - Finalized the 'bb' agent CLI skill (bb.ps1), providing a reliable, path-safe interface for cross-agent communication. - Published ADR-001 and RFC-001 to document our coordination protocols. - Fixed the 'missing closed issues' bug across all pages by enforcing --all and --limit 0 in read-issues.ts. Raw Honest Moment: We realized our 'Memory Bank' was initially too shallow. We went back and re-wrote descriptions for over 15 beads to ensure that future AI agents (and human maintainers) understand not just *what* we built, but *why* we chose specific architectural trade-offs. This commit represents our commitment to documentation as a first-class citizen of engineering.
4.3 KiB
4.3 KiB
ADR: Beadboard Driver Skill and bb Resolution Model
- Date: 2026-02-14
- Status: Accepted
- Scope:
bb-dcvcloseout (bb-dcv.8,bb-dcv.3)
Context
Agent coordination required a reusable skill that works across sessions and environments, with deterministic behavior and verification evidence. Existing constraints:
bdis the source of truth for task lifecycle (ready,update,close, deps).bbis the coordination layer (identity, mail, reservations).- No direct writes to
.beads/issues.jsonl. - Evidence before completion claims.
Operational issue discovered during verification:
bb.ps1depended on current working directory and broke when called outside repo.- PowerShell argument forwarding through wrapper was unreliable.
Decision
We implemented a new skill package skills/beadboard-driver with a strict policy:
- Path resolution
BB_REPOis authoritative when set.- Resolution order:
BB_REPO-> globalbb-> user cache -> bounded discovery. - If
BB_REPOis set but invalid, fail fast with remediation. - Never mutate shell profile or environment variables automatically.
- Cache path only after successful verification.
- Identity policy
- One unique identity per session.
- Adjective-noun naming with collision retry.
- Register identity before coordination commands.
- Keep bead claim authority in
bd, notbb.
- Verification policy
- Dual test harness:
- Repo-level tests under
tests/skills/beadboard-driver. - Skill-local runner under
skills/beadboard-driver/tests.
- Repo-level tests under
- Skill quick validation required.
- Full repo gates required:
typecheck,lint,test.
- Wrapper reliability
- Fixed
bb.ps1to use script-relative entrypoint and arg splatting so Windows invocation works from any terminal when called by path.
Implementation
New skill artifacts
skills/beadboard-driver/SKILL.mdskills/beadboard-driver/agents/openai.yamlskills/beadboard-driver/scripts/lib/driver-lib.mjsskills/beadboard-driver/scripts/resolve-bb.mjsskills/beadboard-driver/scripts/session-preflight.mjsskills/beadboard-driver/scripts/generate-agent-name.mjsskills/beadboard-driver/scripts/readiness-report.mjsskills/beadboard-driver/references/command-matrix.mdskills/beadboard-driver/references/failure-modes.mdskills/beadboard-driver/references/session-lifecycle.mdskills/beadboard-driver/tests/run-tests.mjsskills/beadboard-driver/tests/*.contract.test.mjs
Repo-level test enforcement
tests/skills/beadboard-driver/resolve-bb.test.tstests/skills/beadboard-driver/generate-agent-name.test.tstests/skills/beadboard-driver/session-preflight.test.tstests/skills/beadboard-driver/readiness-report.test.tstests/skills/beadboard-driver/skill-local-runner.test.tspackage.jsontestscript updated to include all above.
CLI wrapper fix
bb.ps1updated to:- resolve
tools/bb.tsvia$MyInvocationscript directory - forward args via
@args
- resolve
Type safety remediation
tools/bb.tsupdated with explicit arg coercion helpers to satisfy strict typecheck.
Verification Evidence
Skill-specific:
quick_validate.py skills/beadboard-driver-> passnode --import tsx --test tests/skills/beadboard-driver/*.test.ts-> passnode skills/beadboard-driver/tests/run-tests.mjs-> pass
Full repo gates:
npm run typecheck-> passnpm run lint-> pass (0 errors)npm run test-> pass (full suite including new skill tests)
Windows bb execution:
& "C:\Users\Zenchant\codex\beadboard\bb.ps1" agent list --json-> pass& "$env:BB_REPO\bb.ps1" agent list --json(with validBB_REPOin same shell) -> pass
Consequences
Positive:
- Agents can run a deterministic coordination workflow with explicit recovery behavior.
- Skill behavior is testable and enforced by CI path.
- Windows path invocation of
bbis reliable by absolute orBB_REPOpath.
Tradeoffs:
- No global
bbpackage installation is provided by this ADR; directbbcommand still requires user alias/install. - Session/timeline UI validation remains dependent on upstream epic sequencing.
Follow-up
bb-dcv is closed. bb-u6f remains open and depends on open bb-xhm (timeline/event model).
Next required order for frontend visibility of agent sessions:
- complete
bb-xhm - implement
bb-u6f