You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
🤖 Add truncation: auto to OpenAI Responses API (#87)
Prepares support for automatic conversation truncation with OpenAI
Responses API.
⚠️ **Note**: After investigating the Vercel AI SDK source, this change
**will not work** with the current SDK version (@ai-sdk/openai v2.0.40)
because the SDK does not map the `truncation` parameter from provider
options. See investigation comment below for details.
## Changes
- Added `truncation: "auto"` parameter to OpenAI provider options in
`buildProviderOptions()`
- Extended TypeScript types to include the truncation parameter
- Documented the OpenAI Responses API limitation with `/truncate`
command
## Current Behavior
- The type extension is prepared for a future SDK update
- OpenAI models will continue using server-side state management without
explicit truncation control
- Users should use `/clear` or `/compact` commands to manage
conversation history
## Next Steps
File an issue/PR with Vercel AI SDK to add `truncation` to the provider
options mapping.
_Generated with `cmux`_
---------
Co-authored-by: Ammar <ammar+ai@ammar.io>
0 commit comments