Skip to content

sep: bounded task-output views on Events - #38

Open
girishkvs wants to merge 1 commit into
modelcontextprotocol:mainfrom
girishkvs:task-output-views
Open

girishkvs wants to merge 1 commit into
modelcontextprotocol:mainfrom
girishkvs:task-output-views

Conversation

@girishkvs

Copy link
Copy Markdown

Draft SEP that moves modelcontextprotocol/agents-wg#30 (bounded task-output views) to ext-tasks and rebuilds it on Events (SEP-3415), so Tasks does not get a second output channel.

  • A task output event type, mcp.task.output.updated, bound to a task through eventSource from Draft: Task Event Sources ext-events#2.
  • Its payload is the whole current view: revision, availability (available, empty or unavailable), maxBytes and content blocks. Over the bound means unavailable, never cut.
  • Clients replace by revision, an older revision never replaces a newer one, and the same revision with different content is a conflict. There is no view after terminal status, and the result comes from tasks/get.
  • Three proposed changes to Events: late join, coalescing without truncated, and a normal end. Each comes with an alternative that needs no Events change.

Related: modelcontextprotocol/modelcontextprotocol#3237, modelcontextprotocol/agents-wg#26. No sponsor yet.

Comment thread seps/bounded-task-output-views.md Outdated

What a generic client cannot do is interpret that output without learning each server's own rules:

- A value of `["A"]` followed by `["A", "B"]` can mean replace or append. Two clients can accept the same JSON and show different output.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe events always append? @pja-ant can you confirm?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @LucaButBoring for the review. I agree the event stream always appends. This line is about what a client shows from each event's data: after ["A"] and then ["A", "B"], one client shows A, B because it replaces the view, and another shows A, A, B because it adds to it. Events leaves data to each event type's payloadSchema, so both readings are valid today. This SEP picks replace, and I reworded this line to say that.

Comment thread seps/bounded-task-output-views.md Outdated

Events leaves `data` to each event type's `payloadSchema` (SEP-3415 L181), and Task Event Sources "does not mandate an event type naming convention" (ext-events#2 L140), so intermediate results sent as events raise the same three questions.

These are examples of how clients can read the same output differently, not defects observed in named implementations. The proposal is worth pursuing only if real producers and clients want a common contract. If application-specific tools, resources and event types meet their needs, there is no reason to standardize this one.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At least for the time being, this would seem to undercut this proposal and render it somewhat premature.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree that sentence undercuts it and I removed it. modelcontextprotocol#3237, already cited in the SEP, shows why a server's own resource isn't enough: a computer-use server on Tasks plans its own task-log://{taskId} resource and a vendor-private _meta key for now, and asks the WG for a shape "so it's interoperable rather than per-vendor". Intermediate results is also a P1 item for this WG.

Comment thread seps/bounded-task-output-views.md Outdated
- **Author(s)**: Girish Konda (@girishkvs)
- **Sponsor**: None (seeking sponsor)
- **Extension Identifier**: `io.modelcontextprotocol/tasks`
- **Amends**: the Tasks extension ([SEP-2663](https://modelcontextprotocol.io/seps/2663-tasks-extension)), using Events ([SEP-3415](https://github.com/modelcontextprotocol/modelcontextprotocol/pull/3415), `io.modelcontextprotocol/events`) and Task Event Sources ([ext-events#2](https://github.com/modelcontextprotocol/ext-events/pull/2)). Proposes three changes to Events.

@LucaButBoring LucaButBoring Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FWIW I've seen little intent to accept modelcontextprotocol/ext-events#2 yet

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this SEP should not depend on it, so I made ext-events#2 optional. A client that has the task ID can subscribe to mcp.task.output.updated with { "taskId": ... } directly, without eventSource. The SEP also takes three rules from that PR, and I stated them in the SEP itself: the same authorization as tasks/get, the event stream ending when the task ends, and task status staying with Tasks. Let me know if that works.

Draft SEP that moves modelcontextprotocol/agents-ig#30 to ext-tasks,
rebuilt on Events (SEP-3415), with Task Event Sources (ext-events#2)
as an optional binding.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants