feat(desktop): mid-turn steer, session memory, mode persistence, and desktop UX improvements#3145
Open
JesonChou wants to merge 3 commits into
Open
feat(desktop): mid-turn steer, session memory, mode persistence, and desktop UX improvements#3145JesonChou wants to merge 3 commits into
JesonChou wants to merge 3 commits into
Conversation
…ew caching BranchMeta gains PlanMode/Bypass/Model/Preview/Turns fields; SaveBranchMetaFlags persists without touching UpdatedAt, keeping mode/model switches from reordering the session list. previewSession reads from .meta cache (O(1) sidebar loads). Agent gains FIFO steer queue consumed at iteration boundaries; each steer is appended to session, preserving the prefix cache. New Steer event kind fires on consumption. Controller.Steer/ SteerConsumed delegate to executor. Controller: SetPlanMode/SetBypass persist to session meta; lazy session path creation on first turn; gated SessionEnd; Resume restores saved PlanMode/Bypass from meta; Run path includes Compose(input) for memory injection. Includes 8 steer tests (FIFO, gating, persistence, events).
…ion quality CLI: Enter during running steers instead of ignoring input; slash/bang/memory commands are rejected; staged indicator shown above composer. Steer events render as confirm lines. mcpTools/isMCPToolName/isMCPPromptName for MCP discovery. Plugin: ToolRef type and Host.Tools() expose MCP tools from connected servers for slash-menu integration. Desktop Go: ListSessions 500ms TTL cache + dedup by display key, async cleanup; ResumeSession checks saved model and switches via switchToModel, then auto-pins via Current sort; lazy session-path creation in buildController; HistoryMessage tool-call fields with toolCallByID mapping; Meta.Plan for frontend mode sync; SetModel persists model to meta; App.Steer wired to controller. bridge.ts: Steer(text) binding in AppBindings + mock.
…esume, and steer Frontend: useController history reducer and HistoryPanel previewMessagesToItems now render tool messages as ToolCards; types.ts adds toolName/toolArgs/toolOutput/toolId/toolTruncated to HistoryMessage. sessionTime shows full date+time with seconds. Theme: root dark/light mode + 8 theme-style blocks receive full color palette overhaul (blue accent #7dd3fc, deep-blue surfaces, clean light neutrals); swatch colors and sidebar grid updated. Session: ResumeSession auto-pins current session via Current sort; list cache invalidated on resume and async model switch. Steer: runningRef (useRef) replaces stale state.running in handleSend closure, fixing mid-turn steer delivery. Windows: HideWindow adds CREATE_NEW_PROCESS_GROUP to suppress child console flashes from MCP/LSP/codegraph subprocesses.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds mid-turn steer (inject guidance while agent is running), session-scoped
model/mode memory, preview caching, and several desktop UX fixes.
Mid-turn steer
Steerevent kind for frontend confirmationrunningRefSession memory & mode persistence
BranchMetagainsPlanMode/Bypass/Model/Preview/TurnsfieldsSaveBranchMetaFlagspersists without touchingUpdatedAtpreviewSessionreads from.metacache (O(1) sidebar)SetPlanMode/SetBypasspersist to session metaResumeSessionrestores saved model and plan/bypass modesMCP tools in slash menu
plugin.ToolReftype +Host.Tools()method for MCP tool discoveryDesktop UX improvements
CREATE_NEW_PROCESS_GROUPsuppresses child console flashesrunningReffixes stale closure inhandleSendVerification
go build ./internal/...go test ./internal/agent/...wails build