Skip to content

Commit c7b2129

Browse files
authored
Merge pull request #13 from matlab-deep-learning/dev-fix-streaming-bug
Improved error message
2 parents c00241a + 3c42bc9 commit c7b2129

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

+llms/+stream/responseStreamer.m

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,8 @@
4545
catch ME
4646
errID = 'llms:stream:responseStreamer:InvalidInput';
4747
msg = "Input does not have the expected json format. " + str{i};
48-
causeException = MException(errID,msg);
49-
ME = addCause(ME,causeException);
50-
rethrow(ME)
48+
ME = MException(errID,msg);
49+
throw(ME)
5150
end
5251
if ischar(json.choices.finish_reason) && ismember(json.choices.finish_reason,["stop","tool_calls"])
5352
stop = true;

0 commit comments

Comments
 (0)