PR #9631 review: new-workspace chats start on the picked reasoning effort

Summary

When you launched a chat from the New Workspace composer, the chat used the picked model, but the reasoning effort always fell back to Default. This happened for two reasons. The desktop dropped the effort for chat launches. The host's chatLaunchTarget also treated "chat + effort" as a terminal launch, and createChatSession never forwarded effortId. The PR fixes both sides. The effort is validated like a terminal launch and passed to chat.commands.createSession, also on the sandbox self-seed path. A host-version floor (2.0.9) stops a new desktop from sending the effort to an older remote host, which would open a terminal instead of a chat.

Verdict

Looks good The fix is correct and minimal on both sides, and the compatibility gate is sound. Both regression tests fail on the base and pass at the head, and the end-to-end journey works in the real desktop app. The findings below are nits and one release-coordination question.

Findings

Minor · release coupling

packages/shared/src/host-version.ts:125: CHAT_LAUNCH_EFFORT_MIN_HOST_VERSION = "2.0.9" is correct only if 2.0.9 is cut from a tree that contains this PR. If a 2.0.9 hotfix is cut from a release branch without it, a new desktop sends effort with surface: "chat" to that remote host. The host then opens a terminal, which is worse than today's "chat on Default".

Fix: Before you merge, check the version against the next planned release. Or bump the floor in the release PR that ships this change. A short line in the release runbook checklist also works.

Nit · readability

apps/desktop/src/renderer/routes/_authenticated/components/DashboardNewWorkspaceModal/components/NewWorkspaceScreen/NewWorkspaceScreen.tsx:774-777: The gate is an anonymous boolean expression, passed as the 9th positional argument of useSubmitWorkspace. At the call site, you cannot see what it means.

Fix: Hoist it to const launchHostAppliesChatEffort = hostId === machineId || hostLaunchesChatWithEffort(...) and pass the name. This hook already has 9 positional parameters, so an options object would be the better long-term shape.

Nit · follow-up

apps/mobile/screens/(authenticated)/hooks/useCreateTerminalWorkspace/useCreateTerminalWorkspace.ts:153: Mobile still strips the effort for chat launches. The PR description already lists this as a follow-up. A ticket would keep it from being lost.

Things I checked and found correct:

Evidence

Desktop (dev build at dba8c8f7, driven over CDP on port 9333, renderer localhost:3005)

I used real clicks and typing through the New Workspace composer: Device "This device", project "No project". In this sandbox, Claude is not signed in, so no turn ran ("Sign in to continue"). The model and effort are applied at ACP session start and are shown in the chat's own picker.

Composer with Opus High selected
1. The composer is set to Opus · High, in chat mode ("Full access" mode chip).
Chat pane showing Opus 5.5 High
2. After submit, a chat pane opens (not a terminal), and the composer chip shows Opus 5.5 · High.
Chat effort slider at High
3. The chat's own model picker shows the effort slider at aria-valuenow=3 of 5 (High).
Composer with Sonnet Low
4. Second run: the composer is set to Sonnet · Low.
Chat pane showing Sonnet 5.5 Low
5. The new chat opens on Sonnet 5.5 · Low, with the slider at aria-valuenow=1. The effort follows the pick and is not a remembered value.
Terminal launch when chat is off
6. Control: with "Open agents in chat" off (the default for this dev account), the same journey opens a terminal. ps showed claude --model opus --effort high …, so the terminal path is unchanged.
Open agents in chat setting
Setup: I turned on Settings → General → "Open agents in chat" for runs 1–5. The toggle reported aria-checked=true; this capture was taken mid-animation. This changed the local dev account's setting in this sandbox only.

I saw no tRPC BAD_REQUEST or uncaught errors in the desktop dev log during these runs.

Not run:

Questions for the author

Test / CI notes

WhatResult
bun test host-service agents.test.ts + sessions.test.ts84 pass, 0 fail
The same tests with agents.ts, create-chat-session.ts and session-service.ts reverted to base ce98da262 fail: "keeps a chat launch a chat when it asks for an effort" and "starts the chat on the model and effort the launch picked". The regression tests are real.
bun test shared host-version.test.ts15 pass
bun test desktop DashboardNewWorkspaceModal + workspace-creates70 pass
tsc --noEmit host-service, shared, desktopclean
GitHub CI at dba8c8f7All green: Lint, Typecheck, Test, Boot twice, Sherif, Version Sync, deploys, mobile build. E2E Mobile, Real sandbox and Production release were skipped.