swarm: list an agent's bash tasks from their published status
GET /api/agents/{name}/bash-tasks reads the agent's keys of the bash-task-status
bucket and reports each task's state, command and times, with a live task whose
daemon stopped reporting as stale. The swarm UI shows them in a background tasks
section of the agent card, running ones first. The task output stays unread.
This commit is contained in:
parent
cc7b298cf3
commit
5de20f31dd
1 changed files with 625 additions and 11 deletions
|
|
@ -203,6 +203,9 @@ goes to `$SWARM.term.<agent>.bash.<task>`, with a `Swarm-Stream` header of `stdo
|
|||
agent, for 24 hours or 64 MiB like the subagent rows. The agent's credential may publish
|
||||
`$KV.bash-task-status.<agent>.*` and `$SWARM.term.<agent>.bash.>` and nothing else of
|
||||
JetStream. The bash daemon publishes both (see [`bash.md`](../agent-tools/bash.md)).
|
||||
`GET /api/agents/<name>/bash-tasks` lists an agent's tasks from the status keys, newest first and at
|
||||
most 200, each with its `state` (the published one, or `stale` when a live task's daemon stopped
|
||||
reporting), `cmd`, `created_unix`, `since_unix` and `exit`. The output stream isn't read yet.
|
||||
|
||||
The queue would refuse a row too large for its `max_payload` outright and
|
||||
take the connection down with it, so the harness drops such a row's body before
|
||||
|
|
|
|||
Loading…
Reference in a new issue