Skip to content

Conversation

@lgrammel
Copy link
Owner

@lgrammel lgrammel commented Jan 15, 2026

Background

Tool calling is essential for agents.

Summary

Add tool calling support.

Manual Verification

  • run and verify examples/basic/src/generate-text-tool-call.ts
  • run and verify examples/basic/src/stream-text-tool-call.ts

Related Issues

Fixes #13

- Added token buffering during the detection phase to handle tool calls more effectively.
- Implemented logic to suppress text deltas when a tool call is detected.
- Updated tests to verify tool call handling and ensure correct output for both tool calls and regular text when tools are present.
@lgrammel lgrammel marked this pull request as ready for review January 15, 2026 17:22
@lgrammel lgrammel merged commit 0dbb7f8 into main Jan 15, 2026
2 checks passed
@lgrammel lgrammel deleted the lg/wsDSDJSe branch January 15, 2026 17:40
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 calling support

2 participants