remove pyq goodbye model and rime synthesizer and fix environment loading
This commit is contained in:
parent
a93bfc1ec9
commit
1dc7bc74c3
28 changed files with 143 additions and 285 deletions
|
|
@ -1,15 +1,15 @@
|
|||
from typing import Optional
|
||||
from pydub import AudioSegment
|
||||
import io
|
||||
import os
|
||||
import openai
|
||||
from vocode import getenv
|
||||
|
||||
from vocode.turn_based.transcriber.base_transcriber import BaseTranscriber
|
||||
|
||||
|
||||
class WhisperTranscriber(BaseTranscriber):
|
||||
def __init__(self, api_key: Optional[str] = None):
|
||||
openai.api_key = os.getenv("OPENAI_API_KEY", api_key)
|
||||
openai.api_key = getenv("OPENAI_API_KEY", api_key)
|
||||
if not openai.api_key:
|
||||
raise ValueError("OpenAI API key not provided")
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue