Skip to content

Commit aa0b4e2

Browse files
committed
reasoning raw content
1 parent dfbf5a3 commit aa0b4e2

File tree

1 file changed

+11
-5
lines changed

1 file changed

+11
-5
lines changed

codex-rs/app-server/src/codex_message_processor.rs

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,8 @@ use codex_core::protocol::Event;
131131
use codex_core::protocol::EventMsg;
132132
use codex_core::protocol::ExecApprovalRequestEvent;
133133
use codex_core::protocol::Op;
134+
use codex_core::protocol::ReasoningContentDeltaEvent;
135+
use codex_core::protocol::ReasoningRawContentDeltaEvent;
134136
use codex_core::protocol::ReviewDecision;
135137
use codex_core::read_head_for_summary;
136138
use codex_feedback::CodexFeedback;
@@ -2586,11 +2588,15 @@ async fn apply_bespoke_event_handling(
25862588
.send_server_notification(ServerNotification::AgentMessageDelta(notification))
25872589
.await;
25882590
}
2589-
EventMsg::ReasoningContentDelta(event) => {
2590-
let notification = ReasoningDeltaNotification {
2591-
item_id: event.item_id,
2592-
delta: event.delta,
2593-
};
2591+
// The logic of whether to emit reasoning summary or reasoning raw content delta is handled in the core.
2592+
// The client just receives ReasoningDelta notifications and handles both cases the same way.
2593+
EventMsg::ReasoningContentDelta(ReasoningContentDeltaEvent { item_id, delta, .. })
2594+
| EventMsg::ReasoningRawContentDelta(ReasoningRawContentDeltaEvent {
2595+
item_id,
2596+
delta,
2597+
..
2598+
}) => {
2599+
let notification = ReasoningDeltaNotification { item_id, delta };
25942600
outgoing
25952601
.send_server_notification(ServerNotification::ReasoningDelta(notification))
25962602
.await;

0 commit comments

Comments
 (0)