mirror of
https://github.com/khoj-ai/khoj.git
synced 2025-02-17 08:04:21 +00:00
Prompt Whisper to know "Khoj" term for speech to text transcription
This commit is contained in:
parent
3dcc8695b2
commit
04363a504c
1 changed files with 1 additions and 1 deletions
|
@ -9,5 +9,5 @@ async def transcribe_audio(audio_file: BufferedReader, model, client: OpenAI) ->
|
|||
Transcribe audio file using Whisper model via OpenAI's API
|
||||
"""
|
||||
# Send the audio data to the Whisper API
|
||||
response = await sync_to_async(client.audio.translations.create)(model=model, file=audio_file)
|
||||
response = await sync_to_async(client.audio.translations.create)(model=model, file=audio_file, prompt="Khoj")
|
||||
return response.text
|
||||
|
|
Loading…
Add table
Reference in a new issue