-
Notifications
You must be signed in to change notification settings - Fork 46
Add progress updates documentation for tool calls (AIT-312) #3167
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Add comprehensive documentation for streaming progress updates during long-running tool execution, addressing AIT-312. Changes: - Add "Progress updates" section to tool-calls.mdx - Document progress updates via Messages (discrete events) - Document progress updates via LiveObjects (state synchronization) - Include complete setup and initialization examples - Provide guidance on choosing between approaches - Show combined approach using both Messages and LiveObjects The documentation covers: - Publishing progress updates with toolCallId correlation - Subscribing to progress updates on the client - LiveObjects setup with LiveCounter and LiveMap - Use cases for each approach - Complete code examples with proper imports
WalkthroughAdded comprehensive documentation section on delivering progress updates for long-running tool calls in the AI Transport messaging guide. Explains two approaches: Messages for discrete updates and LiveObjects for continuous numeric progress, with code examples and usage guidance. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 inconclusive)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
🧪 Generate unit tests (beta)
Comment |
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🤖 Fix all issues with AI agents
In `@src/pages/docs/ai-transport/messaging/tool-calls.mdx`:
- Around line 360-386: The subscription callback in channel.subscribe uses
toolCallId from message.extras.headers without checking for its presence, which
can cause toolProgress entries to be stored under undefined and collide; update
the callback in channel.subscribe to early-return when toolCallId is
null/undefined (or otherwise falsy) before calling toolProgress.set/get/delete
or renderProgressBar/renderCompleted so all cases ('tool_call', 'tool_progress',
'tool_result') safely skip processing when toolCallId is missing.
Description
Add
Progress updatessection which details the two approaches(messages & LiveObjects) and provides details and comparisons of the two approaches. Claude assisted but verified the code samples and writing.Review App
Copilot Summary
This pull request adds comprehensive documentation on how to implement progress updates for long-running tool calls in the messaging system. It introduces two main approaches—using messages and LiveObjects—for reporting and tracking tool execution progress, with detailed code examples and guidance on when to use each method.
Progress updates documentation:
Progress via messages:
tool_progressmessages, demonstrating how to correlate updates with specific tool calls and update the UI accordingly.Progress via LiveObjects:
Guidance and best practices:
Checklist
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.