-
Notifications
You must be signed in to change notification settings - Fork 6.3k
[App-server] add new v2 events:item/reasoning/delta, item/agentMessage/delta & item/reasoning/summaryPartAdded
#6559
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
item/reasoning/delta and item/agentMessage/delta
item/reasoning/delta and item/agentMessage/deltaitem/reasoning/delta, item/agentMessage/delta & item/reasoning/summaryPartAdded
item/reasoning/delta, item/agentMessage/delta & item/reasoning/summaryPartAddeditem/reasoning/delta, item/agentMessage/delta & item/reasoning/summaryPartAdded
| // The logic of whether to emit reasoning summary or reasoning raw content delta is handled in the core. | ||
| // The client just receives ReasoningDelta notifications and handles both cases the same way. | ||
| EventMsg::ReasoningContentDelta(ReasoningContentDeltaEvent { item_id, delta, .. }) | ||
| | EventMsg::ReasoningRawContentDelta(ReasoningRawContentDeltaEvent { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ooc what's the difference between Content and RawContent?
| #[ts(export_to = "v2/")] | ||
| pub struct ReasoningSummaryPartAddedNotification { | ||
| pub item_id: String, | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The Reasoning item is currently defined as:
Reasoning {
id: String,
text: String,
},
should text become something like content_parts: Vec<String>?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this notification doesn't make a whole lot of sense without it IMO
| #[derive(Serialize, Deserialize, Debug, Clone, PartialEq, JsonSchema, TS)] | ||
| #[serde(rename_all = "camelCase")] | ||
| #[ts(export_to = "v2/")] | ||
| pub struct ReasoningDeltaNotification { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does Responses API associate the delta with a specific content part index?
c6f688c to
f036f25
Compare
f036f25 to
0a43e2d
Compare
core event to app server event mapping:
codex/event/reasoning_content_delta&codex/event/reasoning_raw_content_delta->item/reasoning/deltacodex/event/agent_message_content_delta→item/agentMessage/delta.codex/event/agent_reasoning_section_break->item/reasoning/summaryPartAdded(added a small change in core to pass downitem_id).Tested with the
git checkout owen/app_server_test_client && cargo run -p codex-app-server-test-client -- send-message-v2 "hello"and verified that new events are emitted correctly.