Skip to content

Let Aiden change the color theme and the model for new chats - #623

Merged
sambitcreate merged 10 commits into
mainfrom
claude/project-thread-p5v2my-more-controls
Oct 28, 2026
Merged

sambitcreate merged 10 commits into
mainfrom
claude/project-thread-p5v2my-more-controls

Conversation

@sambitcreate

@sambitcreate sambitcreate commented Oct 27, 2026 •

Copy link
Copy Markdown
Owner

Requested by sbt · project thread

This was stacked on #617 (theme applies live) and #622 (honesty). Both have merged, and cf49359 merges main in, so the diff is now this PR's own work. That merge kept both the new Skills-off e2e test from #621 and this PR's theme and model test in tests/e2e/app-controls.spec.ts, and both the workspace-files sync from #618 and this PR's new-chat model subscription in renderer/main/root-view.tsx.

What changes

Tool audit owner answer 4b: Aiden can now change the color theme and the model for new chats from chat. The owner skipped text size, because Aiden has no text size setting; Aiden points to View → Zoom for that.

  • Color theme (appearance.theme, Appearance card):

    • Offers the ten presets and makes the same light and dark replacement as picking a theme in Settings → Appearance.
    • When the current theme is custom, the agent must show the control so the person confirms, because a preset replaces custom colors.
  • Model for new chats (models.newChat, new models topic):

    • The value is provider::model, saved in lastProviderId/lastModel.
    • Only visible models of ready providers are accepted. The card offers pinned and recent models first, at most 20.
    • The host broadcasts settings:new-chat-model-changed so open windows switch their new-chat model at once.
    • A pick in a window now also updates the host's copy, so the card and paired phones are current.
  • Phones keep the v1 vocabulary: iOS and Android reject a whole card with an unknown row or topic, so:

    • Remote snapshots omit the new rows;
    • aiden_show_controls in phone chats offers only the v1 topics;
    • a models card in a desktop chat reaches phones as its text fallback.

    No Remote protocol revision and no native change.

  • The CLI hides the new rows: it has no new-chat model, and its appearance card shows only the terminal theme.

  • The model select keeps long model names on one line.

  • Help text and app guidance now list these as changeable.

  • Docs:

    • docs/plans/aiden-app-knowledge-actions-plan.md update note;
    • docs/aiden-remote-api-v1.md note on desktop-only controls.

Tests

  • app-controls-core.test.ts:
    • model choices: ready, visible, pinned and recent first;
    • leaving a custom theme needs a click;
    • an unknown model is refused;
    • phones get only the v1 rows.
  • config-store-core.test.ts:
    • the theme control writes both preset variants and keeps the other appearance choices;
    • the model control writes lastProviderId/lastModel and nothing else.
  • aiden-remote-chats.test.ts: phones get the v1 cards; a models card arrives as text.
  • use-model-selection.test.ts: a host change reaches the window; a pick reaches the host once.
  • New e2e in app-controls.spec.ts: aiden_set_preference sets Moss and a second model; html[data-theme] becomes moss and the window's new-chat model follows without a reload. The window-follow assertion fails without the fix (received aiden-e2e-vision).
  • Ran locally:
    • test:app-controls, test:provider-model-catalog, test:command-system, test:bots, plus Remote protocol and chats tests;
    • type-check, type-check:e2e, eslint;
    • app-controls.spec.ts e2e;
    • CLI parity: 87 pass, and the 2 Remote HTTPS failures are the container's missing IPv6.
  • After the cf49359 merge: type-check, type-check:e2e, test:app-controls, the model-selection, Remote chats and workspace-files sync tests, and all 3 tests in app-controls.spec.ts (built, under xvfb) pass.

Flaky tests

Both on cf49359, run 40759372114. This PR changes neither area. Failed jobs get one rerun once the run finishes.

Light and dark screenshots are in the project thread.

🤖 Generated with Claude Code

https://claude.ai/code/session_018VA6RJBx7KEMfx6whsfUge

