Prompt previous tokens for streaming (#163)

* feat: prompt previous tokens for streaming

I used a vector pointer instead of vector itself because it gave weird errors, and why not

* convert vector to use with C api

* feat: remove old refs, check for prompt size

* feat: use better way of getting the pointer
This commit is contained in:
M. Eren Akbiyik
2022-11-22 17:10:35 +01:00
committed by GitHub
parent 78116f8eda
commit 63ae03b8e0
3 changed files with 33 additions and 0 deletions

View File

@@ -208,6 +208,10 @@ extern "C" {
bool speed_up; // speed-up the audio by 2x using Phase Vocoder
int audio_ctx; // overwrite the audio context size (0 = use default)
// std::vector<whisper_token>: tokens to provide the whisper model as initial prompt
const whisper_token * prompt_tokens;
int prompt_n_tokens;
const char * language;
struct {