Open
Conversation
Contributor
Author
|
@benbrandt I’ve updated the PR so the description can be read better. Could you take a look when you have time? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Title: "Agent Status Update"
Author(s): anaslimem
Elevator pitch
Add standardized agent status reporting to the Agent Client Protocol, enabling agents to communicate what they are currently doing (thinking, reading, writing, waiting, idle) through
session/updatenotifications.This provides users with visibility into agent activity during long-running tasks, so they can distinguish between an agent that is actively working versus one that is stuck or waiting.
Status quo
Currently, when users run agents for long operations:
The protocol currently supports:
ToolCallStatus- Status of individual tool calls (pending, in_progress, completed, failed)Plan+PlanEntryStatus- Execution plan statusUsageUpdate- Token usage and cost trackingHowever, there is no way for the agent to report its overall status at the agent level (vs individual tool calls).
What we propose to do about it
We propose adding an
AgentStatusUpdatevariant to theSessionUpdateenum that allows agents to report their current activity.Proposed Status Values
thinkingreadingwritingwaitingidleWire Format Example
{ "jsonrpc": "2.0", "method": "session/update", "params": { "sessionId": "sess_abc123", "sessionUpdate": "agent_status_update", "status": "reading", "message": "Reading codebase structure...", "currentTask": "Step 2/5: Finding Rust files" } }Shiny future
Once implemented, clients can display agent status in their UI:
thinkingreadingwritingwaitingidleThis provides:
Implementation details and plan
Phase 1: Schema Changes
Add to
src/client.rs:Add to
SessionUpdateenum:Phase 2: RPC Handling
Add decode logic in
src/rpc.rsfor the new session update type.Phase 3: Documentation
Update protocol documentation to reflect the new notification type.
Frequently asked questions
How is this different from MCP progress notifications?
MCP progress notifications track progress on individual MCP tool requests (e.g., "tool X is 50% complete"). Agent status tracks what the agent as a whole is doing (e.g., "agent is reading files"). They serve different purposes - MCP is tool-level, Agent status is agent-level.
Does this overlap with existing tool call status?
ToolCallStatustracks individual tool calls. Agent status is higher-level - it tells you what the agent is doing overall, which may involve multiple tool calls or no tool calls at all (e.g., "thinking").Is this similar to the existing Plan feature?
The
Planfeature shows the overall execution plan. Agent status is more granular - it shows the current activity at any moment, even without a plan.What alternative approaches did you consider, and why did you settle on this one?
We considered:
We settled on a dedicated
AgentStatusUpdatebecause it provides the right level of abstraction for user-facing status without coupling to tools or plans.