Repository navigation
fix(setup): activate the exact prepared local model - #119050
Conversation
|
@clawsweeper review |
|
🦞👀 Command router queued. I will update this comment with the next step. |
|
@clawsweeper review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
@clawsweeper re-review |
|
Codex review: needs maintainer review before merge. Reviewed August 4, 2026, 2:34 AM ET / 06:34 UTC. ClawSweeper reviewWhat this changesThe PR carries a provider-prepared local model through the Gateway wizard so web and macOS activate that exact model instead of rediscovering a local candidate. Merge readinessKeep this maintainer-owned PR open for final merge review: the exact-model handoff addresses the current setup failure without a new actionable finding, while Priority: P1 Review scores
Verification
How this fits togetherGuided local-model setup runs provider-owned preparation through the Gateway wizard, then web or macOS verifies a model before showing a ready state. This change preserves the provider-selected route across that handoff. flowchart LR
A[Guided local setup] --> B[Provider prepares exact model]
B --> C[Gateway wizard terminal result]
C --> D[Web or macOS client]
D --> E[Exact model activation]
E --> F[Verified ready state]
Decision needed
Why: The patch crosses provider setup, Gateway protocol, and native-client activation; its protected maintainer status requires an explicit human merge decision despite no code finding. Before merge
Agent review detailsSecurityNone. PR surfaceSource +144, Tests +187, Other +190. Total +521 across 27 files. View PR surface stats
Review metrics
Stored data modelPersistent data-model change detected: Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Keep the optional wizard handoff and old-Gateway detection fallback, then land after exact-head macOS validation confirms the generated client contract. Do we have a high-confidence way to reproduce the issue? Yes—source reproduction is high confidence: current main discards the prepared model at the Gateway terminal handoff, then the client re-detects a candidate; an installed but idle Ollama model is intentionally absent from that ambient discovery. Is this the best way to solve the issue? Yes—the provider records the authoritative selected model at its producer boundary, and clients activate that route directly while retaining the older-Gateway fallback instead of guessing from rediscovery. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 52c9448cb505. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
History |
* origin/main: test(qa): prove agent tool approval controls (#119029) docs(agents): require exact-head ClawSweeper re-review after post-review pushes (#119069) fix(qa): provision ffmpeg for Playwright scenarios (#119064) test(qa): repair scenario catalog baselines (#119062) test(qa): prove agent session scope continuity (#119032) test(qa): prove workspace mutation tools (#119021) fix(cli): honor local port in gateway call (#119046) test(xai): cover playback mark overflow fix(xai): bound realtime playback marks
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. |
|
@clawsweeper re-review |
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
@clawsweeper re-review |
* origin/main: test(qa): cover packaged browser profiles (#119043)
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
* origin/main: fix: preserve live updater failure diagnostics (#119096) fix: recover new-session models through Gateway startup (#119120) test(qa): cover instruction profile artifacts (#119078) fix(telegram): record automatic delivery message ids test(qa): cover memory promotion safety (#119093) test(qa): prove overflow compaction pruning (#119033) fix(tool-search): preserve deferred MCP failures (#118363)
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
@clawsweeper re-review |
Closes #119049
What Problem This Solves
Fixes an issue where users completing guided local-model setup could see a misleading provider-not-ready failure when the prepared model was installed but idle, or could activate a different model when multiple local models were available.
Why This Change Was Made
Provider-owned setup already knows the exact model it prepared. This change preserves that model reference through the additive terminal wizard result and activates that exact route before showing success.
Ollama keeps resident-only ambient discovery, so passive detection still cannot wake an idle model and cause surprise memory allocation. Explicit setup completion may activate only the model that setup configured or a model that is still resident.
User Impact
Ollama, LM Studio, and llama.cpp setup now hand the exact prepared model into live verification instead of re-detecting and guessing. Users see the existing verified-success dialog only after that model returns a real response.
Evidence
ollama/qwen3:0.6breturned exactlypongthroughopenclaw infer model run./api/pswas empty before the run and empty afterollama stop qwen3:0.6b.qwen3-0.6bloaded at 32K context, guided setup returned the exactlmstudio/qwen3-0.6broute and a direct completion returnedPong!; the model was unloaded and the server stopped afterward.git diff --check: clean.preparedModelRefwithout a second detection pass, older gateways retain the detection fallback, and provider choice IDs use the canonical percent-encoded kind on web and macOS.03ba86544e8f3051a1275a4b4a4646e10078a9f9in 30m38s (run).3e96bdc1573b6c96d55929afdce76e0110647f5c(run).8a682521136, including a signed merge from currentmain.git diff --checkpassed.Screenshots
This patch changes the setup handoff rather than layout. The current Models capture is byte-identical to the hosted asset below; the setup and verified-success dialogs render the same current UI states.
Local providers on the Models surface
Ollama setup mode
Exact model verified
Repair Notes
openclaw.setup.prepare.startpersisted provider setup but discardedagentModelOverride; the UI then reconstructed the outcome through ambient detection./api/psrediscovery after preparing an idle model.Disclosure
AI-assisted implementation. I reviewed the full diff, provider contracts, test coverage, and live behavior.