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

Supports Whisper prompt and prefix #1028

Open
ocavue opened this issue Nov 14, 2024 · 1 comment
Open

Supports Whisper prompt and prefix #1028

ocavue opened this issue Nov 14, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@ocavue
Copy link
Contributor

ocavue commented Nov 14, 2024

Feature request

Whisper has two options prompt and prefix defined in DecodingOptions (source code). These two options will be inserted as part of the initial_tokens (source code). It would be good to support them in Transformers.js

Motivation

You can find a detailed description of these two options here: openai/whisper#117 (comment). In short, they can improve the transaction quality for long speak (i.e. larger than 30 seconds).

Your contribution

The Python library transformers has prompt_ids for this feature (source code). Maybe we should just implement it in transformers.js too.

@ocavue ocavue added the enhancement New feature or request label Nov 14, 2024
@bil-ash
Copy link

bil-ash commented Dec 22, 2024

+1 for this feature

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

No branches or pull requests

2 participants