Skip to content

Commit 3344223

Browse files
josevalimbenbrandt
andauthored
RFD: Resume existing sessions (#234)
* RFD: resume existing sessions This document proposes the addition of a 'session/resume' command to allow users to resume existing sessions without returning previous messages, addressing the limitations of the current 'session/load' command. * Revise proposal for session resumption functionality Clarified the proposal for resuming sessions and its advantages and compatibility in relation to 'session/load'. * Add session/load vs session/resume to FAQ * update capabilities and formatting * Add to website * Add update --------- Co-authored-by: Ben Brandt <benjamin.j.brandt@gmail.com>
1 parent d2dc31a commit 3344223

File tree

3 files changed

+94
-1
lines changed

3 files changed

+94
-1
lines changed

docs/docs.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,8 @@
9595
"rfds/session-list",
9696
"rfds/session-config-options",
9797
"rfds/session-fork",
98-
"rfds/request-cancellation"
98+
"rfds/request-cancellation",
99+
"rfds/session-resume"
99100
]
100101
},
101102
{ "group": "Preview", "pages": [] },

docs/rfds/session-resume.mdx

Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
---
2+
title: "Resuming of existing sessions"
3+
---
4+
5+
- Author(s): [@josevalim](https://github.com/josevalim)
6+
- Champion: [@benbrandt](https://github.com/benbrandt)
7+
8+
## Elevator pitch
9+
10+
> What are you proposing to change?
11+
12+
We propose adding the ability to resume existing sessions. This is similar to "session/load",
13+
except it does not return previous messages.
14+
15+
## Status quo
16+
17+
> How do things work today and what problems does this cause? Why would we change things?
18+
19+
While the spec provides a "session/load" command, not all coding agents implement it.
20+
This means that, once you close your editor, browser, etc, you can't resume the conversation.
21+
22+
This is particularly a problem for agents that do not directly implement ACP and the
23+
functionality is implemented via a wrapper. In such cases, they may provide the ability
24+
to resume (without history), which we would like to hook into. Not only that, resuming
25+
could be used as a mechanism for proxies and adapter libraries to emulate "session/load".
26+
27+
## What we propose to do about it
28+
29+
> What are you proposing to improve the situation?
30+
31+
Add a "session/resume" command and a capability `{ session: { resume: {} }`.
32+
33+
## Shiny future
34+
35+
> How will things will play out once this feature exists?
36+
37+
We will be able to resume existing conversations, providing a better user experience.
38+
39+
Not only that, if an agent does not implement "session/load" but it does implement
40+
"session/resume", it is now possible to implement a proxy/adapter that intercepts
41+
the agents messages and writes them to disk. Now when the client issues a
42+
"session/load", the proxy/adapter converts it to a "session/resume", and then returns
43+
the stored messages.
44+
45+
## Implementation details and plan
46+
47+
> Tell me more about your implementation. What is your detailed implementation plan?
48+
49+
## Frequently asked questions
50+
51+
> What questions have arisen over the course of authoring this document or during subsequent discussions?
52+
53+
### Should we introduce a new operation (session/resume) or add an option to (session/load)?
54+
55+
A separate method provides a few benefits:
56+
57+
- for clients that for whatever reason don't want the history, they can just resume
58+
59+
- for agents that can only supply resume, a proxy on top could provide load on top of it,
60+
but the agent is still clear on what it supports
61+
62+
- for agents who support both, it should be trivial to use the same resume functionality,
63+
they just either replay events or do not
64+
65+
### What alternative approaches did you consider, and why did you settle on this one?
66+
67+
The biggest question is if it makes sense to support both "session/load" and
68+
"session/resume".
69+
70+
When we start a new session over ACP, we introduce custom MCP tools and configuration.
71+
This means that, while we could use "session/load" to load our own chats, loading
72+
third-party chats would likely lead to a flawed user experience, as our tools would
73+
not be available. And depending on the ACP implementation, not even the capabilities
74+
would be respected (as loading a third-party session would not include our capabilities
75+
in its history, misleading the agent).
76+
77+
Therefore, if we assume "session/load" is for loading conversations started by the client
78+
itself, "session/resume" is effectively a subset of "session/load", decoupled from storage
79+
mechanics. If an agent implements "session/load", then it can be used directly, but if it
80+
doesn't, a proxy or adapter can provide a reasonable fallback on top of "session/resume".
81+
This argues "session/resume" is the basic primitive which "session/load" builds on top of.
82+
83+
## Revision history
84+
85+
- 2025-11-24: Update FAQ to mention session/resume vs session/load

docs/updates.mdx

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,13 @@ description: Updates and announcements about the Agent Client Protocol
44
rss: true
55
---
66

7+
<Update label="November 26, 2025" tags={["RFD"]}>
8+
## session/resume RFD moves to Draft stage
9+
10+
The RFD for adding a "session/resume" method to the protocol has been moved to Draft stage. Please review the [RFD](./rfds/session-resume) for more information on the current proposal and provide feedback as work on the implementation begins.
11+
12+
</Update>
13+
714
<Update label="November 20, 2025" tags={["RFD"]}>
815
## $/cancelRequest RFD moves to Draft stage
916

0 commit comments

Comments
 (0)