dsh-opencode-go 0.1.21 → 0.1.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.en.md +128 -167
- package/README.md +126 -158
- package/THIRD_PARTY_NOTICES.md +3 -1
- package/docs/development.md +56 -6
- package/docs/fork-review-2026-09-25.md +191 -0
- package/docs/independent-package.md +2 -2
- package/docs/verification.md +154 -0
- package/lib/build-info.json +8 -1
- package/lib/client.js +412 -262
- package/lib/index.js +6763 -428
- package/lib/types/account-manager.d.ts +23 -0
- package/lib/types/account-operations.d.ts +31 -0
- package/lib/types/account-policy.d.ts +16 -0
- package/lib/types/account-recovery.d.ts +2 -0
- package/lib/types/account-selection.d.ts +30 -0
- package/lib/types/account-service.d.ts +12 -0
- package/lib/types/accounts-contract.d.ts +38 -0
- package/lib/types/accounts.d.ts +5 -0
- package/lib/types/adapter.d.ts +30 -10
- package/lib/types/call-trace.d.ts +54 -0
- package/lib/types/catalog-manager.d.ts +20 -0
- package/lib/types/catalog.d.ts +5 -3
- package/lib/types/client/accounts-controller.d.ts +6 -17
- package/lib/types/client/host-compat.d.ts +7 -0
- package/lib/types/client/locales.d.ts +9 -0
- package/lib/types/client/section-controller.d.ts +11 -46
- package/lib/types/client/staged-form.d.ts +1 -3
- package/lib/types/client/usage.d.ts +1 -1
- package/lib/types/config-contract.d.ts +69 -0
- package/lib/types/config.d.ts +12 -53
- package/lib/types/conversion/context.d.ts +5 -1
- package/lib/types/conversion/image-pool.d.ts +24 -0
- package/lib/types/conversion/replay.d.ts +1 -1
- package/lib/types/conversion/stream.d.ts +1 -1
- package/lib/types/gateway-diagnostics.d.ts +22 -0
- package/lib/types/gateway-error.d.ts +2 -0
- package/lib/types/host-settings.d.ts +11 -0
- package/lib/types/index.d.ts +1 -1
- package/lib/types/model-metadata.d.ts +3 -1
- package/lib/types/models-contract.d.ts +7 -0
- package/lib/types/protocol-contract.d.ts +5 -0
- package/lib/types/protocol-policy.d.ts +4 -0
- package/lib/types/reasoning.d.ts +36 -6
- package/lib/types/request-control.d.ts +2 -0
- package/lib/types/sdk-types.d.ts +1568 -0
- package/lib/types/settings-bridge.d.ts +22 -0
- package/lib/vendor-licenses.txt +103 -0
- package/package.json +6 -2
package/README.en.md
CHANGED
|
@@ -1,256 +1,217 @@
|
|
|
1
1
|
# dsh-opencode-go
|
|
2
2
|
|
|
3
|
-
[
|
|
3
|
+
[简体中文](README.md)
|
|
4
4
|
|
|
5
|
-
Use OpenCode Go subscription models in [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness), with streaming
|
|
5
|
+
Use OpenCode Go subscription models in [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness), with streaming, reasoning, tool calls, and image input. The plugin synchronizes model listings and limits, and provides multiple accounts, subscription usage, and proxy settings.
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Requires DSH `0.1.5-rc.1` or later.
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
Installed compatibility is checked on ten host versions from `0.1.5-rc.1` through `0.2.1-alpha.1`; see the [compatibility matrix](docs/development.md#installed-package-matrix). Later hosts need verification. Developer messages, dynamic tool additions/removals, and deferred tool loading are explicitly rejected.
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
- **Streaming and history**: Supports streaming output, tool calls, and history replay through pi-ai.
|
|
13
|
-
- **Image input**: Supports models that advertise image capability in the catalog.
|
|
14
|
-
- **Model capacity overrides**: Override the context window and maximum output per model, with blank values inheriting the online catalog.
|
|
15
|
-
- **Per-model switches**: Control which models appear in conversations, with changes applied immediately. Ordinary models default to on and deprecated models default to off; any model can be enabled individually.
|
|
16
|
-
- **Prompt and caching**: The plugin does not add hidden system prompts; the session ID is used for gateway routing.
|
|
11
|
+
## Install
|
|
17
12
|
|
|
18
|
-
|
|
13
|
+
### From DSH
|
|
19
14
|
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
Verified versions: `0.1.5-rc.1`, `0.1.5-rc.2`, `0.1.6-alpha.1`, `0.1.6-alpha.2`, `0.1.7-alpha.1`, `0.1.7-alpha.2`, `0.1.7-rc.1`, `0.1.7-rc.2`, `0.2.0-rc.2`, and `0.2.1-alpha.1`.
|
|
23
|
-
|
|
24
|
-
### Install from DSH (recommended)
|
|
25
|
-
|
|
26
|
-
1. Open the **Plugins** page in DSH and click **Add plugin** in the top-right corner.
|
|
15
|
+
1. Open **Plugins → Add plugin**.
|
|
27
16
|
2. Enter `dsh-opencode-go` and click **Install**.
|
|
28
|
-
3.
|
|
17
|
+
3. Click **Enable now** after installation.
|
|
29
18
|
|
|
30
|
-

|
|
31
20
|
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
The plugin can also be installed by entering this Git repository URL:
|
|
21
|
+
You can also enter the Git repository URL when adding the plugin:
|
|
35
22
|
|
|
36
23
|
```text
|
|
37
24
|
https://github.com/Duskriver/dsh-opencode-go
|
|
38
25
|
```
|
|
39
26
|
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
If your DSH version does not have an **Add plugin** entry, use the command-line method below.
|
|
43
|
-
|
|
44
|
-
### Command-line installation (alternative)
|
|
27
|
+
### From the command line
|
|
45
28
|
|
|
46
29
|
```sh
|
|
47
30
|
dsh plugin --profile web add dsh-opencode-go
|
|
48
31
|
```
|
|
49
32
|
|
|
50
|
-
Start or restart `dsh web
|
|
33
|
+
Start or restart `dsh web` after installation. Web and Headless use separate profiles; install and update each profile individually.
|
|
51
34
|
|
|
52
|
-
|
|
53
|
-
2. Enter and save your OpenCode Go API key.
|
|
54
|
-
3. Select an OpenCode Go model from the conversation model picker.
|
|
35
|
+
## Get started
|
|
55
36
|
|
|
56
|
-
|
|
37
|
+
1. Open **Settings → OpenCode Go**, enter your API key and save, or add an account in **Accounts**.
|
|
38
|
+
2. Select a model under **DSH OpenCode Go** in the conversation model picker.
|
|
39
|
+
3. Start chatting. Choose a reasoning level when offered, or attach images to a model that supports them.
|
|
57
40
|
|
|
58
|
-
|
|
41
|
+
Refresh the model list in Settings to synchronize the catalog. The switch beside each model controls its visibility in the picker and takes effect immediately. Context windows and output limits use catalog values by default; edit and save individual model limits as needed.
|
|
59
42
|
|
|
60
|
-
|
|
61
|
-
dsh plugin --profile headless add dsh-opencode-go
|
|
62
|
-
```
|
|
43
|
+
**Default** leaves reasoning to the service; **Off** explicitly disables it. Models with a switch show **On / Off**, models with adjustable effort show their supported levels, and budget-based models show token values.
|
|
63
44
|
|
|
64
|
-
|
|
45
|
+
Budget-based models offer common presets such as 1,024 / 2,048 / 8,192 / 16,384 tokens. Select a model in Settings, expand **Thinking budgets**, enter a value, click **Add**, then save to make that budget available in conversations. Allowed ranges vary by model; the SDK may reduce the actual budget to leave room for the answer.
|
|
65
46
|
|
|
66
|
-
|
|
67
|
-
- id: agent-default-model
|
|
68
|
-
config:
|
|
69
|
-
provider: dsh-opencode-go
|
|
70
|
-
model: deepseek-v4.1-flash
|
|
71
|
-
```
|
|
47
|
+
The plugin follows DSH's interface language and supports English and Chinese.
|
|
72
48
|
|
|
73
|
-
|
|
49
|
+
### View subscription usage
|
|
74
50
|
|
|
75
|
-
|
|
76
|
-
read -s OPENCODE_API_KEY
|
|
77
|
-
export OPENCODE_API_KEY
|
|
78
|
-
dsh --profile headless --patch ./headless.patch.yml "Hello"
|
|
79
|
-
```
|
|
51
|
+
Click the usage pill beside the conversation input to see the current account's five-hour, weekly, and monthly usage and reset times. Usage refreshes every minute and can also be refreshed manually.
|
|
80
52
|
|
|
81
|
-
|
|
53
|
+
Under **Advanced settings → Usage display**, choose:
|
|
82
54
|
|
|
83
|
-
|
|
55
|
+
- **Auto**: show usage while using this plugin's models; the default.
|
|
56
|
+
- **Always**: also show usage while using other models.
|
|
57
|
+
- **Off**: hide usage and stop polling.
|
|
84
58
|
|
|
85
|
-
|
|
86
|
-
npm ci
|
|
87
|
-
npm run compile
|
|
88
|
-
npm pack
|
|
89
|
-
dsh plugin --profile web add ./dsh-opencode-go-0.1.21.tgz
|
|
90
|
-
```
|
|
59
|
+

|
|
91
60
|
|
|
92
|
-
|
|
61
|
+
### Manage multiple accounts
|
|
93
62
|
|
|
94
|
-
|
|
63
|
+
Use **Accounts** to add accounts, rename them, or replace keys. Expand an account row for detailed usage. Drag its handle to reorder accounts; the first account becomes the current one.
|
|
95
64
|
|
|
96
|
-
|
|
97
|
-
npm run compile # Regenerate lib/ and commit it with source changes
|
|
98
|
-
npm test # Core tests, rebuilding the plugin first
|
|
99
|
-
npm run check:dist # Verify shipped artifacts match the source
|
|
100
|
-
npm run test:compat # One tarball tested in 9 independent DSH environments
|
|
101
|
-
npm run test:install # npm / pnpm Git installs without plugin build approval
|
|
102
|
-
npm run verify # All of the above
|
|
103
|
-
```
|
|
65
|
+
Enable **Auto switch** to try other accounts in list order when the current account runs out of quota or its key is unavailable, before output begins. To choose the account for subsequent requests directly, click **Switch** in the usage pill.
|
|
104
66
|
|
|
105
|
-
|
|
67
|
+
If adding or removing an account is interrupted by closing the page or losing the connection, the host resumes recovery at startup or after settings and credential updates. An addition whose key was never stored stays visible so you can replace its key or remove it. Recovery preserves a current-account choice made in the meantime.
|
|
106
68
|
|
|
107
|
-
##
|
|
69
|
+
## Advanced usage
|
|
108
70
|
|
|
109
|
-
|
|
71
|
+
### Headless mode
|
|
72
|
+
|
|
73
|
+
Install the plugin:
|
|
110
74
|
|
|
111
75
|
```sh
|
|
112
|
-
dsh plugin --profile
|
|
76
|
+
dsh plugin --profile headless add dsh-opencode-go
|
|
113
77
|
```
|
|
114
78
|
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
After updating the desktop plugin, fully quit and reopen DeepSeek Harness to load the updated plugin code.
|
|
118
|
-
|
|
119
|
-
## Multiple accounts and switching
|
|
120
|
-
|
|
121
|
-
Open **Settings → OpenCode Go → Accounts** to add up to 20 named API keys. Adding, renaming, replacing a key, removing, and selecting a preferred account take effect immediately. Model capacities and advanced fields still use Save. Existing `apiKeyEnv` configuration appears as the default account without re-entering its key.
|
|
122
|
-
|
|
123
|
-
Each account shows its rolling, weekly, and monthly usage, reset times, and last successful update. Usage refreshes every minute while the settings page is visible. The conversation usage panel also lets you switch accounts; it immediately clears the old account's data and rejects late responses. Temporary failures retain data only for the same account and key.
|
|
124
|
-
|
|
125
|
-
The preferred account is shared by conversations in the current profile and affects subsequent new requests. Requests already generating retain their resolved key. Account metadata and preference survive restart. Web and Headless profiles keep their own configuration. Save or discard a key draft before changing accounts; if another surface switches accounts, the draft remains addressed to the original account.
|
|
126
|
-
|
|
127
|
-
Keys are stored through the host credential service and never returned to the page. Configuration contains account names, IDs, and credential references. Read-only environment keys can be selected but cannot be replaced in the UI. Removing accounts created here also removes their dedicated credential; existing external references are retained. Removing every account withdraws the provider until another account is added.
|
|
128
|
-
|
|
129
|
-
**Automatic fallback** is off by default. When enabled, missing/rejected keys or exhausted quota can trigger attempts with the other accounts in list order, before any content or tool call is emitted and only when no token usage was reported. Each account is tried at most once per request. The preferred account stays selected; a successful fallback is reported in the usage panel with its reason and time. Partial responses, permission errors, ordinary rate limits, network errors, and server errors stay with host recovery. Cancellation stops further attempts. Quotas remain controlled by the upstream subscriptions.
|
|
130
|
-
|
|
131
|
-
For Headless or manual configuration, put the following under the plugin's `config`:
|
|
79
|
+
Save this as `headless.patch.yml`:
|
|
132
80
|
|
|
133
81
|
```yaml
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
apiKeyEnv: OPENCODE_API_KEY
|
|
139
|
-
- id: backup
|
|
140
|
-
name: Backup
|
|
141
|
-
apiKeyEnv: OPENCODE_GO_BACKUP_KEY
|
|
142
|
-
autoSwitch: false
|
|
82
|
+
- id: agent-default-model
|
|
83
|
+
config:
|
|
84
|
+
provider: dsh-opencode-go
|
|
85
|
+
model: deepseek-v4.1-flash
|
|
143
86
|
```
|
|
144
87
|
|
|
145
|
-
|
|
88
|
+
Enter your key in Bash or Zsh, then run a task:
|
|
89
|
+
|
|
90
|
+
```sh
|
|
91
|
+
read -s OPENCODE_API_KEY
|
|
92
|
+
export OPENCODE_API_KEY
|
|
93
|
+
dsh --profile headless --patch ./headless.patch.yml "Hello"
|
|
94
|
+
```
|
|
146
95
|
|
|
147
|
-
|
|
96
|
+
Replace `model` with an available model ID from Settings. See [examples/headless.patch.yml](examples/headless.patch.yml).
|
|
148
97
|
|
|
149
|
-
|
|
98
|
+
### Network proxy
|
|
150
99
|
|
|
151
|
-
Open **Settings → OpenCode Go → Advanced settings → Proxy address**, enter a
|
|
100
|
+
Open **Settings → OpenCode Go → Advanced settings → Proxy address**, enter a URL, and save. Examples:
|
|
152
101
|
|
|
153
102
|
```text
|
|
154
103
|
http://127.0.0.1:7890
|
|
155
104
|
socks5://127.0.0.1:1080
|
|
156
105
|
```
|
|
157
106
|
|
|
158
|
-
HTTPS
|
|
159
|
-
|
|
160
|
-
The next conversation, model listing, metadata download and usage query use the saved proxy without a restart. Save a blank address to use the default network settings; **Reset** restores the inherited configuration value. A failed proxy connection reports an error rather than falling back to a direct connection.
|
|
161
|
-
|
|
162
|
-
Connections originate from the machine running DSH. On a remote deployment, `127.0.0.1` refers to that server. Headless profiles can set `proxyURL` in the plugin configuration as well.
|
|
163
|
-
|
|
164
|
-
## Subscription usage display
|
|
165
|
-
|
|
166
|
-
Under **Settings → OpenCode Go → Advanced settings → Usage display**, choose a mode and save: **Auto (default)** shows the pill only for this plugin's DSH OpenCode Go models; **Always** keeps it visible with other models, including the built-in `opencode-go` provider; **Off** hides it and stops polling. Disabling OpenCode Go hides the pill in every mode. Click the pill to open the usage panel: its first row is the account in use (state dot, name, Preferred tag, Switch), and Switch turns the card's body into the account list — the current account ticked, reachable with ↑ / ↓ or a click, Escape stepping back. That choice decides which account spends now; the consumption order stays the one this page sets. The three windows take one row each (label, bar, reading) with the reset stamp beneath, and the refresh stamp sits in the card's foot.
|
|
167
|
-
|
|
168
|
-
Usage refreshes every minute. Temporary network or service errors retain the last reading for the same account, with a failure notice, timestamp, and reason; the usage panel offers an immediate retry. Initial and authentication failures do not show old usage. Catalog, metadata, and usage JSON requests retry a transient connection reset once within the original timeout budget; this cannot guarantee recovery while the network is failing.
|
|
169
|
-
|
|
170
|
-

|
|
171
|
-
|
|
172
|
-
## Interface language
|
|
173
|
-
|
|
174
|
-
The plugin follows Harness and supplies Chinese and English copy without storing a separate language preference. With no explicit choice, the Web client matches the browser's preferred languages (usually inherited from the system); native shells with a system-language bridge supply their operating-system languages. English is used when no supported language matches.
|
|
175
|
-
|
|
176
|
-
A language explicitly selected in Harness takes precedence and updates the plugin immediately without discarding form drafts. Model names and IDs stay unchanged; usage dates and capacity numbers follow the active interface language. Automatic language detection runs at startup: reload the Web page after changing browser languages, or restart desktop Harness after changing system languages.
|
|
107
|
+
HTTP, HTTPS, SOCKS5, and URLs containing a username and password are supported. Subsequent conversations, catalog updates, and usage queries use the saved proxy. Connections originate from the machine running DSH; on a remote deployment, `127.0.0.1` refers to that server.
|
|
177
108
|
|
|
178
|
-
|
|
109
|
+
### Experimental Responses protocol
|
|
179
110
|
|
|
180
|
-
|
|
111
|
+
Open **Settings → OpenCode Go → Advanced settings → DeepSeek V4.1 Flash protocol** to select Responses (experimental). Automatic remains the default and follows the gateway's declared protocol. This setting applies only to `deepseek-v4.1-flash` and to new requests. Existing conversation history can continue with either selection; a failed request does not automatically retry through another protocol.
|
|
181
112
|
|
|
182
|
-
|
|
113
|
+
To configure the experiment manually:
|
|
183
114
|
|
|
184
115
|
```yaml
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
116
|
+
- id: opencode-go
|
|
117
|
+
config:
|
|
118
|
+
protocolOverrides:
|
|
119
|
+
deepseek-v4.1-flash: openai-responses
|
|
188
120
|
```
|
|
189
121
|
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
The older `showDeprecatedModels` and `visibleModelIds` fields no longer control visibility. Use the individual switches or `modelVisibility`; retaining old fields does not prevent the plugin from loading.
|
|
193
|
-
|
|
194
|
-
## Image count cap
|
|
195
|
-
|
|
196
|
-
Under **Settings → OpenCode Go → Advanced settings**, set `maxImages` to a positive integer and save; no restart is needed. It is unset by default, with no image-count cap. Clearing or resetting removes the user override and inherits the base configuration; if the base has no cap either, the count is unlimited.
|
|
197
|
-
|
|
198
|
-
The count covers the full history sent in one request, including tool-result images. Repeated occurrences of the same attachment count separately. With a cap of `30`, 30 images pass through; 31 images cause the oldest occurrence to be offloaded before the request continues. Offloading replaces image content with a text placeholder and keeps the original attachment, but the model cannot see the offloaded image content in that request.
|
|
122
|
+
Select Automatic to revert. A null value for this model also clears an inherited override. Gateway routing and performance may change; Responses does not guarantee a particular provider or faster responses.
|
|
199
123
|
|
|
200
|
-
|
|
124
|
+
### Manual configuration
|
|
201
125
|
|
|
202
|
-
|
|
126
|
+
Add an `opencode-go` configuration block to a patch file. It can be combined with the default-model configuration above:
|
|
203
127
|
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
128
|
+
```yaml
|
|
129
|
+
- id: opencode-go
|
|
130
|
+
config:
|
|
131
|
+
apiKeyEnv: OPENCODE_API_KEY
|
|
132
|
+
accounts:
|
|
133
|
+
- id: primary
|
|
134
|
+
name: Primary
|
|
135
|
+
apiKeyEnv: OPENCODE_API_KEY
|
|
136
|
+
- id: backup
|
|
137
|
+
name: Backup
|
|
138
|
+
apiKeyEnv: OPENCODE_GO_BACKUP_KEY
|
|
139
|
+
autoSwitch: true
|
|
140
|
+
proxyURL: http://127.0.0.1:7890
|
|
141
|
+
refreshMinutes: 60
|
|
142
|
+
modelVisibility:
|
|
143
|
+
deepseek-v4-pro: false
|
|
144
|
+
modelLimits:
|
|
145
|
+
deepseek-v4.1-flash:
|
|
146
|
+
maxTokens: 8192
|
|
147
|
+
qwen3.7-plus:
|
|
148
|
+
thinkingBudgets: [4096, 6000]
|
|
149
|
+
maxImages: 30
|
|
150
|
+
```
|
|
209
151
|
|
|
210
|
-
|
|
152
|
+
Keep the options you need and supply the corresponding keys through DSH credentials or environment variables. `apiKeyEnv` selects the current account; the order of `accounts` determines automatic fallback order.
|
|
211
153
|
|
|
212
|
-
|
|
154
|
+
| Option | Purpose |
|
|
155
|
+
| --- | --- |
|
|
156
|
+
| `baseURL` | OpenCode Go gateway URL; defaults to `https://opencode.ai/zen/go/v1` |
|
|
157
|
+
| `usageDisplay` | Usage display mode: `auto`, `always`, or `off` |
|
|
158
|
+
| `proxyURL` | Network proxy; an empty string uses the default network settings |
|
|
159
|
+
| `refreshMinutes` | Model catalog cache lifetime; defaults to 60 minutes, with manual refresh available in Settings |
|
|
160
|
+
| `modelVisibility` | Control model picker visibility by model ID |
|
|
161
|
+
| `protocolOverrides` | Experimental `deepseek-v4.1-flash: openai-responses`; unset or null follows the gateway |
|
|
162
|
+
| `modelLimits` | Per-model `contextWindow` and `maxTokens` overrides, plus additional `thinkingBudgets` options; null uses defaults |
|
|
163
|
+
| `maxImages` | Maximum images in one request's history; unset by default, with oldest images offloaded when exceeded |
|
|
164
|
+
| `streamIdleTimeoutMs` | Maximum wait for the next stream event; defaults to 300000 milliseconds |
|
|
165
|
+
| `requestPreparationTimeoutMs` | Deadline for discovery and each attempt's credential/image preparation; defaults to 60000 milliseconds |
|
|
166
|
+
| `requestTimeoutMs` | Whole dispatch deadline, including discovery, account fallback and streaming; defaults to 1800000 milliseconds. Prepared calls start this timer at dispatch |
|
|
213
167
|
|
|
214
|
-
|
|
168
|
+
Image offloading keeps the original attachment and replaces the old image in the request with a text placeholder. Raising the limit does not automatically restore previously offloaded images.
|
|
215
169
|
|
|
216
|
-
|
|
170
|
+
Image count overflow is detected before attachment reads. Preparation shares four execution slots and at most 32 queued tasks within the plugin module, and stops scheduling images when known encoded bytes exceed the payload cap. Active image attempts share a 128 MiB budget for prepared raw data plus base64 payloads; this is not a process memory limit. Queue or shared-budget overflow returns `IMAGE_RESOURCE_BUSY`; retry after another request completes. Count and byte limits may require successive host offload retries.
|
|
217
171
|
|
|
218
|
-
A
|
|
172
|
+
A cold catalog outage reports `DISCOVERY_FAILED`; a warm catalog retains previously verified models. Only an explicit empty gateway listing clears membership. A partially malformed listing keeps its valid models and reports the ignored row count in settings and logs. Ordinary advanced form settings commit in one revision-checked batch. Credentials use a separate service; failed credential drafts remain, and retry submits only uncommitted parts.
|
|
219
173
|
|
|
220
|
-
|
|
174
|
+
### Export error diagnostics
|
|
221
175
|
|
|
222
|
-
|
|
176
|
+
To investigate a failed request, set a diagnostics directory before starting DSH:
|
|
223
177
|
|
|
224
|
-
|
|
178
|
+
```sh
|
|
179
|
+
export DSH_OPENCODE_GO_DEBUG_DIR=/tmp/dsh-opencode-go-debug
|
|
180
|
+
dsh web
|
|
181
|
+
```
|
|
225
182
|
|
|
226
|
-
|
|
183
|
+
Windows PowerShell:
|
|
227
184
|
|
|
228
|
-
|
|
185
|
+
```powershell
|
|
186
|
+
$env:DSH_OPENCODE_GO_DEBUG_DIR = "$env:TEMP\dsh-opencode-go-debug"
|
|
187
|
+
dsh web
|
|
188
|
+
```
|
|
229
189
|
|
|
230
|
-
|
|
190
|
+
Reproduce the failure to get a JSON file path in the error message. The record contains the model, request parameter summaries, HTTP status, upstream log and route IDs, and the error response, for use in an [issue report](https://github.com/Duskriver/dsh-opencode-go/issues). Review the returned error content before sharing. Clear the environment variable and restart DSH to disable diagnostics.
|
|
231
191
|
|
|
232
|
-
|
|
192
|
+
DSH debug logs contain a call ID and each attempt's stage timings, HTTP status, upstream request ID, time to first output and error code, including stream failures after HTTP 200. Image attempts also report aggregate queue waiting and peak resource occupancy. Error files carry the same call ID and attempt number for correlation. These summaries exclude prompts, keys, proxy addresses and raw session IDs.
|
|
233
193
|
|
|
234
|
-
|
|
194
|
+
## Update and uninstall
|
|
235
195
|
|
|
236
|
-
|
|
196
|
+
Update to the latest npm release:
|
|
237
197
|
|
|
238
|
-
|
|
198
|
+
```sh
|
|
199
|
+
dsh plugin --profile web update dsh-opencode-go --latest
|
|
200
|
+
```
|
|
239
201
|
|
|
240
|
-
|
|
202
|
+
Restart `dsh web` and reload the page afterward. For desktop DSH, quit and reopen the application. Headless users should replace `web` with `headless`.
|
|
241
203
|
|
|
242
|
-
|
|
204
|
+
Uninstall:
|
|
243
205
|
|
|
244
206
|
```sh
|
|
245
207
|
dsh plugin --profile web remove dsh-opencode-go
|
|
246
|
-
# or
|
|
247
|
-
dsh plugin --profile headless remove dsh-opencode-go
|
|
248
208
|
```
|
|
249
209
|
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
Please open an issue for bugs or feature requests.
|
|
210
|
+
When upgrading from `0.1.16` or earlier, select **DSH OpenCode Go** again in existing conversations or Agent presets. Manual configurations use `provider: dsh-opencode-go`.
|
|
253
211
|
|
|
254
|
-
##
|
|
212
|
+
## More
|
|
255
213
|
|
|
256
|
-
[
|
|
214
|
+
- [Development and testing](docs/development.md)
|
|
215
|
+
- [Verification notes](docs/verification.md)
|
|
216
|
+
- [Issues and suggestions](https://github.com/Duskriver/dsh-opencode-go/issues)
|
|
217
|
+
- [MIT license](LICENSE)
|