Skip to content

fix: add fallback download URLs and mid-stream retry for model downloads#407

Open
dcondrey wants to merge 1 commit intoZackriya-Solutions:mainfrom
dcondrey:fix/model-download-fallback-urls
Open

fix: add fallback download URLs and mid-stream retry for model downloads#407
dcondrey wants to merge 1 commit intoZackriya-Solutions:mainfrom
dcondrey:fix/model-download-fallback-urls

Conversation

@dcondrey
Copy link
Copy Markdown

Summary

  • The primary download server (meetily.towardsgeneralintelligence.com) is failing TLS handshakes, causing all first-run model downloads to fail during onboarding for new users
  • Adds HuggingFace fallback URLs for both Parakeet transcription and Gemma summary models
  • Restructures download logic so mid-stream failures (timeout, dropped connection) also trigger fallback instead of just erroring out
  • Fixes a bug where the 416 Range Not Satisfiable retry path used the wrong HTTP response for streaming

Changes

parakeet_engine.rs — Parakeet transcription model download:

  • base_url (single) → base_urls (Vec) with HuggingFace fallback (istupakov/parakeet-tdt-0.6b-v3-onnx)
  • Entire download (connect + stream) wrapped in labeled 'url_loop — mid-stream failures continue to next URL with resume
  • Re-checks existing_size before each URL attempt so resume works after partial downloads
  • Fixes bug: 416 retry now properly reassigns resp so streaming reads from the correct response

model_manager.rs — Gemma summary model download:

  • Same 'url_loop restructure wrapping connection + streaming
  • Mid-stream timeout/error flushes partial file and tries next URL with resume
  • Better error messages: "all download servers failed" instead of "check your internet"

models.rs — Model definitions:

  • Added fallback_urls: Vec<String> field to ModelDef (with #[serde(default)])
  • Gemma 1B fallback: ggml-org/gemma-3-1b-it-GGUF (verified public, no auth)
  • Gemma 4B fallback: ggml-org/gemma-3-4b-it-GGUF (verified public, no auth)

Verified fallback URLs

Model Fallback URL Status
Parakeet v3 huggingface.co/istupakov/parakeet-tdt-0.6b-v3-onnx 307 ✓
Gemma 1B huggingface.co/ggml-org/gemma-3-1b-it-GGUF 302 ✓
Gemma 4B huggingface.co/ggml-org/gemma-3-4b-it-GGUF 302 ✓

Related issues

Test plan

  • Clean install: delete model directories, run app, verify onboarding downloads succeed via fallback
  • Partial download resume: interrupt download mid-stream, restart, verify it resumes correctly
  • Verify both Parakeet and Gemma models download and load successfully after onboarding
  • Verify retry button works when download fails

The primary download server (meetily.towardsgeneralintelligence.com) is
failing TLS handshakes, causing all first-run model downloads to fail
during onboarding. This breaks both Parakeet transcription and Gemma
summary model setup for new users.

Changes:
- Add HuggingFace fallback URLs for Parakeet v3 (istupakov) and Gemma
  models (ggml-org), verified publicly accessible
- Wrap entire download (connection + streaming) in URL fallback loop so
  mid-stream failures (timeout, dropped connection) also trigger fallback
  instead of just erroring out
- Re-check file size before each URL attempt so resume works correctly
  after partial downloads from a failed server
- Fix bug where 416 Range Not Satisfiable retry used the original 416
  response for streaming instead of the fresh retry response
- Improve error messages to say "server issue" instead of misleading
  "check your internet" when all download servers are unreachable

Relates to Zackriya-Solutions#405, Zackriya-Solutions#318
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant