mirror of
https://github.com/HeyPuter/puter.git
synced 2026-05-05 14:40:10 -05:00
fix: repair stream end
This commit is contained in:
@@ -189,6 +189,7 @@ class ClaudeService extends BaseService {
|
||||
}
|
||||
}
|
||||
}
|
||||
chatStream.end();
|
||||
usage_promise.resolve(counts);
|
||||
};
|
||||
|
||||
|
||||
@@ -365,6 +365,7 @@ class OpenAICompletionService extends BaseService {
|
||||
if ( mode === 'text' ) textblock.end();
|
||||
if ( mode === 'tool' ) toolblock.end();
|
||||
message.end();
|
||||
chatStream.end();
|
||||
};
|
||||
|
||||
return new TypedValue({ $: 'ai-chat-intermediate' }, {
|
||||
|
||||
@@ -74,6 +74,10 @@ class AIChatStream {
|
||||
this.stream = stream;
|
||||
}
|
||||
|
||||
end () {
|
||||
this.stream.end();
|
||||
}
|
||||
|
||||
message () {
|
||||
return new AIChatMessageStream(this);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user