…to claude/project-thread-p5v2my-more-controls
New desktop app controls: Color theme (the ten presets, same change as
Settings → Appearance; leaving a custom theme needs the person's click)
and Model for new chats (a new "models" topic; only visible models of
ready providers). Open windows follow a new-chat model the host changes,
and a pick in a window now updates the host's copy. Paired phones keep
the v1 control vocabulary: the new rows and topic never reach them, and a
models card arrives as its text. The earlier "WIP controls" commit is
part of this change.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018VA6RJBx7KEMfx6whsfUge
@sambitcreate sambitcreate self-assigned this Oct 27, 2026
@very-hermes-bot

very-hermes-bot commented Oct 27, 2026 •

Copy link
Copy Markdown
Collaborator

Hermes Review Bot

Confidence: 5

Engine: agy/gemini-3.8-flash-high
Review mode: full
Head: cf49359a5496e5e54a7ccdb37b560151429da1d1
Generated: 2026-10-28T21:14:50+00:00
Reviews: 1

Summary

Aiden can now inspect and change both the color theme and the default model for new chats through chat tools and interactive settings panels. The implementation exposes appearance.theme and models.newChat within the app controls service, mirrors window-level model picks to the host's lastProviderId/lastModel fields via IPC notifications, and disconnects ordinary message sends from overwriting the new-chat default. Paired mobile devices retain the v1 card vocabulary without protocol changes because remote card projections omit the new controls and downgrade models cards to plain text fallbacks. Maintainers should double-check that third-party integrations or background services relying on lastProviderId/lastModel as the "most recently active chat model" expect it to now consistently represent the configured default for new chats.

Confidence Score: 5/5

Full end-to-end trace completed across main process IPC handlers, settings lease mutations, renderer state synchronization (localStorage and React hooks), CLI isolation, and mobile Remote protocol compatibility checks.

📁 Important Files Changed
  • main/services/app-controls-core.ts: Adds newChatModelChoices, policy rules for theme and model controls (requiring foreground confirmation when replacing custom colors), and filtering out desktop-only controls for remote clients.
  • main/services/app-controls-main.ts: Hooks configured providers into the controls service and broadcasts settings:new-chat-model-changed to open windows upon mutation.
  • main/services/config-store-core.ts: Handles atomic updates for appearance.theme and models.newChat within the settings mutation lease.
  • main/handlers/chat.ts & main/services/chat-generation-start.ts: Removes rememberSelection, preventing active chat turns from overwriting the default model for new chats.
  • renderer/lib/use-model-selection.ts & renderer/main/root-view.tsx: Syncs window model selection with the host at startup, writes user picks to host settings, and subscribes to host-driven new-chat model changes.
  • main/services/aiden-remote-chats.ts: Filters models cards from paired phone projections, projecting them as fallback text so v1 mobile clients never receive unknown card topics.
  • renderer/components/app-controls-panel.tsx: Adjusts select control widths and handles truncation for long model names.
  • tests/e2e/app-controls.spec.ts: Adds end-to-end coverage confirming live theme application (data-theme="moss") and window model synchronization without page reload.

Findings

No findings.

Sequence Diagram

sequenceDiagram
    participant User
    participant Renderer as Desktop Window
    participant Host as Main Process
    participant Store as ConfigStore

    alt Aiden or Card updates new-chat model
        User->>Host: aiden_set_preference / Card click ("models.newChat")
        Host->>Store: updateAppControl("models.newChat")
        Store-->>Host: saved (lastProviderId, lastModel)
        Host-)Renderer: broadcast("settings:new-chat-model-changed")
        Renderer->>Renderer: persistModelSelection (localStorage & React state)
    else User selects model in composer
        User->>Renderer: Select model in composer
        Renderer->>Renderer: persistModelSelection (localStorage & React state)
        Renderer-)Host: settings:set({ lastProviderId, lastModel })
        Host->>Store: setSettings(...)
    end
Loading
[]

Last reviewed commit: cf49359a5496
Reviews (1) · Comment /hermes review to trigger a new review · /hermes review full for full re-review

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Important

The new-chat model control can report success without changing the desktop default, and it accepts non-chat models that the normal picker excludes.

