Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add stopSequences parameter to AI SDK functions #1633

Open
rajeshdavidbabu opened this issue May 17, 2024 · 3 comments
Open

Add stopSequences parameter to AI SDK functions #1633

rajeshdavidbabu opened this issue May 17, 2024 · 3 comments
Labels

Comments

@rajeshdavidbabu
Copy link

Feature Description

Add support for stop-sequence to gracefully exit stream, so that we can get usage information.

Use Case

Currently, if I wanna exit the stream I have to use abort-controller or break to get out of for await of loop.

This would not gracefully finish and we need a finish so that we can get usage information.

Additional context

No response

@lgrammel lgrammel mentioned this issue May 27, 2024
@lgrammel lgrammel changed the title Add stop to open-ai input options so that we can finish gracefully Add stopSequences parameter to AI SDK functions May 27, 2024
@lgrammel lgrammel added the enhancement New feature or request label Jun 5, 2024
@flexchar
Copy link

I came across this as a deal breaker to migrate to the new AI SDK functions because certain models just won't stop themselves...

@gergomiklos
Copy link

Please prioritize this or offer an option to pass native settings to models

@flexchar
Copy link

@gergomiklos do you have time to take a stab at this together?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants