M24: attention reasons and actions #38
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Depends on: #36 (classification only; the rest can start now)
Blocks: #40
Swarm track. Attention says what happened, not just "needs you", so the client can explain it, bundle it with others and act on it.
Today
Attentionisidle | working | needs_input | done, plus anAskfor question cards. Keep those states, and add a reason to every non-idle one.ask: an openAsk(agent blocks, and Claude Code through its hook), with its headline;failed: a command that ran longer than a few seconds ended with a non-zero exit (from shell integration'sCommandEnd);exited: a pane's program died with a non-zero code, mainly servers andRerun/Hookpolicies (fromExit), ormachine_gone;input: the pane waits on a prompt. That covers bell andNotify, plus prompt detection for[sudo] password,[y/N]and(y/n), and "Enter passphrase", when output stops on that line;done: a long command finished while nobody was looking (today'sdone), with its duration.since_ms, a one-lineheadline, the command and exit code where there is one, and a bundle key:failedandexitedbundle by machine;askbundles by project and agent;inputnever bundles.POST /api/attention/act) taking one pane or a list:allowanddeny: answer anask(wrapping/api/panes/{id}/ask);rerun: run the last command again (the "Run again" menu item);restart: restart the pane's program under its policy;send: type an answer (y, Enter), forinput;dismiss: today'sPaneOp::Attention.illogical attention --jsonlists the reasons;illogical eventsstreams changes;cargo test, a dyingnpm run dev, asudoprompt, a Claude Code question and a 10-minute build each show the right reason and headline inillogical attention;