Skip to content

Set up a first local model entirely in the agents panel - #18907

Merged
dhh merged 3 commits into
quattrofrom
local-ai-panel-setup
Nov 14, 2026
Merged

dhh merged 3 commits into
quattrofrom
local-ai-panel-setup

Conversation

@dhh

@dhh dhh commented Nov 14, 2026

Copy link
Copy Markdown
Contributor

What changes

Setting up the first local model from the agents panel opened a floating terminal so sudo could install Podman, crun and (on NVIDIA) nvidia-container-toolkit. Add another › Local AI always ran the whole setup in a terminal.

Now the whole flow stays in the panel:

  • omarchy-agent-local use --detach installs missing packages with pkexec pacman (no terminal to ask in, per the privilege-escalation rule), prints an Error: line on failure, and passes pkexec's 126 through when the password dialog is dismissed.
  • The panel runs the setup itself (Main.qml, like pairing does) and shows the model's line right away: "Installing" with a progress bar while packages install, then the usual Downloading bar once status.json takes over. A failure stays on the line with its reason, linking to the full output; Delete dismisses it. Dismissing the password dialog brings the download offer back.
  • Both Download on the offer and Add another › Local AI go through this path, and the panel stays open. Link setup (another Spark's password) and Share (SSH server setup) still use a terminal.

Verification

  • test/shell.d/agents-panel-test.sh: the wrapper installs through pkexec before handing off, a dismissed dialog exits 126 without starting the setup, and the panel's setup line goes starting → installing → failed-with-reason / gone on cancel / gone once handed off. Both new tests fail on the base branch.
  • test/shell.d/i18n-test.sh passes.
  • Live on an N1x laptop: removed the installed model and podman, crun and nvidia-container-toolkit, ran the branch's shell, clicked Download in the agents panel. The polkit dialog came up, the line showed the install, the packages installed, the download handed off to the background unit, and the model loaded and ran (42s, about 30 GiB). The first label, "Installing Podman", overlapped the bar and was shortened to "Installing".

Screenshots

🤖 Generated with Claude Code

The panel's Download and Add another › Local AI no longer open a terminal.
A detached setup missing Podman installs it through pkexec, and the panel
runs the setup itself, showing an Installing line until the download takes
over, the reason if it fails, and the offer again if the password dialog
is dismissed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@greptile-apps

greptile-apps Bot commented Nov 14, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[High impact] The PR appears safe to merge; no new blocking issues were found.

Summary

Local model setup now stays in the agents panel, with password prompts, progress, and failures shown without opening a setup terminal.

  • Local model setup now stays in the agents panel.
  • Standard installs now include the runtime for local models.

No new actionable issues found. Both earlier concerns are addressed by the setup queue and the separate Delete behavior for panel-owned setup rows.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[Download or Add another] --> B[Panel starts setup]
  B --> C{Packages missing?}
  C -->|Yes| D[Password prompt and package install]
  C -->|No| E[Background model download]
  D -->|Success| E
  D -->|Cancelled| F[Restore download offer]
  D -->|Failed| G[Show reason and output link]
  E --> H[Engine status updates the model row]
Loading

Reviews (4) · Last reviewed commit: "Ship Podman and the NVIDIA container too..." · Reviewed by Greptile

Comment thread shell/plugins/agents/Panel.qml Resolved
Comment thread shell/plugins/agents/Panel.qml Resolved
dhh and others added 2 commits November 14, 2026 17:18
Choosing another model in Add another › Local AI while one setup was still
installing Podman did nothing. It now waits on a line of its own and starts
once the first hands off to the background; a failed or declined first
setup drops it too. Delete on a setup the panel owns no longer offers to
delete weights: it forgets a failure, drops one waiting, and leaves the one
starting alone.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* Ship Podman in the base install

Local models run in Podman, so a fresh install has it ready instead of
asking for a password on the first model setup. It's about 26 MiB on the
ISO with crun and its dependencies. Machines installed without it still get
it on first setup.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* Install the NVIDIA container toolkit with the NVIDIA driver

Local models reach the GPU through the CDI spec the toolkit writes, so an
NVIDIA machine now gets it alongside its driver instead of behind a password
prompt on the first model setup. The ISO's offline mirror and the N1x
package set carry it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* Drop the toolkit comment from the N1x package list

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* Stop saying Podman comes on first model setup

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
@dhh
dhh merged commit 0c6dc20 into quattro Nov 14, 2026
3 checks passed
@dhh
dhh deleted the local-ai-panel-setup branch November 14, 2026 16:25
dhh added a commit that referenced this pull request Nov 23, 2026
…ackages (#19769)

#18907 made them base packages, but machines installed before it only
get them when a model is first set up through omarchy models use.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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