Repository navigation
feat(onboarding): recommend plugins and skills from installed apps - #109668
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b2213c6be9
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| workspaceDir, | ||
| }); | ||
| const { setupAppRecommendations } = await import("./setup.app-recommendations.js"); | ||
| nextConfig = await setupAppRecommendations({ |
There was a problem hiding this comment.
Run channel recommendations before channel setup
When a detected macOS app matches an official channel candidate, this recommendation step runs after setupChannels has already finished, and setupAppRecommendations only installs/enables the plugin via ensureOnboardingPluginInstalled. Selecting a Slack/Discord-style recommendation therefore leaves the channel plugin present but never runs the channel setup adapter/account/DM-policy prompts, so the recommended channel is not usable until the user manually reruns channel setup. Route channel candidates back through channel setup or run this before the channel setup step can configure them.
Useful? React with 👍 / 👎.
|
Codex review: needs real behavior proof before merge. Reviewed July 17, 2026, 8:58 AM ET / 12:58 UTC. Summary PR surface: Source +1098, Tests +1017, Docs +14, Generated +2. Total +2131 across 47 files. Reproducibility: not applicable. as a bug reproduction question; this is a new feature, and the reported live run is not an inspectable current-head artifact. Review metrics: 2 noteworthy metrics.
Stored data model Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Proof guidance:
Risk before merge
Maintainer options:
Next step before merge
Maintainer decision needed
Security Review findings
Review detailsBest possible solution: Keep recommendation discovery local until explicit consent, transmit only the minimum disclosed app labels, omit the unused remote inventory surface unless separately approved, filter installed items, configure channel selections fully, and apply changes before the final Gateway restart. Do we have a high-confidence way to reproduce the issue? Not applicable as a bug reproduction question; this is a new feature, and the reported live run is not an inspectable current-head artifact. Is this the best way to solve the issue? No. The discovery idea is promising, but the safest maintainable version needs an explicit consent boundary, minimized metadata, correct channel and duplicate handling, and service restart ordering; the unused remote inventory API should be split or removed. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 62407b36d780. Label changesLabel justifications:
Evidence reviewedPR surface: Source +1098, Tests +1017, Docs +14, Generated +2. Total +2131 across 47 files. View PR surface stats
Security concerns:
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
Review history (3 earlier review cycles)
|
Scan installed macOS apps during classic onboarding (TCC-free), gather candidates from official catalogs + ClawHub search, let the configured model pick genuine matches, and offer an opt-in multiselect install step. Adds a device.apps node-host command (default-off sharing, Android-parity envelope) so remote gateways can request a paired Mac's inventory, and a wizard.appRecommendations kill switch. Custom setup-inference completions no longer inherit the 32-token verification-probe output cap.
b2213c6 to
0e19e65
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 0e19e65491
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| ...result.matches.map((match, index) => ({ | ||
| value: selectionValue(index), | ||
| label: t("wizard.appRecommendations.option", { | ||
| name: match.candidate.displayName, | ||
| reason: match.reason, |
There was a problem hiding this comment.
Filter already-installed app recommendations
When classic onboarding reaches this step, setupSkills and setupOfficialPluginInstalls have already run, so result.matches can include a skill or plugin the user just installed earlier in the same wizard (or already had in the workspace/config). These lines still offer every match, and recommended ones are preselected, so accepting defaults can re-run installSkillFromClawHub/ensureOnboardingPluginInstalled; existing ClawHub skills fail with “Skill already exists…”, while plugins can be reinstalled or re-enabled unnecessarily. Filter matches against the current plugin config/install records and tracked workspace skills before building the multiselect.
Useful? React with 👍 / 👎.
…otion Third-party ClawHub skills are never pre-selected regardless of model tier (publisher-controlled listing text reaches the matcher prompt and could promote itself); their labels now say they install third-party code. Installed-app scans follow symlinked .app bundles. Matcher output stays bounded by the resolved model's own maxTokens budget (documented invariant).
Real catalog entries are package manifests without a top-level id; keying the candidate map and channel/provider classification by entry.id collapsed the whole official catalog into one undefined-keyed entry, so no official plugin or channel was ever recommended. Regression test runs against the bundled catalogs.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 2847cf193a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| appRecommendations: { | ||
| catalogEntryMissing: "Official plugin catalog entry is unavailable.", | ||
| detected: "Detected apps: {apps}", | ||
| disclosure: "App names were matched using your configured model and ClawHub search.", |
There was a problem hiding this comment.
Disclose bundle IDs sent to the matcher
When a scanned macOS app has a bundle ID, the matcher prompt serializes group.app from src/system-agent/setup-app-recommendations.ts, so the configured model receives both the label and bundleId; this onboarding copy tells users only app names are matched through the model and ClawHub. That sends more identifying app metadata than disclosed, so either strip bundleId before building the prompt or update the progress/results disclosure before enabling the scan.
Useful? React with 👍 / 👎.
Split the guided-onboarding test into a self-contained custodian suite to stay under max-lines. Narrow app-recommendation exports (drop dead node-payload normalizer, unexport internal types/helpers, route candidate tests through the public API), replace map-spread with a helper, unexport device.apps result types, add installedAppsSharing to node-host migration expectations, cast the wizard multiselect mock, and regenerate the docs map.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 3990327e99
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const recommendedConfig = await runAppRecommendations({ | ||
| config: persistedConfig, | ||
| prompter, | ||
| runtime, | ||
| workspaceDir: workspace, |
There was a problem hiding this comment.
Apply app recommendations before Gateway restart
In guided hatch onboarding, this runs after applySystemAgentSetup has already installed/restarted the Gateway service (src/system-agent/setup-apply.ts:550-565). If accepting a recommendation adds a plugin or load path, the later write at src/commands/onboard-guided.ts:686-690 only updates openclaw.json; the live Gateway and immediately launched TUI keep the pre-recommendation plugin registry until the user manually restarts. Move recommendations before setup apply/final service restart, or restart/refresh the Gateway after writing the merged config.
Useful? React with 👍 / 👎.
|
Merged via squash.
|
…penclaw#109668) * feat(onboarding): recommend plugins and skills from installed apps Scan installed macOS apps during classic onboarding (TCC-free), gather candidates from official catalogs + ClawHub search, let the configured model pick genuine matches, and offer an opt-in multiselect install step. Adds a device.apps node-host command (default-off sharing, Android-parity envelope) so remote gateways can request a paired Mac's inventory, and a wizard.appRecommendations kill switch. Custom setup-inference completions no longer inherit the 32-token verification-probe output cap. * feat(onboarding): recommend apps in guided flow * fix(onboarding): harden app recommendations against ClawHub self-promotion Third-party ClawHub skills are never pre-selected regardless of model tier (publisher-controlled listing text reaches the matcher prompt and could promote itself); their labels now say they install third-party code. Installed-app scans follow symlinked .app bundles. Matcher output stays bounded by the resolved model's own maxTokens budget (documented invariant). * fix(onboarding): key official catalog candidates by resolved plugin id Real catalog entries are package manifests without a top-level id; keying the candidate map and channel/provider classification by entry.id collapsed the whole official catalog into one undefined-keyed entry, so no official plugin or channel was ever recommended. Regression test runs against the bundled catalogs. * fix(onboarding): satisfy lint, types, deadcode, and migration gates Split the guided-onboarding test into a self-contained custodian suite to stay under max-lines. Narrow app-recommendation exports (drop dead node-payload normalizer, unexport internal types/helpers, route candidate tests through the public API), replace map-spread with a helper, unexport device.apps result types, add installedAppsSharing to node-host migration expectations, cast the wizard multiselect mock, and regenerate the docs map. * test(onboarding): register new live test in the shard classifier
…penclaw#109668) * feat(onboarding): recommend plugins and skills from installed apps Scan installed macOS apps during classic onboarding (TCC-free), gather candidates from official catalogs + ClawHub search, let the configured model pick genuine matches, and offer an opt-in multiselect install step. Adds a device.apps node-host command (default-off sharing, Android-parity envelope) so remote gateways can request a paired Mac's inventory, and a wizard.appRecommendations kill switch. Custom setup-inference completions no longer inherit the 32-token verification-probe output cap. * feat(onboarding): recommend apps in guided flow * fix(onboarding): harden app recommendations against ClawHub self-promotion Third-party ClawHub skills are never pre-selected regardless of model tier (publisher-controlled listing text reaches the matcher prompt and could promote itself); their labels now say they install third-party code. Installed-app scans follow symlinked .app bundles. Matcher output stays bounded by the resolved model's own maxTokens budget (documented invariant). * fix(onboarding): key official catalog candidates by resolved plugin id Real catalog entries are package manifests without a top-level id; keying the candidate map and channel/provider classification by entry.id collapsed the whole official catalog into one undefined-keyed entry, so no official plugin or channel was ever recommended. Regression test runs against the bundled catalogs. * fix(onboarding): satisfy lint, types, deadcode, and migration gates Split the guided-onboarding test into a self-contained custodian suite to stay under max-lines. Narrow app-recommendation exports (drop dead node-payload normalizer, unexport internal types/helpers, route candidate tests through the public API), replace map-spread with a helper, unexport device.apps result types, add installedAppsSharing to node-host migration expectations, cast the wizard multiselect mock, and regenerate the docs map. * test(onboarding): register new live test in the shard classifier
What Problem This Solves
New users finish onboarding with a bare install even when their Mac is full of apps
OpenClaw already has plugins and skills for (Notion, Obsidian, Slack, 1Password,
Things, …). Nothing connects "what is installed on this machine" with "what OpenClaw
can do with it", so discovery is manual catalog browsing.
Why This Change Was Made
Adds installed-app plugin/skill recommendations to
openclaw onboard:/Applications,~/Applications, and a small allowlist of/System/Applications(TCC-free: no permission dialog can fire —readdir,Launch Services, and Spotlight metadata are unprotected paths; verified on a real
machine).
catalogs plus top-3 ClawHub skill search hits per app (concurrency 4, 5s/request,
20s overall budget; failures degrade to catalog-only candidates).
model receives app names + candidate descriptions and returns genuine matches with
a tier (
recommended/optional) and a short reason. No curated bundle-id map tomaintain; the model rejects coincidental name overlaps (naive matching paired
Linear→
line, Zed→zededa, Parallels→parallelin prototyping — the live testasserts these traps stay dead).
no consent prompt before the scan, but the scanning progress line and the results
note both disclose that app names are matched using the configured model and
ClawHub search, and
wizard.appRecommendations: falsedisables the featureentirely. The results step lists detected apps and installs only what the user
selects (recommended tier pre-checked, explicit skip).
device.appsinvoke commandAndroid already ships (same envelope; macOS emits
label/bundleIdwhere Androidemits
label/packageName). Node-side sharing is off by default (privacyparity with Android's consent toggle) via node-host config /
--share-installed-apps; disabled invokes return the typedINSTALLED_APPS_SHARING_DISABLEDerror. The gateway allowlists the command formacOS nodes and strips it everywhere when the kill switch is off. Local onboarding
scans directly and does not use the node command.
Also fixes a latent bug this feature exposed:
runSetupInferenceTestapplied the32-token verification-probe output cap (
SETUP_INFERENCE_TEST_MAX_TOKENS) to everycompletion, so any custom prompt longer than a few words returned a reasoning-only
turn and "Agent couldn't generate a response." Custom-prompt completions now use the
model's own output budget; the probe keeps its cap.
Prior art: Setapp is the only mainstream product doing install-scan → recommendation;
its trust framing (scan silently, show the detected list, act opt-in) is what this
follows, with explicit disclosure because app names do leave the machine.
User Impact
openclaw onboard(non-quickstart, macOS, working model route) gains one optionalstep: detected apps → tiered multiselect → install. Zero matches or any failure
(offline ClawHub, model error, malformed model output) skips the step silently;
onboarding never blocks on this feature.
wizard.appRecommendations(default enabled) to disable.(
--share-installed-apps, persisted in node-host config, default off).Evidence
/api/v1/search+ real OpenAIgpt-5.6-luna):OPENCLAW_LIVE_TEST=1 OPENAI_API_KEY=… pnpm test:live src/system-agent/setup-app-recommendations.live.test.ts— passed (76s). Fixtureinventory of 9 real apps incl. traps; model matched Notion→
notion,Obsidian→
obsidian, Slack→slack-api, Linear→linear, Things→things-mac,1Password→
1passwordand produced none of the trap pairings.reader injection; candidate dedupe + ClawHub failure degradation; matcher zod
filtering incl. fenced-JSON/extra-key/overlong-reason tolerance; node
device.appsgating + Android-parity envelope; gateway allowlist + kill-switch stripping;
node-host config persistence; wizard gating/pre-check/skip/install paths
(
pnpm test src/infra/installed-apps.test.ts src/system-agent/setup-app-recommendations.test.ts src/node-host/invoke-device-apps.test.ts src/node-host/runtime.test.ts src/node-host/config.test.ts src/wizard/setup.app-recommendations.test.ts src/gateway/node-command-policy.test.ts src/wizard/setup.test.ts src/system-agent/setup-inference.test.ts).pnpm tsgo,pnpm config:schema:check,pnpm docs:check-mdx,git diff --check—all green.
plutil dependency in the scanner test; unbounded ClawHub phase → 20s budget). The
remaining consent-first finding is consciously rejected as the documented product
decision (default-on with disclosure + kill switch); an inline comment records it.