bug: Multiple tool calls in one completion response are not handled
- [x] I have looked for existing issues (including closed) about this
Bug Report
Instead of handling all of the tool calls, the current agent impl only handles the first one.
Reproduction
Call a model that returns multiple tool calls, for example the calculator agent with multiple subs and adds
Expected behavior
Rig correctly evaluates all of the tool calls.
Actual behaviour
Rig only evaluates the first tool call.
Fix PR incoming!
Check out #168 as a potential fix that was deployed specifically for Anthropic!
Check out #168 as a potential fix that was deployed specifically for Anthropic!
This won't handle that issue, as for the moment the ModelChoice is a single object and not an array. You would need to parse the raw_response to gather all the tool_uses
@0xMochan @edisontim here's how I implemented a fix: https://github.com/0xPlaygrounds/rig/pull/224
Closing as I believe this has been fixed - please reply if you're still getting this issue!