docs(agents): add two-gate session-start protocol (rule summary + scope)

The template previously had no session-start gate at all. Adds:
- Step 5: rule-summary gate (summarize rules, wait for confirmation)
- Step 9: scope-alignment gate (present priorities, wait for user to
  name the target ticket before any work begins)

Prevents agents from autonomously picking work outside the session's
intended scope. Mirrors the PFVCluster gate structure.

💘 Generated with Crush

Assisted-by: Crush:glm-5.2
This commit is contained in:
2026-08-11 20:33:02 -05:00
parent 5c44e3ef41
commit 28b0019d2e
+22 -2
View File
@@ -13,12 +13,32 @@ enforce the mechanical rules below; this document states the policy and intent.
**You are an AI agent working on this project. Your first actions, in order:** **You are an AI agent working on this project. Your first actions, in order:**
> **SESSION-START GATE (NON-NEGOTIABLE):** Steps 1-4 orient you. Step 5 is the
> check-for-understanding gate (rule summary). Steps 6-8 gather state. Step 9 is
> the scope-alignment gate. You MUST NOT begin any task work until the user
> (a) confirms your rule summary AND (b) names the ticket to work on. This runs
> **every session, automatically** — the user should never have to ask for it.
1. **Set up the environment:** `bash scripts/setup-hooks.sh` (installs git hooks — idempotent). 1. **Set up the environment:** `bash scripts/setup-hooks.sh` (installs git hooks — idempotent).
2. **Read [STATUS.md](STATUS.md)** — current state, inbox, blockers, tactical notes. 2. **Read [STATUS.md](STATUS.md)** — current state, inbox, blockers, tactical notes.
3. **Read [`.crush/memory/operational.md`](.crush/memory/operational.md)** — access details, key IDs, gotchas. 3. **Read [`.crush/memory/operational.md`](.crush/memory/operational.md)** — access details, key IDs, gotchas.
4. **Read [questions-v1.md](questions-v1.md)** — open questions awaiting human input. 4. **Read [questions-v1.md](questions-v1.md)** — open questions awaiting human input.
5. **Check Redmine**`redmine list --assigned-to-me -p <project-id>` for active work. 5. **Check for understanding — GATE.** In your own words, summarize the rules
6. **Check current state:** `git log --oneline -10`. from this file back to the user: Systems of Record, Git Workflow, Questions
policy, Remote Access (if applicable), Conventions, and any project-specific
rules. Then stop and wait for the user to confirm. This checkpoint
guarantees every session starts aligned.
6. **Check Redmine**`redmine list --assigned-to-me -p <project-id>` for active work.
7. **Check current state:** `git log --oneline -10`.
8. **Run rule audit:** `bash scripts/check-rules.sh --fast`.
9. **Scope-alignment — GATE.** Present the session handoff's priority list (or
the Redmine queue if no handoff exists). Do NOT scan the full ticket queue
and pick work on your own — **the user directs what gets worked on, always.**
Note any new or urgent items from the Redmine check, then ask which ticket
to work on tonight. **STOP and wait.** Do not set `.crush/active-ticket`,
do not read systems, do not run diagnostics, until the user names the
target. This gate prevents the agent from burning context on work the user
didn't ask for.
## Project Overview ## Project Overview