Skip to content

Loop/cockpit: needs-human signal — label + push notification when the loop blocks on the owner #99

Description

@robercano

Context (from the orchestrator landscape comparison)

reCode's cockpit is pull-only: if the loop is blocked on YOU (a PR awaiting your review, a stall, a budget halt), nothing tells you — the loop idles at WATCH cadence and work sits until you happen to open the dashboard. Every comparable treats human-attention-needed as a first-class pushed signal:

  • emdash's core UX insight: agent state is a tri-state — working / awaiting input / done — surfaced as OS notifications with lifecycle hooks; "observability without an attention path is half a product" (emdash).
  • Looper: a reserved looper:needs-human label + decision cards pushed to the human (GitHub comment or chat), and notify-on-action_required with sound levels (users guide).
  • Composio AO: a Notifier slot (Slack/desktop/webhook) that alerts "only when judgment is needed" — not on every event.

This issue is the natural companion to #85 (loop-health panel): #85 makes state visible, this makes the blocking subset find you. Several other filed issues (#94 protected-paths, #95 budget halt, #96 escalations, #98 manual-intervention) already want to emit exactly this signal — it should exist once, not four times.

Proposal

  1. One label, one meaning: needs-human (created by the setup skill alongside backlog/planned). Applied by loop scripts whenever they block on owner judgment: PR ready-for-review (fresh approval needed), CHANGES_REQUESTED round-trip done and re-review needed, stall/manual-intervention, budget halt, protected-path flag, escalations from bounded retries. Removed automatically when the condition clears (approval given, issue advanced).
  2. One notifier seam: notify.sh <severity> <title> <body-line> in .claude/scripts/, adapter-configured command in gates.json (e.g. ntfy publish, a webhook curl, notify-send, or empty = disabled — same empty-means-skip convention as gates). Loop scripts call it at the same points they apply the label. Throttled: one notification per (kind, target) per cadence window, so a WATCH loop doesn't nag every 5 minutes.
  3. Cockpit: a "Needs you" strip at the very top — anything labeled needs-human or awaiting owner review, with links. This is the first thing the dashboard should answer: "does anything need me right now?"

Acceptance criteria

  • When a loop PR becomes merge-eligible-except-owner-approval, the owner gets exactly one push notification and the PR shows needs-human; approving clears it.
  • All escalation paths in the loop route through the same label + notifier (grep should find one implementation).
  • Notifier command empty → silent no-op, loop unaffected (offline/CI safe).
  • Cockpit "Needs you" strip renders from live data and from fixtures.

Decision points for you

  • Default notifier for your setup: ntfy? Telegram webhook? WSL toast? (The seam is generic; pick your default.)
  • Should needs-human also PAUSE the loop for that issue/PR (Looper's hold semantics), or only signal? (Recommend: signal only; planned-removal already provides manual hold.)

🤖 Generated with Claude Code

https://claude.ai/code/session_014Gu82LWNkdzhrDFSQ7EZmB

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestmodule:harnessOrchestrator machinery under .claudeplannedOwner-approved for the autonomous loop (assigned ONLY by the owner)

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions