fix(stt): correct Realtime WS model to gpt-realtime-whisper + enhance event handling for deltas/completed
- URL now uses ?model=gpt-realtime-whisper (was invalid gpt-4o-mini-realtime-preview) - Cleaned session.update (removed modalities that may not apply) - Expanded _handle to catch input_audio_transcription.delta and .completed events - on_error now forwards transcription errors to frontend client - Per AUDIT + PLAN item 1
This commit is contained in:
@@ -141,6 +141,10 @@ async def conversation_ws(websocket: WebSocket):
|
||||
|
||||
async def on_error(msg: str):
|
||||
logger.warning(f"Whisper error: {msg}")
|
||||
try:
|
||||
await websocket.send_json({"type": "error", "message": f"Transcription error: {msg}"})
|
||||
except Exception:
|
||||
pass
|
||||
|
||||
# Start WhisperStream
|
||||
stream = WhisperStream(
|
||||
|
||||
Reference in New Issue
Block a user