Skip to content

add toolCallid and firstclass toolresult event #122#137

Closed
IbrahimAhmed8 wants to merge 1 commit intoupstash:mainfrom
IbrahimAhmed8:fix/issue-122-tool-calls
Closed

add toolCallid and firstclass toolresult event #122#137
IbrahimAhmed8 wants to merge 1 commit intoupstash:mainfrom
IbrahimAhmed8:fix/issue-122-tool-calls

Conversation

@IbrahimAhmed8
Copy link
Copy Markdown
Contributor

Closes #122.

This PR addresses the issue with parallel tool calls by:

  1. Adding toolCallId to the tool-call chunk variant in types.ts
  2. Introducing a first class tool-result chunk variant
  3. Updating the processEvent parser in client.ts to properly extract the tool call IDs and map incoming tool_result events to the new chunk type instead of falling back to the Unknown type
    and all tests n type checks are passing locally

@IbrahimAhmed8 IbrahimAhmed8 changed the title add toolCallId and firstclass toolresult event #122 add toolCall ID and firstclass toolresult event #122 Apr 20, 2026
@IbrahimAhmed8 IbrahimAhmed8 changed the title add toolCall ID and firstclass toolresult event #122 add toolCallid and firstclass toolresult event #122 Apr 20, 2026
@IbrahimAhmed8
Copy link
Copy Markdown
Contributor Author

Closing this PR since the changes were merged via #144

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add tool call IDs and a first-class tool-result event to the streaming Chunk type

1 participant