Zackriya-Solutions/meetily · error
Failed to load model '{}': {}
Error message
Failed to load model '{}': {} What it means
`WhisperEngine::load_model(target_model)` failed while preparing the engine for import. target_model comes from the import request's model argument or the transcript_settings row. Typical inner causes: the named ggml model file is absent from the models directory (the discover_models warning just above is non-fatal, so discovery problems flow into this error), the file is corrupt/truncated, or the GPU backend (Metal/CUDA/Vulkan per build features) fails to initialize.
Source
Thrown at frontend/src-tauri/src/audio/import.rs:787
let current_model = e.get_current_model().await;
let needs_load = match ¤t_model {
Some(loaded) => loaded != &target_model,
None => true,
};
if needs_load {
info!(
"Loading Whisper model '{}' (current: {:?})",
target_model, current_model
);
if let Err(e) = e.discover_models().await {
warn!("Model discovery error (continuing): {}", e);
}
e.load_model(&target_model)
.await
.map_err(|e| anyhow!("Failed to load model '{}': {}", target_model, e))?;
}
Ok(e)
}
None => Err(anyhow!("Whisper engine not initialized")),
}
}
/// Get or initialize the Parakeet engine
async fn get_or_init_parakeet<R: Runtime>(
app: &AppHandle<R>,
requested_model: Option<&str>,
) -> Result<Arc<ParakeetEngine>> {
use crate::parakeet_engine::commands::PARAKEET_ENGINE;
let engine = {
let guard = PARAKEET_ENGINE.lock().unwrap_or_else(|e| e.into_inner());
guard.as_ref().cloned()View on GitHub (pinned to 0281737d87)
Solutions
- List the models the app can actually see (model-list command or discover_models result) and confirm target_model is present before reimporting
- Download the correct ggml file into the models dir: frontend/models in dev; Application Support/Meetily/models on macOS, %APPDATA%\Meetily\models on Windows
- Omit the model argument so get_configured_model falls back to the configured/default model, or pick one known to exist
- If the inner error mentions Metal/CUDA/Vulkan, retry on a CPU-feature build or fix the GPU runtime
Example fix
// before — load and hope
e.load_model(&target_model).await
.map_err(|e| anyhow!("Failed to load model '{}': {}", target_model, e))?;
// after — verify availability first (adapt to discover_models' return type)
if let Ok(models) = e.discover_models().await {
if !models.iter().any(|m| m == &target_model) {
return Err(anyhow!("Model '{}' not found. Available: {:?}", target_model, models));
}
}
e.load_model(&target_model).await
.map_err(|e| anyhow!("Failed to load model '{}': {}", target_model, e))?; Defensive patterns
Strategy: validation
Validate before calling
// verify the ggml file exists before import
let models_dir = app_models_dir(); // dev: frontend/models, prod: app-support/Meetily/models
let expected = models_dir.join(format!("ggml-{}.bin", target_model));
if !expected.exists() {
return Err(anyhow!("Model '{}' not downloaded: {}", target_model, expected.display()));
} Try / catch
Catch the load error and fall back to a known-present model (or omit the model argument to use the configured default) before giving up — the inner error text distinguishes 'not found' from GPU-init failures, which determines whether a CPU retry helps.
Prevention
- Check the model list command output before naming a model in an import request
- Keep model downloads atomic (temp file + rename) so partial ggml files never look valid
- On GPU-feature builds, test a CPU build when load_model reports backend errors
When it happens
Trigger: Importing with a model name (request arg or settings row) that was never downloaded; the models directory relocated or cleaned; a partially downloaded ggml file; a GPU-feature build on a machine whose GPU runtime is missing.
Common situations: User picked 'large-v3' without ever downloading it; app support dir cleaned between sessions; settings restored from another machine without the model files; GPU driver update broke Metal/CUDA init.
Related errors
- Failed to load model {}: {}
- Whisper transcription failed on segment {}: {}
- Whisper engine not initialized
- Failed to load Whisper model '{}': {}
- Failed to load Parakeet model {}: {}
AI-assisted analysis of Zackriya-Solutions/meetily@0281737d87 (2026-08-16).
Data as JSON: /api/errors/46cd8ae7b560f877.
Report an issue: GitHub.