Release

OpenCode v2.4.0–v2.4.2: a signed-in desktop browser, automations, and video generation

Three releases: a persistent signed-in desktop browser, timed automations, agent video generation, a new default TUI look, and GPT-6.2 prompts.

Three tagged OpenCode releases shipped since v2.3.2: v2.4.0 on November 23, v2.4.1 later the same day, and v2.4.2 on November 26. The v2.4.0 headlines: the desktop app gains a built-in browser that keeps you signed in and can be driven by the agent, automations run prompts, scripts or shell commands on a schedule, agents can generate videos, the TUI’s new designs are on by default, and on Windows the taskbar shows session progress. Check the upgrade notes before updating — the image tool is renamed, version-following plugins now update themselves, GitHub Copilot no longer reads GITHUB_TOKEN, and a v2.4.2 change narrows what “Always allow” for a web fetch permits. The same-day v2.4.1 fixes saving assistant messages on macOS 12, and v2.4.2 adds a system prompt written for GPT-6.2 and lets Esc take back your last message.

The desktop browser keeps you signed in (v2.4.0)

The desktop app’s browser pane runs on one persistent desktop profile: you can import sign-ins and browsing history from Chrome, Edge, Firefox or Safari, and install extensions from Chromium browsers or the Chrome and Edge stores after reviewing what they can access. Chat links open signed in, your tabs survive restarts, and the agent can read and drive the same signed-in pages without you switching apps (improvement). New tabs a page opens appear beside the tab they came from, and middle-clicking a link opens it in a new tab (improvement). The pane gains a right-click menu, find in page, page dialogs, permission prompts, pop-up blocking and readable error pages, and the address bar completes from your history (improvement). In the desktop app, web links from the chat open beside the conversation, and modifier-clicking a link opens it in your system browser; a browser deny in your permission rules refuses every agent browser call (improvement).

Automations run your prompts on a schedule (v2.4.0, hardened in v2.4.2)

Agents can schedule prompts, Code Mode scripts or fixed shell commands to run once, on an interval, on a cron schedule or when a connected MCP server pushes an event. Use the /automation command or the automation tools; a shell action asks for approval once, when it’s created, and records each run’s exit code and output. Set "automations": false to turn them off (improvement). OpenCode follows the MCP Events beta for push delivery, with argument checks, heartbeats and automatic reconnects; an event too large for its prompt is skipped and its automation keeps running (improvement). From v2.4.2, automations keep running after a failed run: the failed run is recorded and the next one runs on schedule. They still pause when the session that created them or their directory is gone, or when their setup is no longer valid, and a shell command in an automation’s code that runs past its timeout is now stopped and fails the call instead of moving to the background (improvement).

Video generation, now inside Code Mode (v2.4.0, v2.4.2)

When a connected provider has a video model, the agent can make videos with generate_video. The job runs in the background, survives a server restart, saves the finished videos into your workspace and wakes the agent with their paths (improvement). Set a default model with experimental.video_generate.model. The image tool is now called generate_image — it was experimental_image_generate (improvement). In v2.4.2, generate_image and generate_video run inside Code Mode instead of as top-level tools, so their definitions no longer add about 700 tokens to every request (improvement).

The new TUI look is on by default (v2.4.0)

The TUI’s new designs are on by default, and the theme named opencode is the new theme. The previous default is available as opencode-classic, and opencode2 keeps working as an alias of opencode. To go back to the previous designs, turn off New designs in the Experiments dialog (improvement). The opencode theme’s light mode uses lighter grays for the prompt box, selected tabs and hovered rows (improvement).

Windows taskbar progress (v2.4.0)

On Windows, the taskbar button shows session status as a progress bar, shows a count badge for sessions that need you, and flashes when a permission or question is waiting; notifications say what is being asked and disappear once you answer (improvement). The jump list gains New Session and New Window, you can drag files from the file tree into other apps, and Open in includes Windows Terminal and lists only installed apps (improvement).

Esc takes back your last message (v2.4.2)

If the composer is empty, stopping a response with Esc before the model has written anything or called a tool removes your message and puts it back in the composer, images included, so you can edit it and send again (improvement).

Before you update

Upgrade notes from the v2.4.0 and v2.4.2 release notes:

Model and provider fixes (v2.4.1, v2.4.2)

OpenCode can save assistant messages again on the older SQLite version included with macOS 12, which does not support the JSON operator used in v2.4.0 (bugfix). Providers you set up only in your config, such as Ollama, now show their models in /models without a /connect login (bugfix). GPT-6.2 Sol and Astra, and the gpt-latest aliases, use a system prompt written for GPT-6.2 (improvement). After you connect OpenCode, the model picker lists OpenCode Go first (improvement).

With experimental.model_speeds enabled, model service tiers are exposed as remembered speeds instead of separate model-picker entries: the TUI’s /speed and /fast list the current model’s service tiers and relative prices, with the speed.list and speed.cycle keybinds available without default bindings, and models with service tiers get a speed dropdown beside the variant selector in the desktop app (improvement).

How to use

Also worth knowing

Core improvements and fixes from all three releases:

In the TUI:

In the desktop app:

In the SDK:

In extensions:

For the full list of changes, see the v2.4.0 release notes, the v2.4.1 release notes and the v2.4.2 release notes, and follow the release feed for the next tag.

溯源: https://github.com/anomalyco/opencode/releases

继续探索