{"record":{"id":"b2892babb42dca6c","repo":"Zackriya-Solutions/meetily","slug":"parakeet-transcription-failed-on-segment-b2892b","errorCode":null,"errorMessage":"Parakeet transcription failed on segment {}: {}","messagePattern":"Parakeet transcription failed on segment (.+?): (.+?)","errorType":"exception","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"frontend/src-tauri/src/audio/retranscription.rs","lineNumber":376,"sourceCode":"                i + 1,\n                processable_count,\n                segment_duration_sec\n            ),\n        );\n\n        // Skip very short segments (< 100ms of audio = 1600 samples at 16kHz)\n        if segment.samples.len() < 1600 {\n            debug!(\"Skipping short segment {} with {} samples\", i, segment.samples.len());\n            continue;\n        }\n\n        // Transcribe this segment\n        let (text, conf) = if use_parakeet {\n            let engine = parakeet_engine.as_ref().unwrap();\n            let text = engine\n                .transcribe_audio(segment.samples.clone())\n                .await\n                .map_err(|e| anyhow!(\"Parakeet transcription failed on segment {}: {}\", i, e))?;\n            (text, 0.9f32)\n        } else {\n            let engine = whisper_engine.as_ref().unwrap();\n            let (text, conf, _) = engine\n                .transcribe_audio_with_confidence(segment.samples.clone(), language.clone())\n                .await\n                .map_err(|e| anyhow!(\"Whisper transcription failed on segment {}: {}\", i, e))?;\n            (text, conf)\n        };\n\n        // Skip empty transcripts\n        let trimmed = text.trim();\n        if !trimmed.is_empty() {\n            debug!(\n                \"Segment {}/{}: {:.1}s, conf={:.2}, text='{}'\",\n                i + 1, processable_count, segment_duration_sec, conf,\n                if trimmed.len() > 80 { let mut end = 80; while !trimmed.is_char_boundary(end) { end -= 1; } &trimmed[..end] } else { trimmed }\n            );","sourceCodeStart":358,"sourceCodeEnd":394,"githubUrl":"https://github.com/Zackriya-Solutions/meetily/blob/0281737d87d26352fb0adc78c8c0975f691b23d1/frontend/src-tauri/src/audio/retranscription.rs#L358-L394","documentation":"ParakeetEngine::transcribe_audio(segment.samples) returned Err for segment i. The inner '{}' names the engine-level failure: typically the model was unloaded or swapped by another task sharing the global PARAKEET_ENGINE, an ONNX runtime error, a malformed sample buffer, or memory exhaustion during inference.","triggerScenarios":"Retranscribing with provider='parakeet' while another operation (live transcription, import, a second retranscription of a different meeting) calls unload_engine_after_batch or load_model on the same global engine mid-loop; a segment containing NaN samples; ONNX/DirectML runtime failure on Windows.","commonSituations":"User starts an import or live recording while a long Parakeet retranscription is in progress; low RAM/VRAM with large models; GPU driver update breaking the ONNX execution provider.","solutions":["Read the inner error text - it names the exact engine failure (model not loaded vs runtime error vs OOM).","Ensure no other transcription workload runs concurrently; wait for is_retranscription_in_progress() to return false before starting other engine work.","Retry the retranscription once - transient ONNX and memory errors often clear.","Reload the Parakeet model from Settings and confirm it reports as loaded before retranscribing."],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":"// Retry once on engine inference failure, then surface the inner error\nlet attempt = engine.transcribe_audio(segment.samples.clone()).await;\nlet text = match attempt {\n    Ok(t) => t,\n    Err(e) => match engine.transcribe_audio(segment.samples.clone()).await {\n        Ok(t) => { warn!(\"segment retry succeeded after: {e}\"); t }\n        Err(e2) => return Err(anyhow!(\"Parakeet transcription failed on segment {i}: {e2}\")),\n    },\n};","preventionTips":["Run only one transcription workload at a time - concurrent engine use is the top cause.","Confirm the Parakeet model is loaded (Settings) before batch retranscription.","Keep enough free RAM/VRAM for the selected model plus segment buffers."],"tags":["parakeet","transcription","onnx","audio"],"backgroundTag":"asr-engine-inference-failed","analyzedSha":"0281737d87d26352fb0adc78c8c0975f691b23d1","analyzedAt":"2026-08-16T20:57:52.567Z","schemaVersion":2},"datasetVersion":"2026-08-16T23:17:17.608Z"}