Check a background agy task
agy_statusCheck a background agy task's status, stream recent activity, and retrieve its final result when done or errored; use the returned cursor to poll only new updates.
Instructions
Check on a background agy task started with agy_ask/agy_continue's background:true. Returns its current status, recent activity (tool calls, response text as it streams in), and — once it's done or errored — the same result object a blocking call would have returned. Pass the response's next_cursor back as after_cursor on your next call so repeat polls only show what's new, instead of re-showing the same overlapping window of recent activity every time. agy is a cheap, fast model and explores well, but it fabricates file paths, line numbers, function names, and quoted code with some regularity. Treat everything in response as an unverified lead, not fact: before repeating a specific claim (a path, a symbol, a line number, an exact quote) to the user or acting on it, confirm it yourself with Read/Grep/Glob.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"task_id": "<task_id>"
},
"name": "agy_status"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| task_id | Yes | task_id returned when the task was started with background:true. | |
| after_cursor | No | Pass the next_cursor from a previous agy_status call on this task to get only activity newer than that, instead of the default last-20-events snapshot. With this set, a wait_seconds long-poll also returns as soon as any new activity shows up, not just on completion — so repeated polling stays cheap and non-redundant. | |
| wait_seconds | No | If the task is still running (and, when after_cursor is set, has no new activity yet), long-poll for up to this many seconds before returning. 0 (default) returns the current status right away. Keep this well under your own client's tool-call timeout — if this call itself times out while the underlying agy process is still running, the client may kill/restart this MCP server to recover, which kills every task tracked in it (background tasks are in-memory only). For a long-running task, prefer several short polls over one long one. |