Repository navigation
fix(model-runtime): complete streaming invocation callbacks - #376
Conversation
There was a problem hiding this comment.
Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.
An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing. Review the Copilot code review billing settings.
There was a problem hiding this comment.
Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.
An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing. Review the Copilot code review billing settings.
bd92369 to
bb1ed6b
Compare
There was a problem hiding this comment.
Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.
An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing. Review the Copilot code review billing settings.
Important
Read the contribution guidelines and checked related issues and pull requests.
Related Issue
Closes #375
Summary
Streaming LLM completion callbacks currently omit tool calls, and exceptions raised while reading the stream skip the error callback.
Include assembled tool calls in
on_after_invokeusing the existing delta merger, and notifyon_invoke_errorwith the original exception before propagating stream failures.Invocation, token counting, and callback signatures consistently accept
Sequence[PromptMessage], matching their read-only use of the input collection.Regression coverage exercises complete calls, interleaved argument fragments, and failures before or after the first chunk, with blocking calls as controls.
Existing scenarios also use tuple prompts: four argument-type errors reproduce the restrictive signatures, and the updated signatures pass the full type check.
Validation:
just check: passed, including full type checking.just test: 1067 passed.Checklist
!