Skip to content

Commit 0d4c5b9

Browse files
committed
Fix agent notification
1 parent bff7f69 commit 0d4c5b9

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

docs/protocol/draft/schema.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -167,9 +167,9 @@ This capability is not part of the spec yet, and may be removed or changed at an
167167

168168
Cancels an ongoing request.
169169

170-
This is a notification sent by the agent to cancel any ongoing request.
170+
This is a notification sent by the client to cancel any ongoing request.
171171

172-
Upon receiving this notification, the Client:
172+
Upon receiving this notification, the Agent:
173173

174174
1. MUST cancel the corresponding request activity and all nested activities
175175
2. MAY send any pending notifications.

src/bin/generate.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -822,10 +822,7 @@ and control access to resources."
822822
"session/prompt" => self.agent_methods.get("PromptRequest").unwrap(),
823823
"session/cancel" => self.agent_methods.get("CancelNotification").unwrap(),
824824
"session/set_model" => self.agent_methods.get("SetSessionModelRequest").unwrap(),
825-
"request/cancel" => self
826-
.client_methods
827-
.get("CancelRequestNotification")
828-
.unwrap(),
825+
"request/cancel" => self.agent_methods.get("CancelRequestNotification").unwrap(),
829826
_ => panic!("Introduced a method? Add it here :)"),
830827
}
831828
}

0 commit comments

Comments
 (0)