File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed
providers/anthropic-base/utils Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -26,7 +26,7 @@ const getMessageDeltaEvent = (response: MessagesResponse): string => {
26
26
return `event: message_delta\ndata: ${ JSON . stringify ( messageDeltaEvent ) } \n\n` ;
27
27
} ;
28
28
29
- const MESSAGE_STOP_EVENT = `event: message_stop\ndata: {type: ' message_stop' }\n\n` ;
29
+ const MESSAGE_STOP_EVENT = `event: message_stop\ndata: {" type": " message_stop" }\n\n` ;
30
30
31
31
const textContentBlockStartEvent = ( index : number ) : string => {
32
32
return `event: content_block_start\ndata: ${ JSON . stringify ( {
Original file line number Diff line number Diff line change @@ -110,10 +110,15 @@ export interface RawContentBlockStopEvent {
110
110
type : 'content_block_stop' ;
111
111
}
112
112
113
+ export interface RawPingEvent {
114
+ type : 'ping' ;
115
+ }
116
+
113
117
export type RawMessageStreamEvent =
114
118
| RawMessageStartEvent
115
119
| RawMessageDeltaEvent
116
120
| RawMessageStopEvent
117
121
| RawContentBlockStartEvent
118
122
| RawContentBlockDeltaEvent
119
- | RawContentBlockStopEvent ;
123
+ | RawContentBlockStopEvent
124
+ | RawPingEvent ;
You can’t perform that action at this time.
0 commit comments