Remove the monolithic specification - #166
Open
atqamz wants to merge 2 commits into
Open
Conversation
Move durable rationale to a focused ADR set and leave behavioral contracts with code, help, and tests. Refs #163
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.
Summary
SPECS.mdwithout replacing it with another specification or generated command reference.config/keys, into README.md.SPECS.md disposition
Repository and architecture
What this file is: deleted as migration narration.Core principles: concise contributor routing now lives in AGENTS.md and CONTRIBUTING.md; the durable one-binary rationale remains insecondhand-rebuilds-firstmate-as-one-go-binary.md.Architecture overview: deleted because README.md and the package boundaries already represent it.Machine state and the prose corpus,Which to believe when they disagree, andNot Postgres, and no daemon: implementation and recovery behavior remain ininternal/store,internal/state, their tests, and README.md; durable report-file authority was merged intothe-report-channel-is-the-only-outcome-signal.md, and the short-lived-process consequence remains in the one-binary ADR.Directory layout: init, home, store, and config code and tests own the layout. README.md now lists the optional operator configuration keys that otherwise lacked a discoverable owner.Ambient contextandFirst-run configuration: README.md,internal/sessionhook,internal/agentsmd, command help, and their focused tests own behavior. The hook-versus-rendered-file boundary remains in a tightened ADR.Output shape:internal/axi, command tests, root error tests, and generated AGENTS.md own behavior. The TOON default and JSON compatibility choice remains in a tightened ADR.Commands
Every command contract is already represented by Cobra help, its implementation, and focused command or end-to-end tests, so the duplicate prose and exhaustive output examples were deleted:
hand:cmd/root.goand root tests.hand init:cmd/init.go, README.md, init tests, and init e2e tests.hand config:cmd/config.go, generated AGENTS.md, and config tests.hand project add,list,upstream,remove, andsync:cmd/project.go, project package code, and project, PR, sync, and upstream tests.hand spawn:cmd/spawn.go,cmd/launch.go,internal/harness, and spawn and launch tests.hand status:cmd/status.go,cmd/statusview.go, and status tests.hand send:cmd/send.goand send unit and e2e tests.hand hold setandclear:cmd/hold.go, store and state hold code, and hold and status tests.hand deliver:cmd/deliver.goand deliver and upstream teardown tests.hand teardownandCompletion store:cmd/teardown.go,internal/completion, and their focused tests. The fail-closed work guard and append-only completion storage choices remain as tightened ADRs.hand merge:cmd/merge.go,internal/ghutil, and merge tests.hand pr:cmd/pr.go,internal/project/pr.go, and PR detection tests.hand watch,One watcher per fleet home,Delivering an event,Notifying,Resuming a usage-limited worker,What survives a restart, andPane-anchored facts across promote:cmd/watch.go,internal/watcher,internal/harness,cmd/promote.go, generated AGENTS.md, and focused unit and e2e tests. The singleton flock, exit-as-delivery, and harness-capability boundaries remain as tightened ADRs; exhaustive field and filter membership prose was deleted.hand promote:cmd/promote.goand promote and watcher cache tests.hand notify:cmd/notify.go,internal/notify, and tests.hand searchandOptional qmd:cmd/search.go,internal/store/index.go, tests, and README.md.hand doctor:cmd/doctor.go,internal/agentsmd, AGENTS.md, and tests.Integrations and formats
Harness launch templatesand its Claude Code, Codex, Grok, Pi, and OpenCode subsections: exact commands and capabilities live ininternal/harnessand its tests; launch confirmation lives incmd/launch.goand tests. The interactive residency and split liveness/dialog boundary is one merged ADR.Herdr integration detail,Connection,Workspace and tab model,Agent state,Operations, andHerdr CLI calls:internal/herdr, command tests,internal/faketool/FIDELITY.md, andtests/contractown syntax and observed behavior. The report channel ADR retains only why herdr state cannot be task outcome.No-mistakes integration,Gate preflight, andGate-run visibility: user workflow remains in README.md and command help;internal/project/gaterun.goand gate tests own behavior. The public-output-versus-private-database boundary remains in a tightened ADR.Brief formatandDeclared model and effort:internal/brief, generated AGENTS.md, tier resolution, and focused tests own the format and precedence.Backlog format: generated AGENTS.md and README.md own concise agent guidance. The stale example and unused implementation claims were deleted.Project registry format:internal/project,internal/store, parser and projection tests, and README.md own the format and user concept.State, errors, tests, and release
State managementandRules:internal/store,internal/state,internal/watcher, and their tests own behavior; only qualifying data-boundary rationale remains in ADRs.Report channelandUnacknowledged terminal reports:internal/state/report.go, watcher and status tests, and generated AGENTS.md own the contract; the outcome and plain-file authority rationale is one merged ADR.Holds: store, state, command, and status tests own behavior; the independent-row boundary remains in a tightened ADR.Concurrency: sqlite and named-lock implementations and tests own it.Collision guard:internal/worktree, spawn and collision tests, and FIDELITY.md own it.Recovery: README.md and generated AGENTS.md own operator guidance; the report ADR keeps why plain-file recovery exists.Migration:internal/store/migrate.goand migration tests own it.Schema versioning:internal/store/schemaversion.goand tests own the protocol; the PRAGMA boundary remains in a tightened ADR.Error handling,Philosophy,Exit codes, andError output:cmd/root.go,cmd/precondition.go,internal/axi, generated AGENTS.md, and root, send, watch, and e2e tests own behavior.Testing strategy,Unit tests, andIntegration tests: AGENTS.md, CONTRIBUTING.md, package documentation, FIDELITY.md, the shared fake, and the suites own the strategy. The stateful-fake boundary remains in a tightened ADR.Distribution,Install methods,Fleet home creation,Self-update,Release pipeline, andRepo scaffolding: README.md, CONTRIBUTING.md, command help, the Makefile, release configuration, tracked workflows, and their tests own these workflows. Duplicate narration and tracked-file inventories were deleted.ADR disposition
Keep and tighten
ambient-context-is-a-session-hook-not-a-file.mdgate-checks-read-no-mistakes-output-not-its-database.mdholds-are-their-own-table.mdone-stateful-fake-per-external-tool.mdone-watcher-per-fleet-home-guarded-by-an-flock.mdoutput-is-toon-by-default-and-json-is-retained.mdsecondhand-rebuilds-firstmate-as-one-go-binary.mdthe-completion-store-is-an-uncapped-append-only-sibling.mdthe-landed-work-guard-reads-the-work-not-the-record.mdthe-schema-version-lives-in-pragma-user-version.mdthe-until-event-exit-is-the-delivery.mdusage-limit-detection-is-a-harness-capability.mdMerge
believe-the-status-file-and-ship-no-hand-dump.mdmerged intothe-report-channel-is-the-only-outcome-signal.md; the destination now records both worker-outcome ownership and plain-file authority.launch-confirmation-trusts-herdr-not-the-screen.mdmerged intoharness-templates-launch-interactively.md; the destination now records both interactive residency and the split between herdr liveness and dialog text.Delete because executable owners already hold the fact
a-fork-projects-upstream-is-declared-never-inferred.mda-silent-report-channel-is-parked-on-three-bounds.mda-steer-that-never-lands-leaves-a-durable-trace.mdan-unrecorded-pr-is-recovered-by-head-ref.mddeliver-names-the-state-instead-of-widening-force.mdherdr-workspace-labels-carry-a-hand-prefix.mdnotify-is-a-filtered-consumer-of-the-event-stream.mdthe-collision-guard-keys-on-the-lease-id.mdthe-report-offset-is-trusted-only-with-a-digest.mdthe-watcher-persists-what-it-announces.mdRelocate contributor policy
the-comment-rule-is-two-mechanical-checks.md: CONTRIBUTING.md andtools/commentlintalready own the rule, exemptions, and enforcement, so the ADR was deleted.Final retained collection: 14 ADRs plus
docs/adr/README.md.Verification
make lintgo build ./...go test -race ./...make e2emake contractCloses #163