Zackriya-Solutions/meetily · error

Parakeet transcription failed on segment {}: {}

Error message

Parakeet transcription failed on segment {}: {}

What it means

`ParakeetEngine::transcribe_audio(segment.samples)` returned Err for segment i; the engine's own error chain follows the colon. The `?` aborts the entire import on a single failing segment, discarding all prior transcription. On the success path confidence is hardcoded to 0.9, so confidence is never the problem — this is an engine/inference failure.

Source

Thrown at frontend/src-tauri/src/audio/import.rs:587

        );

        // Skip very short segments
        if segment.samples.len() < 1600 {
            debug!(
                "Skipping short segment {} with {} samples",
                i,
                segment.samples.len()
            );
            continue;
        }

        // Transcribe
        let (text, conf) = if use_parakeet {
            let engine = parakeet_engine.as_ref().unwrap();
            let text = engine
                .transcribe_audio(segment.samples.clone())
                .await
                .map_err(|e| anyhow!("Parakeet transcription failed on segment {}: {}", i, e))?;
            (text, 0.9f32)
        } else {
            let engine = whisper_engine.as_ref().unwrap();
            let (text, conf, _) = engine
                .transcribe_audio_with_confidence(segment.samples.clone(), language.clone())
                .await
                .map_err(|e| anyhow!("Whisper transcription failed on segment {}: {}", i, e))?;
            (text, conf)
        };

        let trimmed = text.trim();
        if !trimmed.is_empty() {
            debug!(
                "Segment {}/{}: {:.1}s, conf={:.2}, text='{}'",
                i + 1, processable_count, segment_duration_sec, conf,
                if trimmed.len() > 80 { let mut end = 80; while !trimmed.is_char_boundary(end) { end -= 1; } &trimmed[..end] } else { trimmed }
            );
            all_transcripts.push((text, segment.start_timestamp_ms, segment.end_timestamp_ms));

View on GitHub (pinned to 0281737d87)

Solutions

  1. Read the inner error after the colon — it names the actual cause (model file missing vs execution provider failure vs input shape)
  2. Verify the parakeet model files exist and appear in discover_models() results before importing
  3. Retry the import with provider 'whisper' to isolate a parakeet-specific failure
  4. If the inner error is provider-related (CUDA/DirectML/CoreML), switch the execution provider to CPU or update the ONNX runtime

Example fix

// before — one failing segment aborts everything
let text = engine.transcribe_audio(segment.samples.clone()).await
    .map_err(|e| anyhow!("Parakeet transcription failed on segment {}: {}", i, e))?;

// after — skip failing segments, keep the import alive
let text = match engine.transcribe_audio(segment.samples.clone()).await {
    Ok(t) => t,
    Err(e) => {
        warn!("Parakeet failed on segment {}, skipping: {}", i, e);
        continue;
    }
};
Defensive patterns

Strategy: fallback

Validate before calling

// confirm the parakeet model is present before import
const models = await invoke<string[]>('list_models', { engine: 'parakeet' });
if (!models.includes(requestedModel)) {
  throw new Error(`Parakeet model ${requestedModel} is not downloaded`);
}

Try / catch

Catch per segment rather than per import: on engine.transcribe_audio error, log `warn!("segment {} failed: {}", i, e)`, `continue`, and report a partial-meeting warning at the end — fall back to the whisper provider for the whole file if every segment fails.

Prevention

When it happens

Trigger: Import with provider == 'parakeet' and >0 VAD segments: the engine was initialized (get_or_init_parakeet succeeded) but inference fails — ONNX session invalidated by a concurrent model swap, execution provider (CUDA/CoreML/DirectML) error mid-run, or a segment whose sample length the model rejects.

Common situations: Switching the provider to parakeet without its model fully downloaded; a GPU driver update breaking the ONNX execution provider; engine state disturbed by another command between import init and the segment loop.

Related errors


AI-assisted analysis of Zackriya-Solutions/meetily@0281737d87 (2026-08-16). Data as JSON: /api/errors/01d1ef9ab5174af5. Report an issue: GitHub.