* feat(opencode): migrate OpenCode Manager to OpenCode 2
Port the backend lifecycle, generated plugins, event aggregation,
schedules, worktrees, provider credentials, MCP, config handling, the
frontend chat model, and the ocm CLI to OpenCode 2.
Adopt @opencode/client 2.0.15 as the single typed V2 API contract,
require OpenCode 2.0.0 or newer (pinned 2.0.15), and delete every
V1-only code path.
* refactor(opencode): reload config in place and drop v1 compatibility shims
Route config/skill/AGENTS.md changes through the OpenCode location reload
API instead of a full server restart, stop auto-resuming interrupted
sessions, remove the restart coordinator and v1 MCP/version shims, and pin
support to OpenCode >=2.0.15 <3.0.0. Adds integration-ready retries,
service-mode launch, ocm-cli repo proxy, and new frontend form/MCP helpers.
* refactor(opencode): consolidate v2 migration helpers and harden install, proxy, and session flows
- extract shared semver and model-ref utilities, reuse across version checks
- share the OpenCode release download script across Docker, entrypoint, dev setup
- unify install/upgrade failure recovery and guard externally managed OPENCODE_BIN
- scope the repo proxy location rewrite and surface ocm proxy errors
- rework frontend session projection, permission lookup, and cache invalidation
* fix(schedules): reject unavailable agents before creating a session
* feat(opencode): add ocm install, schedule agent fallback, and session move guards
* feat(config): support layered OpenCode config sources with revision-guarded saves
* refactor(config): harden multi-source OpenCode config handling
- extract shared config-source helpers and default source name
- reject shadowed removals with 409 and require sources/revision
- restart the server on reload with session resume
- mirror multiple host config files on import and warn on removals
- skip restart for mcp-only saves
- drop removedFields and CONFIG_PATCH_TIMEOUT_MS
* fix(config): return null when archiving broken OpenCode config fails
* refactor(config): make on-disk opencode.json the single source of truth
Make <workspace>/.config/opencode/opencode.json the only store for the active OpenCode configuration. One owner (opencode-config-file.ts) reads, validates, writes, archives, and seeds the file; one owner (opencode-config-apply.ts) decides how an edit is applied: restart pending, or a live patch with recovery. Settings routes, the internal assistant API, the health-watch supervisor, boot, and host import all go through them, so an edit that lands on the file without going through the database is visible immediately instead of at the next Manager boot.
Remove the named-config profiles. Migration 019 archives every opencode_configs row to .config/opencode-configs-archive/<name>.json, restores the default row to opencode.json when no file exists, then drops the table, its indexes, and repos.opencode_config_name. The /opencode-configs* and config/switch routes and the CreateConfigDialog/SwitchConfigDialog dialogs are gone, and the ocm tool gains GET/PUT /opencode-config backed by the same apply owner.
Harden the write path: serialize and atomically write config updates while preserving the file mode, keep withFileLock usable after a rejection, route reloadConfig's cleaned-config write through the file owner, stop boot from rewriting an existing valid config when importing state, prune the health-watch directory to its newest 20 entries, resolve archive paths with realpath, and share one frontend config query across dialogs.
* fix(mirror): canonicalize worktree paths before branch ownership check
* refactor(config): unify opencode config apply and rollback paths
- share one config route factory between public and internal mounts
- capture last-known-good before every config write and restore via one helper
- stop auto-restarting on save; flag restart-required fields and live-patch the rest
- add CONFIG_PATCH_TIMEOUT_MS for config patch requests
- extract canonicalPath helpers, health-watch artifact writer, and useProvidersWithModels hook
* refactor(model-state): use OpenCode state file as model state source of truth
* feat(sandbox): add KVM-backed agent sandboxing via microsandbox
* feat(sandbox): route host-shell surfaces into microVM via shell wrapper
* feat(sandbox): route host-shell surfaces into microVM via shell wrapper
* fix(sandbox): harden enforcement validation and backup handling
* fix(sandbox): bound lifecycle queue and harden install/backup paths
Bound the OpenCode supervisor lifecycle queue to one running plus one
pending operation so repeated restarts cannot stack unbounded HTTP
requests, while exempting stop() so shutdown is never dropped.
Reject enforcement backups that carry no recoverable removed sections,
matching the existing fail-closed handling of unparseable backups.
Install OpenCode through a private mktemp staging directory instead of
the predictable /tmp/opencode path.
Use named path/os imports in the files added by this branch.
* refactor(sandbox): remove OpenCode version allowlist gating under enforcement
* fix(settings): use resolved opencode binary and verify installed version
* refactor(sandbox): scope enforcement to agent bash tool only
* fix(sandbox): plan bash against factory directory and attest runtime tmpfs; align permission reply API
* fix(sandbox): pin neutral entrypoint and persist opencode upgrades across rebuilds
* fix(sandbox): align canonical spec with msb 0.6.8 runtime defaults
* feat(sandbox): show unwrapped sandboxed bash commands in message UI
* refactor(sandbox): pin shell shim to sandbox agent bash without rewriting commands
* feat(sandbox): route notifications through a host-side manager tool
* feat(sandbox): route all assistant capabilities through the ocm tool
Add an allow-listed request action to the generated ocm plugin so agents
reach settings, assistant reload, repos, git-info, workspaces, and
schedules through the tool instead of curling the internal API with a
bearer token, which is impossible under sandboxing.
Rewrite the curl-based skills to use the ocm request action and drop the
apiBaseUrl plumbing. Remove the now-unread .opencode/internal-token file
and the sandbox tmpfs mask that hid it; attestation now rejects any
tmpfs other than the runtime /tmp mount.
* fix(sidebar): wire new-session and new-schedule actions to every page
AssistantRedirect never registered a listener for the sidebar's
new-session event, so the desktop sidebar CTA on /assistant was a
no-op; the Schedules pages had the same gap for new-schedule.
Make useSidebarAction the single source of truth for action keys and
event dispatch, and warn when an action is dispatched with no mounted
handler so an unhandled CTA fails loudly instead of silently. Wire the
missing listeners to the existing per-page handlers.
* feat(sandbox): forward git credentials into the microVM and add sandbox guest image
* feat(sandbox): add git credential forwarding toggle to settings
* fix(oauth): forward upstream error categories to clients
The route boundary collapsed every upstream OAuth failure into a single
generic message, leaving all six mappings in the frontend's mapOAuthError
unreachable. Classify the failure and forward the matched category so
clients surface specific guidance.
Hoist the category list into @opencode-manager/shared as the single source
of truth for both sides; the frontend map is now typed
Record<OAuthErrorCategory, string> so a missing message fails typecheck.
* fix(oauth): match upstream provider auth errors by type instead of substrings
The previous mapping matched invented substrings ("invalid code", "expired",
"access denied", ...) that opencode never emits, so every real failure fell
through to the generic message and left the frontend map unreachable. It also
returned 500 for what upstream reports as 400.
opencode serialises these failures as a structured contract: ProviderAuthError
({ name, data }) or InvalidRequestError ({ _tag, message }) at HTTP 400. Model
both shapes in shared, discriminate on name/_tag, and forward the exact code
plus upstream detail so clients can map errors precisely.
Pin the contract to upstream with a compile-time conformance assertion against
@opencode-ai/sdk's generated ProviderOauthAuthorizeErrors[400] and
ProviderOauthCallbackErrors[400], added as a type-only devDependency. Any
added, removed, renamed, or retyped upstream variant now fails typecheck.
Also stop discarding the structured error at the frontend boundary, where
handleApiError rewrapped FetchError in a bare Error and dropped the code that
fetchWrapper had already parsed.
Verified against a live opencode 1.18.7 server: callback without a pending
authorization returns 400 ProviderAuthOauthMissing and is now forwarded as
such. Tests are pinned to captured responses, including the multiline message
BadRequest carries.
* fix(settings): persist recovered OpenCode config and accept provider api/npm fields
Applying a default config with auto-removed fields wrote the stripped content
to disk but left the stored record holding the rejected fields, so the database
and the on-disk config disagreed until the next write. Persist the applied
content and return 409 when the config disappears mid-recovery.
Add the provider-level api, npm, whitelist, and blacklist fields so valid
opencode provider configs survive a parse round-trip instead of being stripped.
* feat(repo): add graphical folder picker for adding local repositories
Previously, adding a local repository or scanning a folder in the
"Add Repository" dialog required typing an absolute filesystem path by
hand. This adds a navigable directory browser so users can select a
folder graphically instead.
Backend
- New shared Zod schemas (DirectoryEntry, BrowseDirectoryResponse,
BrowseDirectoryRequest) exported via shared/types and shared/schemas.
- New env var REPO_BROWSE_ROOT plus getBrowseRootPath() helper. It is
intentionally NOT defaulted to WORKSPACE_PATH: folder browsing is
opt-in and only works when an administrator explicitly configures a
root directory.
- New filesystem service (browseDirectory) that lists only directories
(hidden entries filtered), flags Git repositories, and confines all
access to the configured root:
- 501 when REPO_BROWSE_ROOT is not configured
- 403 on path traversal outside the root
- 404 for missing directories, 400 when the target is a file
- New authenticated route GET /api/filesystem/browse, registered under
the protected API group.
Frontend
- New api client browseDirectory() (uses fetchWrapper, so auth cookies
are sent).
- New DirectoryPickerDialog: navigate into subfolders, go up a level,
Git repos marked with an icon, and a "Select This Folder" action.
Retries are disabled so a configuration error is not polled
repeatedly.
- When browsing is disabled (501), the dialog shows a clear, actionable
message telling the user to set REPO_BROWSE_ROOT and to enter the
path manually in the meantime, instead of a generic error.
- AddRepoDialog gains a "Browse" button next to both the Local and
Folder path inputs; the chosen path is written back into the active
field.
Tests
- Service and route tests covering listing, Git-repo detection, hidden
filtering, parent navigation, and the 400/403/404/501 error paths.
Security note: because there is no default root, the picker is inert
until REPO_BROWSE_ROOT is set, and it can never escape that root.
* fix(fs): reject symlink escapes in directory browse
Canonicalize root and requested path with fs.realpath() and gate on
path.relative() so symlinks inside REPO_BROWSE_ROOT pointing outside
are rejected with 403 before fs.stat/fs.readdir follow them. Handles
root '/' correctly. Adds regression test for symlink escape.
* fix(ui): make directory picker fill dialog height
Replace grid content-start packing with explicit grid-rows tracks so
the directory list grows to fill the dialog and scrolls while the
header, path, and footer stay fixed. Drops the ineffective flex-1
from the grid child on the scroll container.
---------
Co-authored-by: Chris Scott <99081550+chriswritescode-dev@users.noreply.github.com>
Remove the long-lived synchronous POST to /session/{id}/message that produced
spurious "Connection Failed" banners on transient network blips; route every
send (normal, streaming-queue follow-up, message refresh) through prompt_async,
whose failure genuinely means not-delivered. Suppress network-kind banners
while SSE is disconnected or reconnecting (the header already shows that state);
session-kind banners still appear and reconcile clears confirmed prompts after
reconnect.
* feat: add schedule worktree isolation for running jobs in isolated worktrees
* feat: schedule worktree isolation for running jobs in isolated worktrees
* feat: show worktree/branch artifact counts in clear history confirmation
* feat: validate and select base branches for schedule worktrees
* feat: add repo rename capability with custom name field
Add a custom name field to repos, allowing users to set a display name
independent of the repo URL or path. Includes a migration, PATCH endpoint,
rename dialog, and display name consolidation.
- DB migration 014 adds name column to repos table
- PATCH /api/repos/:id endpoint with Zod validation
- RenameRepoDialog component with clear/reset support
- RepoRowActions gains Rename action in both dropdown and inline modes
- getRepoDisplayName() consolidated to accept a repo object and prefer name
- All repo name display call sites updated to use the new API
* fix: add DialogTitle to RenameRepoDialog for a11y compliance
* refactor: extract getRepoDisplayName to shared utils, fix schedule cache invalidation on rename
* feat: show variant label on model picker and add folder upload for agents/commands
- Replace three-dot variant menu trigger with selected variant label
- Add POST /api/settings/opencode-directory-files/install endpoint
- Upload agents/commands markdown folders into .config/opencode/{agents,commands}/
- Reload OpenCode server after upload so files are picked up
* fix: revalidate branch/git caches when mobile sheet opens and on vcs.branch.updated SSE
- add shared invalidateRepoGitCaches() helper for consistent invalidation
- revalidate repo list when mobile repo quick-switch sheet opens
- revalidate current repo when mobile More drawer opens
- revalidate repo/git caches when Source Control dialog opens
- handle vcs.branch.updated SSE event with optimistic cache update
- use helper in branch create/switch mutations in useGit and BranchesTab
* style: make variant selector look more like a button with chevron and compact sizing
* refactor: consolidate settings editors, add folder upload support, and clean up unused code
* refactor: consolidate settings editors, add folder upload support, and clean up unused code
* feat: add opencode-directory-files listing service and consolidate settings editors
* fix: distinguish scroll from tap in suggestion popups on touch devices
* refactor: consolidate settings editors and add DirectoryFilesList component
* refactor: target repo status cache updates only to affected batch entries
* refactor: streamline settings, git hooks, and query invalidation logic
* loop: stt-warmup completed after 6 iterations
* refactor: extract STT startup helpers and simplify audio recorder
* feat(stt): add energy-based VAD with silence gate and auto-stop
- New VoiceActivityDetector class: adaptive noise floor, per-frame RMS
classification, trailing-silence endpointing, configurable thresholds
- AudioWorkletProcessor computes RMS in existing flush loop and posts
{samples, rms} instead of a bare Int16Array
- AudioRecorder integrates VAD via handleVadFrame() in both worklet and
ScriptProcessor paths; auto-calls stop() on trailing silence; silence
gate in processRecording() fires onNoSpeech instead of sending empty
audio to the transcription API (fixes Whisper hallucination bug)
- useSTT wires setOnNoSpeech to reset isProcessing/isRecording cleanly
without surfacing an error
- computeRms() exported helper for ScriptProcessor fallback path
* fix(stt): clear processing state when stopping a silent recording
stopRecording() called recorder.stop() before setIsProcessing(true). For
a silent take the recorder synchronously fires onNoSpeech (which sets
processing false), so the subsequent setIsProcessing(true) won and the
voice overlay was stuck in the processing state forever.
Set processing before stop() so the recorder callback (onNoSpeech or
onDataAvailable) has the final say on the processing flag.
* fix(stt): always emit a terminal signal so the voice overlay never sticks
Two remaining stuck paths after the silent-stop fix:
- processRecording() early-returned without firing onNoSpeech when a take
had no captured audio (e.g. a quick start/stop under one worklet flush,
totalSamples === 0). Now any non-emitting path (empty audio or no
detected speech) fires onNoSpeech, while a genuine abort still returns
silently.
- stopRecording() set isProcessing true even when the recorder was no
longer recording (double-stop or post auto-stop), where stop() skips
processRecording entirely and nothing clears the flag. Guard the
external path on recorder state before entering processing.
* loop: mediarecorder-stt completed after 6 iterations
* refactor(stt): extract shared helpers and cleanup
* refactor(stt): add separate arm/disarm thresholds for voice swipe
* fix(stt): prevent default touch behavior on voice gesture handlers
* feat(stt): add audio-level speech detection before emitting data
* test(backend): replace better-sqlite3 test mock with node:sqlite
Reimplement the bun:sqlite test mock on top of node:sqlite with an
explicit BEGIN/COMMIT/ROLLBACK transaction wrapper.
* feat(assistant): self-configuring assistant mode
Add a self-editable assistant workspace and the APIs that support it:
- POST /assistant/reload disposes and re-bootstraps the assistant
instance (directory-scoped, rate-limited) so agent.md edits apply.
- Internal settings API accepts non-secret TTS/STT patches via
dedicated partial schemas.
- Strip the generated agent persona from opencode.json on repair so
user-customized agents are preserved across config recovery.
- Cache the last assistant session id to avoid redundant session
listing on launch.
* style(repo): align worktree and workspace tabs with primary/orange theme
* feat(session): paginated session list with infinite scroll and search
Replace per-directory useQueries session listing with a combined
cursor-based useInfiniteQuery (25 per page, loads more on scroll) and
move search into the API query instead of client-side filtering.
Add OpenCodeClient.listSessionsPage backed by the v2 /api/session
endpoint plus a toLegacySession adapter. Add invalidateSessionListCaches
to centralize session-list cache invalidation for infinite queries, and
update EventContext and useSSE to handle the new infinite-query cache
shape.
* fix(session): centralize and debounce session-list cache invalidation
Migrate ResetPermissionsDialog off the stale per-directory cache key
(which no longer matches the infinite-query key shape and hardcoded the
opencode URL) to the shared invalidateSessionListCaches helper, and drop
the now-unused repoDirectory prop and its call sites.
Debounce session-list invalidation on SSE session.updated events in
EventContext and useSSE so a burst of updates coalesces into a single
refetch instead of one per event. Fix the directory fallback in
EventContext getClient so it never returns the joined directory key.
* fix(permissions): scope instance dispose to the repo directory
Drop the session-list cache invalidation from ResetPermissionsDialog:
disposing the OpenCode instance does not change the persisted session
list, so the refetch was unnecessary, and the prior cache key no longer
matched the paginated shape.
Guard the reset-permissions route against an empty repo directory so it
never forwards /instance/dispose without a directory, which would
dispose the entire server instead of only the repo's instance.
* loop: worktree-tabs-2 completed after 4 iterations
* loop: server-env-vars completed after 7 iterations
* feat(worktree): add worktree tabs and server env vars settings
* refactor(worktree): multi-directory SSE support and workspace chip row
* feat(workspace): collapsible workspace manager and sibling filtering
* feat(workspace): workspace creation endpoint, refactored workspace manager, and tests
* refactor(frontend): unify workspace label and remove dead code
- extract shared workspaceLabel helper into api/repos and reuse in
WorkspaceManager and RepoDetail directoryLabels
- remove unused useSessions hook and subscribeToDirectory subscription
- drop redundant frontend workspace dedup now guaranteed by backend
- align WorktreeTabs empty-state test with create-workspace button
* fix: repo directory name collisions and custom directory support
Allow users to specify a custom directory name when adding a remote repo, preventing collisions when cloning a fork of an already-cloned repo.
- Add shared validation and normalization utilities (shared/src/utils/repo.ts)
for directory name sanitization, URL normalization, and path safety
- Replace duplicated sanitizeWorkspaceAliasSegment with shared helper
- Backend validates directoryName before use as filesystem path
- Frontend detects directory collisions with normalized URL comparison
- Move SSH credential setup after DB record creation
* add backend origin validation and base-directory collision detection
* fix potential ReDoS in repo url and directory name normalization
* chore: remove dead code and unused exports
* fix: preserve model form during config refresh
Signed-off-by: mehmet turac <mehmetturac@gmail.com>
* loop: model-select-fix completed after 11 iterations
* fix(frontend): show provider prefix for duplicate models in quick select dropdown
When the same model exists under multiple providers, show the provider name
for both entries so users can distinguish them. Detects duplicates by modelID
across all favorites and recents.
* refactor(frontend): replace useTallScrollContent with scroll visibility hook
* fix: harden mirror push rollback
* Remove Load button from skill cards, clicking card loads skill
* feat(backend): add plugin installation support and schema updates
* refactor(frontend): remove unused useHeaderScrollVisibility hook
* refactor(frontend): replace model dropdown with bottom sheet selector
Replace DropdownMenu-based ModelQuickSelect with a bottom sheet
implementation featuring favorites, recents, provider browsing, and
search. Remove onShowModelsDialog prop from PromptInput and
SessionDetail, using data attribute trigger instead. Fix ZodIssueCode
deprecation, input text color, and portal rendering for bottom sheet.
* fix(frontend): simplify session model restore and fix mobile swipe reset
* loop: single-source-models completed after 10 iterations
* refactor(frontend): add desktop sidebar layout to model quick select
* refactor(frontend): improve model selector with connected providers, favorites, and recent management
* fix(frontend): constrain model name width to prevent overflow in prompt input
* fix(frontend): adjust padding and styling in model quick select
* fix(frontend): add optimistic removal with rollback for recent models
---------
* fix: enable swipe-back suspension on more drawer and remove unused variable
* refactor(frontend): improve dialog component and settings navigation
* fix: disable route swipe suspension in MoreDrawer to prevent unintended navigation
* fix(frontend): enable swipe-back suspension on more drawer route
* refactor(frontend): improve mobile navigation drawer and tab bar
* feat: add schedules service and workspace hook with navigation updates
* chore: add workspace hook, schedules library, and tests
* fix: prevent MoreDrawer sentinel from undoing navigation
* feat: per-agent model selection and UI refinements (#217)
* feat: per-agent model selection and UI refinements
- Add agentModels store with setAgentModel/getAgentModel
- PromptInput uses session model priority and stores agent model on change
- useContextUsage derives model from assistant message instead of global
- Migrate sub-agent/subtask badges from purple to blue with refined styling
- Fix MoreDrawer sentinel to skip history-back on navigation
* refactor: improve per-agent model selection and task tool call status indicators
* feat: add repo management skill and internal repos API
* fix: improve assistant session launcher and UI components
* fix: update atomic-json test assertions
* refactor: split Assistant Mode instructions between AGENTS.md and assistant.md
* loop: todo-header-mobile completed after 3 iterations (#218)
* loop: stt-perf-1 completed after 5 iterations
* fix: load audio worklet per recording context
* fix: canonicalize assistant navigation routes
* fix: adjust scroll-up threshold for header visibility
* fix: update settings and skills handling with assistant redirect
* refactor: simplify context usage indicator and extract token sum helper
* feat: add currently selected model row to popover and fix responsive truncate
* feat: add persistent model state storage with database backend
- Create opencode_model_state table for storing user model preferences
- Implement database-backed model state management (recent, favorite, variant)
- Add atomic JSON file utilities with file locking for concurrent safety
- Migrate providers routes from file-based to database storage
- Add backfill migration to preserve existing model.json data
- Include comprehensive tests for model-state and atomic-json modules
- Refactor useSessionAgent hook to simplify agent/model resolution logic
- Update getFileApiUrl to use consistent query parameter approach
* fix: include workspace dependencies in Docker image
* fix: overlay workspace node_modules after source to prevent layer overwrite
* fix: ensure model state table exists for existing databases
* feat: add model state persistence and improve model selection sync
- Add setActiveModel to modelStore and useModelSelection for direct model updates
- Sync session agent model/variant to store when messages load
- Include model, agent, and variant in optimistic user messages
- Fix useSessionAgent to check isFetching during message loading
- Update env.ts to use getter for BASE_PATH for dynamic resolution
- Fix test environment variable from OPENCODE_WORKSPACE_PATH to WORKSPACE_PATH
* refactor(frontend): extract VoiceStatusOverlay component and improve swipe tracking
- Extract voice status overlay to dedicated VoiceStatusOverlay.tsx component
- Move pointer event handlers from button to container for larger swipe surface area
- Users can now initiate swipe gesture from anywhere in the container, not just the button
* refactor(frontend): add SSE delta support and improve status synchronization
- Add SSEMessagePartDeltaEvent type for streaming delta updates
- Add SSESessionCreatedEvent type for session creation events
- Implement directory filtering for SSE events to prevent cross-contamination
- Add version tracking for status snapshots to ignore stale responses
- Replace individual status updates with atomic replaceStatuses operation
- Refactor parts batcher to use unified operation queue with delta support
- Clear stale statuses on initial snapshot and directory changes
- Add tests for status snapshot clearing and stale response handling
* refactor: remove auto-restart from assistant mode and fix mobile sheet close behavior
Stop restarting OpenCode after assistant mode initialization since the
startup error logic is no longer needed. Also fix the repo quick switch
sheet to stay open when launched from the mobile tab bar, preventing
unwanted navigation away from the sheet.
* refactor(frontend): improve speech-to-text UI
* fix: sync model selection with OpenCode state
* feat(model): add favorites system for model selection
- Add toggleFavoriteModel API endpoint
- Add favorite toggle UI in ModelQuickSelect and ModelSelectDialog
- Show provider name prefix when model display names are ambiguous
- Fix directory scoping for getProviders API calls
feat(assistant): send welcome message on new session creation
- Send setup guidance message when creating new assistant session
---------
Co-authored-by: Chris Scott <>
* refactor: add desktop sidebar navigation and consolidate header actions
- Add DesktopSidebar component with collapsible navigation
- Add useDesktop and useSidebarAction hooks for sidebar state management
- Add useSidebarCollapsed hook with localStorage persistence and error handling
- Integrate sidebar into App layout with tooltip support
- Remove repoUrl and isRepoWorktree props from SourceControlPanel
- BranchesTab now fetches repo data internally using getRepo query
- Remove unused to prop from SidebarItem
- Simplify RepoList conditional rendering
- Add comprehensive test coverage for new components
* refactor: remove LSP status button and memory plugin status hook
- Delete LspStatusButton component and its test file
- Remove unused useMemoryPluginStatus hook from RepoDetail
- Clean up dead code as part of desktop header refactor
* feat: add assistant mode integration and fix test environment
- Add assistant-mode service for managing assistant workspace files (AGENTS.md, opencode.json)
- Add backend GET/POST routes for assistant-mode status and initialization
- Add AssistantRedirect page and useAssistantSessionLauncher hook
- Update mobile navigation to include Assistant tab (replaces Alerts)
- Fix React.act compatibility by setting NODE_ENV=test in vitest config
- Add shared Zod schemas for AssistantMode types and requests
* feat: enhance assistant mode with session list view and legacy config migration
- Add session list view for assistant mode with full workspace management
- Migrate legacy opencode.json permission format to granular permissions
- Enable assistant navigation from mobile tab bar and repo switcher
- Preserve assistant context in session routes via query params
- Auto-restart OpenCode server after assistant mode initialization
- Add comprehensive tests for legacy config detection and navigation
- Add baseBranch parameter to cloneRepo and createWorktreeSafely
- Create CreateWorktreeDialog component for dedicated worktree creation
- Add Create Worktree action to RepoRowActions and RepoDetail page
- Update BranchesTab to use CreateWorktreeDialog
- Allow specifying base branch when creating worktrees
- Extract getFileApiUrl helper with options interface for type-safe URL building
- Handle paths containing '.' and '..' segments via query parameters
- Remove duplicate URL construction logic from FileBrowser, FilePreview, and FileTree components
- Add getSpecialRoutePathFromRequest helper in backend for consistent path extraction
- Add query parameter support for file paths to handle special characters
- Enable navigation above base path with proper validation
- Centralize URL encoding logic for file API calls
- Update path validation to use workspace base instead of repos base
- Add normalizePath utility for consistent path handling
* loop: simple-chat-mode completed after 1 iterations
* feat(frontend): add simple chat mode for user messages and clean up redundant optimistic filtering
* refactor(frontend): consolidate status indicators and simplify simple chat mode
- Merge MiniScanner and CompactStatusIndicator into SessionStatusIndicator with size and showLabel props
- Hide step-finish cost/token display in simpleChatMode
- Update SessionCard and PromptInput to use unified SessionStatusIndicator
- Add tests for step-finish rendering in simpleChatMode