Skip to content

Add deterministic tool call ids#594

Merged
jahooma merged 1 commit intomainfrom
jahooma/tool-call-ids
May 5, 2026
Merged

Add deterministic tool call ids#594
jahooma merged 1 commit intomainfrom
jahooma/tool-call-ids

Conversation

@jahooma
Copy link
Copy Markdown
Contributor

@jahooma jahooma commented May 5, 2026

Summary

  • Add deterministic tool call IDs using functions.<toolName>:<index> counters seeded from message history and pending calls.
  • Apply the IDs across streamed native, custom, XML, and programmatic handleSteps tool execution paths.
  • Add focused runtime tests for ID formatting, counter seeding, emitted tool call/result IDs, and handleSteps counters.

Validation

  • bun test packages/agent-runtime/src/util/__tests__/tool-call-id.test.ts packages/agent-runtime/src/__tests__/tool-validation-error.test.ts packages/agent-runtime/src/__tests__/run-programmatic-step.test.ts packages/agent-runtime/src/__tests__/run-agent-step-tools.test.ts
  • bun run --cwd packages/agent-runtime typecheck

@jahooma jahooma merged commit f43b59e into main May 5, 2026
35 checks passed
@jahooma jahooma deleted the jahooma/tool-call-ids branch May 5, 2026 19:02
jahooma added a commit that referenced this pull request May 7, 2026
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.

1 participant