Skip to content

feat: model download & management UX (P13f-1)#153

Merged
blokzdev merged 1 commit into
mainfrom
claude/p13f1-model-download-ux
Jun 5, 2026
Merged

feat: model download & management UX (P13f-1)#153
blokzdev merged 1 commit into
mainfrom
claude/p13f1-model-download-ux

Conversation

@blokzdev
Copy link
Copy Markdown
Owner

@blokzdev blokzdev commented Jun 5, 2026

P13f-1 — Model download & management UX

First of three P13f phase-close PRs (split confirmed: f-1 model UX · f-2 translation settings surface · f-3 docs phase-close). Exploration found gating is already consistent (shared aiSummaryAction copy; tier-ineligible features hide; the d-3 low-tier path is wired to the "most relevant items" screen) — so the real polish is model download/management legibility.

Every-device-appropriate, settings-screen UX. No schema, no deps.

What changed

  • ModelDownloadServiceinstalledModelIds() (cheap existence scan of the models dir) + delete(modelId) (frees a cached model; no-op if absent). Reuses the existing hash-checked isInstalled.
  • downloadedModelIdsProvider (new) — drives the tile state; invalidated after download/delete.
  • ai_settings_screen.dart generation + transcription model tiles:
    • Subtitle now reads its state: Active · Downloaded · ~XXX MB.
    • A "Delete download" overflow action for downloaded-but-inactive models (frees space; the model stays selectable and re-downloads on demand). The active model has no delete — avoids breaking the active feature.
    • Inline determinate progress during download via the engines' already-exposed downloadModel(onProgress:) (replaces the opaque "Downloading…" snackbar).
  • Aligned the one outlier gating string ("Translation isn't available here""…on this device") with the established tone.
  • The embedder (Gecko floor / multilingual) is intentionally excluded from delete — deleting the active embedder would break semantic search (deferred to BACKLOG with a guarded "switch to Gecko first" flow).

Tests

  • model_download_service_testinstalledModelIds (lists dirs with files, ignores empties; empty when none), delete (removes the dir, no-op when absent, flips isInstalled).
  • ai_settings_screen_test — a downloaded-inactive model shows "Downloaded" + a delete affordance.
  • Full suite green (933), dart format + flutter analyze clean. (downloadedModelIdsProvider is a hand-written FutureProvider — no codegen.)

Docs

  • P13-PLAN.md — P13f card expanded to the f-1/f-2/f-3 breakdown; f-1 [~] + as-built. VERIFICATION.md — P13f-1 row. BACKLOG.md — embedder-delete + item-detail transcribe-flow inline progress deferred.

Verification

  • ✅ CI gates green locally.
  • APK spot-check owed: tile state reads correctly; downloading shows inline progress; delete frees space and the model re-downloads on next select.

Next: f-2 (translation settings surface), then f-3 (P13 phase close — markers, summary, consolidated cross-feature checklist, and the CLAUDE.md §7 phase-close convention).

https://claude.ai/code/session_013JoYmLCosYt5tQ8qwdbL1T


Generated by Claude Code

Make on-device model state legible in Settings → AI: each generation/
transcription picker tile now reads Active / Downloaded / ~MB, downloaded-but-
inactive models offer "Delete download" to free space (the model stays
selectable and re-downloads on demand), and downloading shows an inline
determinate progress indicator via the engines' existing onProgress callback
(replacing the opaque snackbar). ModelDownloadService gains installedModelIds()
+ delete() (reusing the existing isInstalled hash check); a new
downloadedModelIdsProvider drives the tiles. The embedder floor is excluded
from delete (would break semantic search). Also aligned the one outlier gating
copy string. First of three P13f phase-close PRs.

https://claude.ai/code/session_013JoYmLCosYt5tQ8qwdbL1T
@blokzdev blokzdev merged commit 64d378a into main Jun 5, 2026
1 check passed
@blokzdev blokzdev deleted the claude/p13f1-model-download-ux branch June 5, 2026 05:47
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.

2 participants