feat(settings): add opt-in local model setup and lifecycle - #107
Open
nonamexishere wants to merge 6 commits into
Open
nonamexishere wants to merge 6 commits into
nonamexishere wants to merge 6 commits into
Conversation
Content-addressed blobs under an injected root. SHA-256 must match before a model is ready. Interrupted staging and truncated files stay unlistable. Duplicate imports reuse one blob. No HTTP, no auto-download, no Tauri commands.
Rename-over the dest manifest instead of deleting it first. The no-GGUF walk ignores gitignored bundle trees so local prepare scripts do not fail cargo test.
Settings can import a local file after a preview of size, license, location, and a hardware-check stub. Load, unload, cancel, and remove use the Fake backend and the McanKul#83 store. No HTTP, no auto-download, no chat. The file picker has no extension filter so any file can be chosen.
Use the preview DTO compatibility string once. After preview, choose a different file or Cancel to dismiss. A checksum mismatch drops the stale hash. Trim Fake-era comments on ai_cancel and ai_generate.
…ancel Settings Cancel no longer latches Fake cancel. open() removes leftover staging/install-* dirs. Dest manifests replace via a sibling tmp file. list_ready uses size only; import_file preflights disk space.
…hing Sweep only leftover install-* dirs from other pids. Remove reads recorded size from the dest manifest (or blob metadata), not a full SHA-256 get.
McanKul
requested changes
Sep 11, 2026
McanKul
left a comment
Owner
There was a problem hiding this comment.
Thanks for the work here. The setup UI should not present an imported file as a loaded, ready model while it is still backed by the Fake runtime and hardware compatibility is unavailable. Please keep the user-facing section hidden or clearly disabled until the real runtime and compatibility check are connected; the underlying lifecycle/store scaffolding can remain.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a Local model section on Settings: import a file from this computer (preview size, license, location, hardware-check stub, then confirm), then load / unload / cancel / remove. Import copies into the #83 store. Load uses the pathless #81 Fake. Restart keeps the file on disk and starts Unloaded. No HTTP, no catalog, no auto-download, no chat/Test button.
Fixes #84.
Stacked on #106 (
feat/83-model-store). This branch includes those store commits until #106 merges.Why
Parent #76 needs an opt-in Settings flow before a real runtime or assistant can ask anyone to load weights. Compatibility is a stub until #82.
Validation
cargo test --manifest-path src-tauri/Cargo.toml --lib lifecycle_(8 passed)npx vitest run src/features/settings/modelSetupView.test.tsnpm test/npm run typecheck/cargo test --libtauri:dev: Import any file (no extension filter), facts then confirm, Load/Unload, restart stays listed + Unloaded, Remove reports freed bytes, PDF tools work with no modelPrivacy Checklist