Reviewed changes Reviewed the full PR, including the stacked live-appearance and capability-honesty changes.

  • Conversational controls: Adds color-theme presets and a model-for-new-chats control with persistence, availability checks, and foreground confirmation for replacing custom colors.
  • Live synchronization: Applies host appearance changes to open windows and synchronizes model-control changes with renderer defaults.
  • Client compatibility: Keeps the existing phone vocabulary by filtering new controls and projecting unsupported cards as text; preserves CLI-specific controls.
  • Capability guidance: Updates offline help, tool-aware system prompts, Bot settings-file protection, and Live screen-control guidance.
  • Verification: Focused TypeScript suites and application/e2e type checks pass. Both Electron specs are collected, but runtime e2e and iOS XCTest were not run here; Android focused tests timed out after 120000ms, including an offline attempt.

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using gpt-6.1-sol | 𝕏

Comment thread main/services/app-controls-core.ts Resolved
Comment thread main/services/app-controls-core.ts Resolved
…at models

- A desktop send no longer writes lastProviderId/lastModel. A send in an
  existing chat used that chat's own model and overwrote the default the
  control reported, so asking for that model returned already_set while new
  chats still used the window's pick. Each window now also brings the host
  copy in line with its pick at startup.
- The control offers and accepts only chat models, using the model picker's
  isNonChatModel rule, so embedding and reranking ids from a custom endpoint
  are left out.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018VA6RJBx7KEMfx6whsfUge
…esty' into claude/project-thread-p5v2my-more-controls

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Important

Startup synchronization can overwrite a newer model choice, and the new CLI settings fence leaves active host configuration writable by Bot file tools.

Reviewed changes Reviewed the changes since the previous Pullfrog review at 07d316a, including the fixes and newly merged CLI protection.

  • Separated default persistence: Removed send-time writes to the new-chat model and added startup synchronization from the desktop selection to the host.
  • Filtered model eligibility: Applied the shared non-chat model filter to both offered options and accepted values, including provider metadata.
  • Extended CLI protection: Installed a protected-root list for CLI Bot file tools covering named settings and credential locations.
  • Corrected read-only guidance: Distinguished chats that can read live settings from those that cannot read or change them.

Validation: 177 focused tests passed across conversational controls, model selection, generation start, Assistant prompts, Bot file tools, and configuration persistence. Application and e2e type checks passed; separate behavioral probes reproduced both findings below. Electron runtime and native mobile suites were not rerun for this delta.

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using gpt-6.1-sol | 𝕏

Comment thread renderer/lib/use-model-selection.ts Resolved
Comment thread main/services/bot-protected-settings.ts Resolved

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes Reviewed the delta since the previous Pullfrog review at fb1f0d3, including both fixes and the expanded desktop Bot-storage protection.

  • Preserved newer model choices: Moved the startup selection read after the host response so an intervening picker change or host notification is not overwritten by the captured startup value.
  • Expanded Bot-file protection: Added CLI Telegram configuration, authority anchors and Bot-service storage to the fence, and protected desktop Bot definitions and service storage.
  • Kept Bot homes writable: Added bounded directory exceptions so ordinary artifacts in homes/ remain writable while host-owned Bot metadata stays protected.
  • Extended behavioral coverage: Added pending-startup-read coverage and write/edit rejection checks for existing and not-yet-created host configuration files.

Validation: 49 focused tests passed, the native file mutator built successfully, and application TypeScript passed. Separate probes using the real persistence and notification helpers verified both pending-read interleavings. Electron runtime and native mobile suites were not rerun for this delta; hosted CI was still pending when inspected.

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes Reviewed the main merge since the previous Pullfrog review at 9affd06, focusing on integration with the theme and new-chat model controls.

  • Preserved renderer synchronization: Kept the new-chat model subscription and startup mirroring alongside main's workspace-file synchronization.
  • Retained behavioral coverage: Preserved all three app-controls e2e tests, including Skills-off completion and live theme/model changes.
  • Checked appearance admission: Verified that the inherited pending-Appearance guard covers the new theme control without interfering with model-default changes.

Validation: 234 focused tests passed across controls, model selection, workspace synchronization, Remote chats, appearance and configuration persistence. Application and e2e TypeScript checks passed, and Playwright collected all three app-controls specs. Electron runtime and native mobile suites were not rerun; hosted CI was still pending at inspection.

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

@sambitcreate
sambitcreate merged commit f186f36 into main Oct 28, 2026
45 of 50 checks passed
@sambitcreate
sambitcreate deleted the claude/project-thread-p5v2my-more-controls branch October 28, 2026 23:42
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.

3 participants