Threads, commands and labels on the new loop (M2.3) #102

Merged
dongar merged 1 commits from loop-labels into main 2026-10-04 20:15:08 +00:00
Collaborator

M2.3 of the Development Plan (L5, D1).

What changes

  • Commands that name their item ("go #14", "abandon #14", "stop #14") apply to that item from top level or any thread. Alone at top level, go, approve and abandon are ambiguous, so the agent asks which item and lists the open ones. stop in a waiting item's thread is no longer taken as an answer.
  • Plain-language go-aheads. A reply to a restatement that isn't a command goes to GoAheadReader (loop/reader.py). It's one model call that answers yes, no or unclear, and only yes counts.
    • Questions never reach it.
    • The agent says "Taking that as a go-ahead on rev-N" before acting, and it binds to the revision on screen when the reply arrived.
    • This is not the L4 action classifier, which judges commands (M3.1). It only reads your reply. For now it runs on the driver's model; the classifier role takes over in M2.6.
  • Labels steer (D1).
    • bug: the restatement says it will go ahead after tuning.loop.bug_grace_s (default 10 minutes, in the Tuning Guide). Any reply stops the countdown, and status shows the time left. The driver is told to reproduce first and never to fix a bug it couldn't see.
    • discuss: restate isn't offered until you've spoken in the thread.
    • design: steered by the driver's instructions. Design documents in the repo come in M2.4.
  • A restatement asks no questions. This is a new prompt line, added after a live run where a restatement ended in a question, which a yes can't answer.

Tests

  • test_loop_labels.py covers named and ambiguous commands, plain yes, no, questions and stale revisions, the reader's verdicts, the grace period and its cancellation, discuss, and label prompts.

  • The property walk now has labelled issues, plain yeses, named gos and time passing. Two new properties:

    • grace_only_unanswered;
    • discuss_talks_first.

    Letting discuss restate at once fails 8 of 32 seeds. Not clearing the countdown on a reply is caught by the unit test, not the walk: almost every reply re-runs the driver, which puts up a fresh revision anyway.

  • E2E (scripts/e2e.sh, 5 tests):

    • a bug issue against a real bug on the run's base branch, which the agent reproduces and then proceeds on after a 20-second grace period with no go;
    • a feature started with "Yep, that's right, sounds good."

    The full run passed 4 of 5. The plain-yes test then failed twice on the test's own wording: once on the old prompt, once when its clarification read as agreement. After rewording it, it passed twice on its own.

Deferred

  • Labels are read at intake; a label changed later isn't picked up.
  • The L1 switching grace period (still pending, as noted in M2.2).

🤖 Generated with Claude Code

https://claude.ai/code/session_01PPQ14L3LikyefCMFBqEbKE

M2.3 of the Development Plan (L5, D1). ## What changes - **Commands that name their item** ("go #14", "abandon #14", "stop #14") apply to that item from top level or any thread. Alone at top level, `go`, `approve` and `abandon` are ambiguous, so the agent asks which item and lists the open ones. `stop` in a waiting item's thread is no longer taken as an answer. - **Plain-language go-aheads.** A reply to a restatement that isn't a command goes to `GoAheadReader` (`loop/reader.py`). It's one model call that answers yes, no or unclear, and only yes counts. - Questions never reach it. - The agent says "Taking that as a go-ahead on rev-N" before acting, and it binds to the revision on screen when the reply arrived. - This is not the L4 action classifier, which judges commands (M3.1). It only reads your reply. For now it runs on the driver's model; the `classifier` role takes over in M2.6. - **Labels steer (D1).** - `bug`: the restatement says it will go ahead after `tuning.loop.bug_grace_s` (default 10 minutes, in the Tuning Guide). Any reply stops the countdown, and `status` shows the time left. The driver is told to reproduce first and never to fix a bug it couldn't see. - `discuss`: `restate` isn't offered until you've spoken in the thread. - `design`: steered by the driver's instructions. Design documents in the repo come in M2.4. - **A restatement asks no questions.** This is a new prompt line, added after a live run where a restatement ended in a question, which a yes can't answer. ## Tests - `test_loop_labels.py` covers named and ambiguous commands, plain yes, no, questions and stale revisions, the reader's verdicts, the grace period and its cancellation, `discuss`, and label prompts. - The property walk now has labelled issues, plain yeses, named gos and time passing. Two new properties: - `grace_only_unanswered`; - `discuss_talks_first`. Letting `discuss` restate at once fails 8 of 32 seeds. Not clearing the countdown on a reply is caught by the unit test, not the walk: almost every reply re-runs the driver, which puts up a fresh revision anyway. - E2E (`scripts/e2e.sh`, 5 tests): - a `bug` issue against a real bug on the run's base branch, which the agent reproduces and then proceeds on after a 20-second grace period with no go; - a feature started with "Yep, that's right, sounds good." The full run passed 4 of 5. The plain-yes test then failed twice on the test's own wording: once on the old prompt, once when its clarification read as agreement. After rewording it, it passed twice on its own. ## Deferred - Labels are read at intake; a label changed later isn't picked up. - The L1 switching grace period (still pending, as noted in M2.2). 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01PPQ14L3LikyefCMFBqEbKE
dev-agent added 1 commit 2026-10-04 16:13:34 +00:00
Threads, commands and labels on the new loop (M2.3)
CI / checks (push) Skipped
CI / checks (pull_request) Successful in 3m45s
4d9c1d7529
- Commands that name their item ("go #14", "abandon #14", "stop #14")
  apply to it wherever they're said; go, approve and abandon alone at top
  level are asked about (L5). stop is never taken as an answer.
- A plain-language reply to a restatement is read by GoAheadReader, one
  model call that agrees only on a clear yes; questions never reach it. The
  agent says "taking that as a go-ahead on rev-N" first, bound to the
  revision on screen at arrival (L3, L5, D1).
- Labels steer (D1): `bug` goes ahead after tuning.loop.bug_grace_s
  (default 600 s) unless the operator replies; `discuss` isn't offered
  restate until the operator has spoken; `bug`, `discuss` and `design` add
  to the driver's instructions. A restatement asks no questions.

Tests: label and command unit tests, the property walk with labelled
issues, plain yeses, named gos and time passing (grace_only_unanswered,
discuss_talks_first), and e2e tests for a bug proceeding after its grace
period and a plain-language go-ahead.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PPQ14L3LikyefCMFBqEbKE
dongar approved these changes 2026-10-04 20:15:05 +00:00
dongar merged commit da32cac5cf into main 2026-10-04 20:15:08 +00:00
dongar deleted branch loop-labels 2026-10-04 20:15:08 +00:00
Sign in to join this conversation.
No Reviewers
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: dev/nisse#102