cjpais/Handy · error · anyhow::Error
Failed to load canary model
Error message
Failed to load canary model {}: {} What it means
Thrown when CanaryModel::load fails to load the Canary ONNX model (Int8 quantization) from model_path. As with the other ONNX engines, the underlying error is chained after the model_id and a "loading_failed" model-state event reaches the frontend.
Solutions
- Re-download the Canary model
- Verify sufficient disk space and that the Int8 files are complete
- Check the chained error for provider names; switch ONNX accelerator to CPU and retry
- Temporarily select a Whisper model to verify the rest of the pipeline works
Defensive patterns
Strategy: try-catch
Try / catch
if let Err(e) = manager.load_model(&model_id, None) {
// error text already reached the frontend via loading_failed; decide retry vs fallback engine here
log::error!("canary load failed: {e:#}");
} Prevention
- Ensure enough free disk space for the quantized model before downloading
- Do not mix model files across app versions
- Surface loading_failed events to the user immediately
When it happens
Trigger: EngineType::Canary branch executes CanaryModel::load(&model_path, &Quantization::Int8) and ONNX Runtime returns an error: missing/truncated files, wrong quantization variant present, or session creation failure on the configured provider.
Common situations: Interrupted download; large model hitting disk-space limits mid-write; provider (e.g. CoreML/DirectML/CUDA) unavailable on the machine; app update changed model packaging.
Related errors
- Failed to load cohere model
- Failed to load gigaam model
- Failed to load moonshine model
- Failed to load moonshine streaming model
- Failed to load SenseVoice model
AI-assisted analysis of cjpais/Handy@ba10ce1943 (2026-08-17).
Data as JSON: /api/errors/043e5ad8eea926ff.
Report an issue: GitHub.
Appendix: source
Thrown at src-tauri/src/managers/transcription.rs:696
format!("Failed to load SenseVoice model {}: {}", model_id, e);
emit_loading_failed(&error_msg);
anyhow::anyhow!(error_msg)
})?;
LoadedEngine::SenseVoice(engine)
}
EngineType::GigaAM => {
let engine = GigaAMModel::load(&model_path, &Quantization::Int8).map_err(|e| {
let error_msg = format!("Failed to load gigaam model {}: {}", model_id, e);
emit_loading_failed(&error_msg);
anyhow::anyhow!(error_msg)
})?;
LoadedEngine::GigaAM(engine)
}
EngineType::Canary => {
let engine = CanaryModel::load(&model_path, &Quantization::Int8).map_err(|e| {
let error_msg = format!("Failed to load canary model {}: {}", model_id, e);
emit_loading_failed(&error_msg);
anyhow::anyhow!(error_msg)
})?;
LoadedEngine::Canary(engine)
}
EngineType::Cohere => {
let engine = CohereModel::load(&model_path, &Quantization::Int8).map_err(|e| {
let error_msg = format!("Failed to load cohere model {}: {}", model_id, e);
emit_loading_failed(&error_msg);
anyhow::anyhow!(error_msg)
})?;
LoadedEngine::Cohere(engine)
}
};
// Update the current engine and model ID
{
let mut engine = self.lock_engine();
*engine = Some(loaded_engine);
}View on GitHub (pinned to ba10ce1943)