From 34527e30808562666efc9a24edcbefed90df2075 Mon Sep 17 00:00:00 2001 From: j4rviscmd Date: Sat, 4 Apr 2026 17:17:31 +0900 Subject: [PATCH] docs: recommend config file editing as primary mode switching method Restructure README usage section to recommend directly editing agent-mode-switcher.json over slash commands, and separate informational slash commands into their own section. Co-Authored-By: Claude Opus 4.6 --- README.md | 38 ++++++++++++++++++++++++++++++-------- 1 file changed, 30 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 18befdf..bc5dfa3 100644 --- a/README.md +++ b/README.md @@ -48,20 +48,42 @@ The following command files are automatically copied to - `mode-status.md` - `mode-list.md` -## Usage +## How to Change Mode -### Available Commands +### Recommended: Edit Configuration File Directly + +The recommended way to switch modes is to edit +`~/.config/opencode/agent-mode-switcher.json` and change the `currentMode` value: + +```json +{ + "currentMode": "economy" +} +``` + +Then start (or restart) opencode. The plugin automatically detects the change +and applies the corresponding preset to `opencode.json` and +`oh-my-opencode.json`. + +Available values for `currentMode`: + +- `"performance"` - High-performance models for complex tasks +- `"economy"` - Cost-efficient free model for routine tasks +- Any custom preset name you have defined + +> [!TIP] +> This approach is preferred because it works even when opencode is not +> running. The plugin applies pending changes on the next startup. + +### Alternative: Slash Commands - `/mode-performance` - Switch to high-performance models - `/mode-economy` - Switch to cost-efficient free models -- `/mode-status` - Show current mode and configuration -- `/mode-list` - List all available mode presets -### Available Tools +## Slash Commands -- `mode_switch` - Switch to a specified mode preset -- `mode_status` - Display current mode settings -- `mode_list` - List all available presets +- `/mode-status` - Show current mode and configuration +- `/mode-list` - List all available mode presets ## Configuration