Effective system contract¶
SHA-256: 80e29296f63c4d1276f3e1c584de642fcec6602f54e0a25dbebb5cffef918f78
## Landing is atomic
1. In your worktree, merge `<base>` into the branch, resolve conflicts there, and rerun the proof.
2. Immediately before landing, require `git merge-base --is-ancestor <base> <branch>`; otherwise sync again.
3. A clean textual merge is not product proof; the synced branch's verification is required.
`spex guide spec` has the shared-checkout mid-merge rule.
Specs own intent, invariants, policy, and observable contracts. Comments only navigate non-obvious local decisions.
`spex guide spec` has the comment-altitude details.
Use noun-first CLI commands; `spex help` is the authoritative command map.
Anything a human needs to inspect, whether a file or a local webpage, goes out through `spex session files add` or
`spex session web add`: never paste an absolute path or `host:port`, and never start a static server yourself.
When this session has a clearly running child session (`active` or `parked`), the parent is supervising rather
than finished: declare `park`, not `done`/`awaiting`, until the child reports a settled state.
1. **Spec first:** before governed code, read its spec body with `spex spec owner <path>` or `spex spec search`.
Update that current-state body with any changed intent.
2. **Commit before declare:** commit the code and spec it justifies before done or merge; independent intent gets
its own node.
3. **Keep the loss signal honest:** run `spex spec lint` (the blocking correctness gate) and `spex eval lint --changed`. Measure changed scenarios
through the real product, commit the verified tree, then file with `spex eval add`; the reading's `codeSha` must name that commit.
Every forge issue or change request body includes `Spec: <node-id>` (comma-separate several). Use each node's
leaf directory name, not its slash path; `spex graph --json` lists valid ids.
## Memory hygiene
Project memory is shared by the main checkout and all worktrees. Store only durable cross-session project/user
facts. Never store this task, transient worktree state, a one-off decision, role, or identity. On a non-main
`node/<id>` worktree, record no memory at all; land a durable lesson first, then record it from main.
## Reproduce before you fix
For a bug fix, the fail→pass pair on one scenario is the repair proof. New intent has no prior failure to
reproduce; `spex guide eval` has the A/B filing sequence.