-
Notifications
You must be signed in to change notification settings - Fork 99
AGML-229: emit tool call and output events #388
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
Open
KevinWu06
wants to merge
4
commits into
main
Choose a base branch
from
fix/show-tool-call
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
68c6715 to
594f6eb
Compare
594f6eb to
beb2017
Compare
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.
Cursor Bugbot has reviewed your changes and found 2 potential issues.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
abc2d4e to
ac6e6fe
Compare
bb790e7 to
c29df74
Compare
c29df74 to
28e3a22
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
bug
Something isn't working
run-coverage-tests
Label a pull request before merging to trigger test coverage
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Previously, the show tool calls toggle was not working for the LLM and NLU agents for both text and voice features. In the call history, the toggle would not show the tool call logs.
This fix ensures that the tool calls are emitted to the message queue to be picked up and added to the call transcript.
https://linear.app/arklex/issue/AGML-229/agents-fix-tool-call-toggle-for-pipecat-chat-and-voice-transcripts
Description
The previous problem with the NLU agent (voice) was that the tool calls weren't appearing in the call transcript, while regular user/bot messages were. This was because, even though there were listeners to add tool calls to the transcript, the tool calls weren't even being emitted to the message queue. This change ensures that the tool calls are emitted such that the tool calls can populate the call transcipt.
Tests
pip install pre-commitandpre-commit installbefore committing changesrun-coverage-testslabel,run-diff-coverage-testslabel, orrun-integration-testslabel (to skip test coverage) and ensure the check passes.Reviewers
@arklexai/agent-leads
Note
Medium Risk
Touches core execution flow by adding new message-queue events for every tool invocation, which could affect downstream stream/transcript consumers if they assume a different event cadence or payload shape.
Overview
Ensures tool invocations executed via
Executor.step()publish structuredEventType.TOOL_CALLandEventType.TOOL_CALL_OUTPUTmessages toorch_state.message_queue(including tool name, extracted slot arguments, and a best-effort output string).This makes tool calls show up in streamed call transcripts for NLU/LLM agent flows when the "show tool calls" toggle is enabled.
Written by Cursor Bugbot for commit 28e3a22. This will update automatically on new commits. Configure here.