Persist realtime transcription sessions to history
The websocket handler now accumulates the full session's PCM audio
(not just the per-chunk buffer that gets discarded after each
worker call) and, on stop, writes it as a wav to UPLOAD_DIR plus a
result JSON to RESULT_DIR via the new _save_realtime_history()
helper — same shape /transcribe already writes, tagged
gateway_backend="realtime" so the history table visually
distinguishes it from file uploads. This reuses /asr/history and
/asr/uploads/{filename} as-is; no new endpoints needed.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -200,7 +200,7 @@ async function startRecording() {
|
||||
appendLive('');
|
||||
} else if (msg.type === 'final') {
|
||||
rtFinalText.value = msg.text || '';
|
||||
setIndicator('idle', '완료');
|
||||
setIndicator('idle', msg.id ? '완료 (처리 내역에 저장됨)' : '완료');
|
||||
cleanupAudio();
|
||||
} else if (msg.type === 'error') {
|
||||
setIndicator('idle', `오류: ${msg.detail}`);
|
||||
|
||||
Reference in New Issue
Block a user