command-code 1.28.4 → 1.30.0
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/CHANGELOG.md +12 -0
- package/dist/bundled/command-code-knowledge/SKILL.md +11 -4
- package/dist/bundled/command-code-knowledge/reference/byok.md +356 -0
- package/dist/bundled/command-code-knowledge/reference/custom-slash-commands.md +1 -1
- package/dist/bundled/command-code-knowledge/reference/models.md +1 -1
- package/dist/bundled/command-code-knowledge/reference/product-help.md +2 -1
- package/dist/bundled/config/references/settings.md +0 -1
- package/dist/cli.mjs +5 -5
- package/package.json +5 -5
- package/vsix/commandcode-vscode.vsix +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# command-code
|
|
2
2
|
|
|
3
|
+
## 1.30.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- feat: BYOK providers support (beta)
|
|
8
|
+
- /connect menu to manage provider connections
|
|
9
|
+
- feat(providers): local-only mode for byok
|
|
10
|
+
|
|
11
|
+
## 1.29.0
|
|
12
|
+
|
|
13
|
+
- feat: improve traffic routing
|
|
14
|
+
|
|
3
15
|
## 1.28.4
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: command-code-knowledge
|
|
3
|
-
description: Authoritative Command Code product knowledge — slash commands, CLI options, permissions, skills, custom agents, MCP servers, hooks, memory, headless mode, plan mode, checkpoints, sessions, the model catalog, taste, pricing, and troubleshooting. Use when the user asks how Command Code works, how to configure or extend it, which models exist, or when you need product facts to answer a "can Command Code do X" question. Do NOT search the codebase for product behavior — read the reference files here instead.
|
|
3
|
+
description: Authoritative Command Code product knowledge — slash commands, CLI options, permissions, skills, custom agents, MCP servers, hooks, memory, headless mode, plan mode, checkpoints, sessions, the model catalog, custom/BYOK providers (providers.json, OpenAI-compatible and Anthropic-wire endpoints, local servers like Ollama, API keys, /providers), taste, pricing, and troubleshooting. Use when the user asks how Command Code works, how to configure or extend it, which models exist, how to add their own provider or endpoint, or when you need product facts to answer a "can Command Code do X" question. Do NOT search the codebase for product behavior — read the reference files here instead.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Command Code Knowledge
|
|
@@ -22,13 +22,19 @@ the matching reference file.
|
|
|
22
22
|
limits): read `reference/plans.md` and the Min plan column in `reference/models.md`. The
|
|
23
23
|
plan itself is not readable headlessly — ask the user or point them at /usage. Never
|
|
24
24
|
dig through auth files, API endpoints, or TTY tricks.
|
|
25
|
-
5.
|
|
25
|
+
5. Custom/BYOK provider questions (the providers.json shape, `apiKey` references, local
|
|
26
|
+
endpoints like Ollama/vLLM/LM Studio, `/providers`, "add X as a provider"): read
|
|
27
|
+
`reference/byok.md`. Never invent config keys — the accepted fields are listed there
|
|
28
|
+
verbatim. When you need current model ids, context windows, or prices for an EXTERNAL
|
|
29
|
+
provider, fetch the models.dev registry (https://models.dev/api.json — the same catalog
|
|
30
|
+
the CLI's /providers wizard uses) rather than inventing them.
|
|
31
|
+
6. Anything about the help surface (slash commands, keyboard shortcuts, CLI flags, taste,
|
|
26
32
|
FAQ, pricing links): `reference/product-help.md` — the same document the
|
|
27
33
|
bundled product-help reference.
|
|
28
|
-
|
|
34
|
+
7. Questions about the built-in tools — exact wire names, parameters, guards, limits, or how
|
|
29
35
|
the agent is expected to drive one (e.g. the worked `todo_write` checklist examples):
|
|
30
36
|
`reference/tools.md`.
|
|
31
|
-
|
|
37
|
+
8. Building a mod (a loadable ModApi plugin)? Switch to the `mod-builder` skill — it has
|
|
32
38
|
the mods reference and runnable examples.
|
|
33
39
|
|
|
34
40
|
## Reference index
|
|
@@ -45,6 +51,7 @@ the matching reference file.
|
|
|
45
51
|
- `reference/headless.md` — Headless Mode
|
|
46
52
|
- `reference/plan-mode.md` — Plan Mode
|
|
47
53
|
- `reference/sessions.md` — Sessions & Checkpoints
|
|
54
|
+
- `reference/byok.md` — BYOK
|
|
48
55
|
- `reference/models.md` — Command Code Models
|
|
49
56
|
- `reference/plans.md` — Plans, credits, and per-plan model access
|
|
50
57
|
- `reference/product-help.md` — Product help (slash commands, CLI, taste, FAQ, pricing)
|
|
@@ -0,0 +1,356 @@
|
|
|
1
|
+
<!-- Generated from the Command Code docs: https://commandcode.ai/docs -->
|
|
2
|
+
|
|
3
|
+
# BYOK
|
|
4
|
+
|
|
5
|
+
BYOK is currently in beta and subject to improvements.
|
|
6
|
+
|
|
7
|
+
Bring your own provider and use it in Command Code CLI. Any OpenAI or Anthropic compactible API can serve models in Command Code. You can bring your key from hosted providers (DeepSeek, OpenRouter, Vercel AI Gateway), local servers (Ollama, vLLM), or other coding agent's APIs.
|
|
8
|
+
|
|
9
|
+
## BYOK Providers
|
|
10
|
+
|
|
11
|
+
You can connect to any external provider in Command Code, requests go straight from your machine to that provider's endpoint with your key, never through Command Code's servers.
|
|
12
|
+
|
|
13
|
+
BYOK providers can be managed from `/connect` in the Command Code CLI. Below are providers and instructions on how to connect to them.
|
|
14
|
+
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
## Command Code
|
|
18
|
+
|
|
19
|
+
Command Code is the default and recommended provider. Every model in `/model` routes through your plan, and the models are optimized for the cmd harness. That optimization is real engineering: see [Harness Engineering](https://commandcode.ai/docs/harness-engineering) for how the harness repairs, steers, and optimizes models.
|
|
20
|
+
|
|
21
|
+
The `/model` menu can be used to access models from Command Code and BYOK providers. BYOK models are active alongside Command Code models, and you switch back to Command Code models anytime through the model menu.
|
|
22
|
+
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
## OpenAI ChatGPT/Codex
|
|
26
|
+
|
|
27
|
+
You can use your ChatGPT Pro/Plus subscription directly in Command Code. Select **OpenAI ChatGPT/Codex** in `/connect` (or run `cmd login openai`, `chatgpt` works too) and sign in.
|
|
28
|
+
|
|
29
|
+
The provider package installs on demand at first login, and its models appear as their own section in `/model`. Requests run locally from the CLI over your subscription.
|
|
30
|
+
|
|
31
|
+
---
|
|
32
|
+
|
|
33
|
+
## GitHub Copilot
|
|
34
|
+
|
|
35
|
+
Same flow for an active GitHub Copilot subscription: select **GitHub Copilot** in `/connect` (or `cmd login copilot`), complete the device sign-in, and the copilot provider's models will be listed in `/model`.
|
|
36
|
+
|
|
37
|
+
---
|
|
38
|
+
|
|
39
|
+
## Adding a custom provider
|
|
40
|
+
|
|
41
|
+
The `/connect` menu supports **150+ providers** out of the box. For those, the endpoint, wire, and current model list come prefilled. Anything else works too: any OpenAI-compatible or Anthropic-wire endpoint can also be setup.
|
|
42
|
+
|
|
43
|
+
Run `/connect` and pick **(BYOK) Add your own provider**.
|
|
44
|
+
|
|
45
|
+
### From the supported providers list (the happy path)
|
|
46
|
+
|
|
47
|
+
The connect menu supports 150+ providers with endpoint, models, and config prefilled. You can search and pick a provider from this menu.
|
|
48
|
+
|
|
49
|
+
**Pick the provider**
|
|
50
|
+
Start typing at the id step (`openrouter`, `deepseek`, `groq`, …) and a browsable list of known providers shows under the input. Pick one with `↑/↓` + enter; the wire and endpoint prefill.
|
|
51
|
+
|
|
52
|
+
**Paste your key**
|
|
53
|
+
Keys are stored securely in `~/.commandcode/auth.json`. Press enter on the empty field if the endpoint takes no key (local servers).
|
|
54
|
+
|
|
55
|
+
**Models arrive on their own**
|
|
56
|
+
Discovery is silent: the provider's current model list, names and context windows included, is imported for you. Finishing lands you in `/model` with the new models selectable and routing.
|
|
57
|
+
|
|
58
|
+
### Not in the list (fully custom)
|
|
59
|
+
|
|
60
|
+
If your provider is not in the menu, or you want to declare a custom/local one, follow these steps:
|
|
61
|
+
|
|
62
|
+
**Name it**
|
|
63
|
+
Type any id, a short lowercase handle (`work-llm`). It names the entry in `~/.commandcode/providers.json` and prefixes its models (`work-llm/gpt-x`).
|
|
64
|
+
|
|
65
|
+
**Pick the wire**
|
|
66
|
+
**OpenAI-compatible** (`/chat/completions`, the default: Ollama, vLLM, LM Studio, most hosted APIs) or **Anthropic** (`/v1/messages`, for endpoints speaking the Claude Messages API).
|
|
67
|
+
|
|
68
|
+
**Point at the endpoint**
|
|
69
|
+
The API root. OpenAI-compatible servers usually end in `/v1`; Anthropic roots get `/v1` added on the wire when missing. A pasted URL carrying a route suffix (`…/v1/chat/completions`) is trimmed to the root automatically, with a note showing what was removed.
|
|
70
|
+
|
|
71
|
+
**Add the key, or skip it**
|
|
72
|
+
Key is securely stored in `auth.json`. Press enter on the empty field if the endpoint takes no key (local servers).
|
|
73
|
+
|
|
74
|
+
**Declare the models**
|
|
75
|
+
The menu asks the endpoint's own `/models` listing first. If that comes up empty, you can either type ids there or modify the providers.json file to add the models. See the config schema below for details.
|
|
76
|
+
|
|
77
|
+
Press `h` on any non-typing step for the condensed version of all of this; `esc` (or `←` where it can't mean cursor movement) goes back one step.
|
|
78
|
+
|
|
79
|
+
You can also just ask the agent: `add OpenRouter as a provider and enable deepseek/deepseek-v4-flash`. It reads its bundled BYOK reference, looks up current model ids and context windows when it needs them, and writes the `providers.json` entry for you. Review it like any other edit.
|
|
80
|
+
|
|
81
|
+
---
|
|
82
|
+
|
|
83
|
+
## Provider config schema
|
|
84
|
+
|
|
85
|
+
Everything related to byok providers lives in `~/.commandcode/providers.json`. It is yours to edit, and changes apply live (reopen `/connect` or `/model`). For example:
|
|
86
|
+
|
|
87
|
+
```json
|
|
88
|
+
// ~/.commandcode/providers.json
|
|
89
|
+
{
|
|
90
|
+
"provider": {
|
|
91
|
+
"novita": {
|
|
92
|
+
"name": "Novita",
|
|
93
|
+
"baseURL": "https://api.novita.ai/v3/openai",
|
|
94
|
+
"apiKey": "$NOVITA_API_KEY",
|
|
95
|
+
"models": {
|
|
96
|
+
"qwen/qwen3.6-27b": {
|
|
97
|
+
"name": "Qwen 3.6 27B",
|
|
98
|
+
"contextWindow": 131072,
|
|
99
|
+
"maxOutput": 16384,
|
|
100
|
+
"reasoningEfforts": ["low", "high"],
|
|
101
|
+
"cost": { "input": 0.4, "output": 1.6 },
|
|
102
|
+
"options": { "temperature": 0.6 }
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
},
|
|
106
|
+
"claude-proxy": {
|
|
107
|
+
"api": "anthropic-messages",
|
|
108
|
+
"baseURL": "https://api.novita.ai/anthropic",
|
|
109
|
+
"apiKey": "$NOVITA_API_KEY",
|
|
110
|
+
"models": { "minimax/minimax-m2.7": {} }
|
|
111
|
+
},
|
|
112
|
+
"ollama": {
|
|
113
|
+
"baseURL": "http://localhost:11434/v1",
|
|
114
|
+
"apiKey": false,
|
|
115
|
+
"models": { "llama3.3:70b": {} }
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
### Provider fields
|
|
122
|
+
|
|
123
|
+
| Field | Values | Notes |
|
|
124
|
+
| --- | --- | --- |
|
|
125
|
+
| `name` | string | Display name in `/connect` and `/model`; defaults to the id |
|
|
126
|
+
| `api` | `openai-completions` (default) \| `anthropic-messages` | Omit for OpenAI-compatible endpoints. Any other value skips the provider |
|
|
127
|
+
| `npm` | AI-SDK package name | Compat only: `@ai-sdk/openai-compatible` & `@ai-sdk/openai` map to `openai-completions`, `@ai-sdk/anthropic` to `anthropic-messages`; any other package warns and assumes `openai-completions`. Ignored when `api` is set. |
|
|
128
|
+
| `baseURL` | URL | Required. The API root requests go to. Missing or invalid URL skips the provider. Also read from `options.baseURL` (top-level wins) |
|
|
129
|
+
| `apiKey` | `"$ENV_VAR"` \| `"{env:VAR}"` \| `"!command"` \| `false` | A key saved via `/connect` wins over this field. It is reference to the key, never the key itself. `"$VAR"` and `"{env:VAR}"` read that env variable; `"!command"` runs the command and uses its output; `false` = keyless endpoint, no auth header sent. A pasted raw secret is refused with a warning. |
|
|
130
|
+
| `headers` | object | Extra request headers, string values only. One non-string value drops the whole object with a warning |
|
|
131
|
+
| `models` | object | Required. `{}` per id is enough. Zero valid models skips the provider |
|
|
132
|
+
| `disabled` | `true` | Tombstone: the entry is skipped silently, no warning. `"enabled": false` means the same |
|
|
133
|
+
|
|
134
|
+
### Model fields
|
|
135
|
+
|
|
136
|
+
Every field is optional but we recommend adding `contextWindow` as a bare minimum. `"a-model-id": {}` is a complete declaration:
|
|
137
|
+
|
|
138
|
+
| Field | Values | Notes |
|
|
139
|
+
| --- | --- | --- |
|
|
140
|
+
| `name` | string | Display name in `/model` |
|
|
141
|
+
| `contextWindow` | number > 0 | Tokens. Compat alias: `limit.context` (`contextWindow` wins when both are set) Default: 200K|
|
|
142
|
+
| `maxOutput` | number > 0 | Tokens. Compat alias: `limit.output` |
|
|
143
|
+
| `reasoning` | boolean | `true` assumes the efforts `low` / `medium` / `high`; `false` declares none |
|
|
144
|
+
| `reasoningEfforts` | string[] | Exact valid set: `low` \| `medium` \| `high` \| `xhigh` \| `max`. Unknown levels are dropped with a warning naming that set |
|
|
145
|
+
| `cost` | object | $ per 1M tokens: `input`, `output`, `cacheRead`, `cacheWrite` (snake_case `cache_read` / `cache_write` accepted); `0` is valid for free models |
|
|
146
|
+
| `options` | object | Extra request-body params merged into every call for this model (`temperature`, `top_p`, …) |
|
|
147
|
+
|
|
148
|
+
A non-object model value skips that model with a warning; sibling models survive.
|
|
149
|
+
|
|
150
|
+
---
|
|
151
|
+
|
|
152
|
+
## Example provider config
|
|
153
|
+
|
|
154
|
+
Below are examples of BYOK providers added in `~/.commandcode/providers.json`. Command Code is the default provider, nothing to declare for it.
|
|
155
|
+
|
|
156
|
+
**OpenRouter**
|
|
157
|
+
|
|
158
|
+
```json
|
|
159
|
+
// ~/.commandcode/providers.json
|
|
160
|
+
{
|
|
161
|
+
"provider": {
|
|
162
|
+
"openrouter": {
|
|
163
|
+
"name": "OpenRouter",
|
|
164
|
+
"baseURL": "https://openrouter.ai/api/v1",
|
|
165
|
+
"apiKey": "$OPENROUTER_API_KEY",
|
|
166
|
+
"models": { "deepseek/deepseek-v4-flash": {} }
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
**Vercel AI Gateway**
|
|
173
|
+
|
|
174
|
+
```json
|
|
175
|
+
// ~/.commandcode/providers.json
|
|
176
|
+
{
|
|
177
|
+
"provider": {
|
|
178
|
+
"vercel": {
|
|
179
|
+
"name": "Vercel AI Gateway",
|
|
180
|
+
"baseURL": "https://ai-gateway.vercel.sh/v1",
|
|
181
|
+
"apiKey": "$AI_GATEWAY_API_KEY",
|
|
182
|
+
"models": { "deepseek/deepseek-v4-flash": {} }
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
```
|
|
187
|
+
|
|
188
|
+
**Cloudflare AI Gateway**: its OpenAI-compatible root carries your account and gateway ids, and model ids are `provider/model` as the gateway spells them:
|
|
189
|
+
|
|
190
|
+
```json
|
|
191
|
+
// ~/.commandcode/providers.json
|
|
192
|
+
{
|
|
193
|
+
"provider": {
|
|
194
|
+
"cf-gateway": {
|
|
195
|
+
"name": "Cloudflare AI Gateway",
|
|
196
|
+
"baseURL": "https://gateway.ai.cloudflare.com/v1/<account>/<gateway>/compat",
|
|
197
|
+
"apiKey": "$CF_AI_GATEWAY_TOKEN",
|
|
198
|
+
"models": { "anthropic/claude-sonnet-4-6": {} }
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
```
|
|
203
|
+
|
|
204
|
+
**Hugging Face router**
|
|
205
|
+
|
|
206
|
+
```json
|
|
207
|
+
// ~/.commandcode/providers.json
|
|
208
|
+
{
|
|
209
|
+
"provider": {
|
|
210
|
+
"huggingface": {
|
|
211
|
+
"name": "Hugging Face",
|
|
212
|
+
"baseURL": "https://router.huggingface.co/v1",
|
|
213
|
+
"apiKey": "$HF_TOKEN",
|
|
214
|
+
"models": { "Qwen/Qwen3.6-27B-Instruct": {} }
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
```
|
|
219
|
+
|
|
220
|
+
**Ollama (local, keyless)**
|
|
221
|
+
|
|
222
|
+
```json
|
|
223
|
+
// ~/.commandcode/providers.json
|
|
224
|
+
{
|
|
225
|
+
"provider": {
|
|
226
|
+
"ollama": {
|
|
227
|
+
"baseURL": "http://localhost:11434/v1",
|
|
228
|
+
"apiKey": false,
|
|
229
|
+
"models": { "llama3.3:70b": {} }
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
```
|
|
234
|
+
|
|
235
|
+
---
|
|
236
|
+
|
|
237
|
+
## Managing a provider
|
|
238
|
+
|
|
239
|
+
Selecting a custom provider in `/connect` opens its card: the endpoint, its declared model count (with a clickable `config: providers.json` link straight to the file), the key situation, and the actions that fit.
|
|
240
|
+
|
|
241
|
+
| Key state | Card shows | Actions |
|
|
242
|
+
| --- | --- | --- |
|
|
243
|
+
| Stored key | `key sk_… ✓ stored in auth.json` | enter save · `r` replace key · `c` clear · `u` update models · `d` delete |
|
|
244
|
+
| File reference | `key $VAR` | `r` store key · `u` update models · `d` delete |
|
|
245
|
+
| Keyless | `no key — the endpoint asks for none` | `r` store key · `u` update models · `d` delete |
|
|
246
|
+
| No key yet | `no key yet — requests fail until one is added` | enter add key · `u` update models · `d` delete |
|
|
247
|
+
|
|
248
|
+
In the `/connect` menu itself, a healthy provider row shows a green ✓ with its model count. Only `○ needs a key` appears when requests would fail without action.
|
|
249
|
+
|
|
250
|
+
Update `u` refetches the provider's model list (registry first, the endpoint's `/models` as fallback) and updates the provider's models. The key reference, headers, and wire are untouched.
|
|
251
|
+
|
|
252
|
+
Delete `d` removes the provider. It is deleted from providers.json, its stored key is cleared, and its models leave `/model` immediately; if it owned your active model, the session switches to the default model.
|
|
253
|
+
|
|
254
|
+
---
|
|
255
|
+
|
|
256
|
+
## Invalid config
|
|
257
|
+
|
|
258
|
+
If there is a malformed entry in providers config, it never breaks its siblings. It's skipped with a specific warning shown under the `/connect` list and on `--list-models`:
|
|
259
|
+
|
|
260
|
+
```
|
|
261
|
+
providers.json needs attention — one entry did not load as written:
|
|
262
|
+
provider.work-llm: no baseURL configured — provider skipped
|
|
263
|
+
```
|
|
264
|
+
|
|
265
|
+
An unreadable or unparseable file warns the same way (`providers config <path>: invalid JSON (details redacted)`). Your providers vanish for that run instead of crashing the CLI. The `/connect` writers never touch a file they can't parse: an add, model refetch, or remove against broken JSON refuses with nothing written.
|
|
266
|
+
|
|
267
|
+
---
|
|
268
|
+
|
|
269
|
+
## Local-only mode
|
|
270
|
+
|
|
271
|
+
For setups that must never contact Command Code's backend at all (a team running the CLI against their own endpoints, CI fleets, or other environments), they can turn on local-only mode:
|
|
272
|
+
|
|
273
|
+
```bash
|
|
274
|
+
cmd --local-only
|
|
275
|
+
# or via the environment:
|
|
276
|
+
CMD_LOCAL_ONLY=1 cmd
|
|
277
|
+
```
|
|
278
|
+
|
|
279
|
+
or persist it in `~/.commandcode/config.json`:
|
|
280
|
+
|
|
281
|
+
```json
|
|
282
|
+
{ "localOnly": true }
|
|
283
|
+
```
|
|
284
|
+
|
|
285
|
+
What it guarantees:
|
|
286
|
+
|
|
287
|
+
- **No telemetry, anywhere.** Trace exporters, lifecycle events, telemetry identity, and machine fingerprinting are all off. (`DO_NOT_TRACK=1` also stops all of these, including fingerprinting; local-only additionally blocks the non-telemetry backend traffic below.)
|
|
288
|
+
- **No billing reads.** The plan/credits prefetches never run; model pickers treat the absent plan as unrestricted and your providers gate access themselves.
|
|
289
|
+
- **A refusal transport.** The session's backend transport is replaced with one that throws a clear `LocalOnlyError` naming the route and the switch. Nothing can reach Command Code including a model id that would otherwise fall through to the Command Code provider.
|
|
290
|
+
|
|
291
|
+
What stops working, by design: Command Code catalog (gateway) models, `/share`, `/usage`, the server-proxied `web_search`/`web_fetch` tools, `cmd taste push`/`pull`, and backend agent generation. Your BYOK providers, and everything local keep working exactly as before.
|
|
292
|
+
|
|
293
|
+
---
|
|
294
|
+
|
|
295
|
+
## FAQs
|
|
296
|
+
|
|
297
|
+
Your BYOK session model, for everything. Compaction and summarization, sub-agents, title generation: all the side tasks default to the session model while a BYOK model is active, so nothing silently falls back to Command Code (or bills your plan) mid-session.
|
|
298
|
+
</p>
|
|
299
|
+
)
|
|
300
|
+
},
|
|
301
|
+
{
|
|
302
|
+
id: 'faq-keys-storage',
|
|
303
|
+
question: 'Where are my API keys stored?',
|
|
304
|
+
answer: (
|
|
305
|
+
<p>
|
|
306
|
+
Keys pasted in <code>/connect</code> live in <code>~/.commandcode/auth.json</code> (written <code>0600</code>), each under its provider's id, beside your Command Code login and subscription tokens. Logging out of Command Code strips only the account fields. Provider keys survive. Update a key any time with <code>r</code> on the provider's card in the /connect menu.
|
|
307
|
+
</p>
|
|
308
|
+
)
|
|
309
|
+
},
|
|
310
|
+
{
|
|
311
|
+
id: 'faq-keys-providers-json',
|
|
312
|
+
question: 'Can I put a key directly in providers.json?',
|
|
313
|
+
answer: (
|
|
314
|
+
<p>
|
|
315
|
+
Only as a reference: <code>"$ENV_VAR"</code>, <code>"{env:VAR}"</code>, or <code>"!command"</code> (see the schema above). A raw secret pasted into the file is refused at parse with a warning; the provider survives, only the key is ignored. Per request, a stored key wins over the file's reference.
|
|
316
|
+
</p>
|
|
317
|
+
)
|
|
318
|
+
},
|
|
319
|
+
{
|
|
320
|
+
id: 'faq-customize',
|
|
321
|
+
question: 'How do I customize a provider or its models?',
|
|
322
|
+
answer: (
|
|
323
|
+
<p>
|
|
324
|
+
Edit <code>~/.commandcode/providers.json</code>. The full schema is documented above, and changes apply live (reopen <code>/connect</code> or <code>/model</code>). Per model you can set the display name, context window, max output, reasoning efforts, cost, and extra request-body <code>options</code> like temperature. Per provider: headers, the wire (<code>api</code>), and the endpoint.
|
|
325
|
+
</p>
|
|
326
|
+
)
|
|
327
|
+
},
|
|
328
|
+
{
|
|
329
|
+
id: 'faq-same-id',
|
|
330
|
+
question: 'What if a model id exists on Command Code and my provider?',
|
|
331
|
+
answer: (
|
|
332
|
+
<p>
|
|
333
|
+
Both stay selectable. <code>/model</code> shows each under its own heading, and picking a row routes exactly where its heading says. Two of your own providers sharing an id works the same way: each qualified model id owns its route.
|
|
334
|
+
</p>
|
|
335
|
+
)
|
|
336
|
+
},
|
|
337
|
+
{
|
|
338
|
+
id: 'faq-project-scope',
|
|
339
|
+
question: 'Can a project or repo define its own providers?',
|
|
340
|
+
answer: (
|
|
341
|
+
<p>
|
|
342
|
+
No. BYOK providers are set only on the user-level, with config stored globally at <code>~/.commandcode/providers.json</code>.
|
|
343
|
+
</p>
|
|
344
|
+
)
|
|
345
|
+
},
|
|
346
|
+
{
|
|
347
|
+
id: 'faq-privacy',
|
|
348
|
+
question: 'Do BYOK requests or my keys ever touch Command Code?',
|
|
349
|
+
answer: (
|
|
350
|
+
<p>
|
|
351
|
+
No. Requests go straight from your machine to your endpoint, and keys never leave it. The only thing emitted is a trimmed telemetry span: model id, provider id, usage, latency, and finish reason. Never prompts, keys, endpoint URLs, or errors after scrubbing. <code>DO_NOT_TRACK=1</code> or local-only mode turns even that off.
|
|
352
|
+
</p>
|
|
353
|
+
)
|
|
354
|
+
}
|
|
355
|
+
]}
|
|
356
|
+
/>
|
|
@@ -77,7 +77,7 @@ Every built-in command, grouped by area. Aliases are shown in parentheses on the
|
|
|
77
77
|
| ----------------- | ---------------------------------------------------------------------------------------- |
|
|
78
78
|
| `/model [id]` | Switch between Command Code models - `/model <id>` applies directly, bare opens a picker |
|
|
79
79
|
| `/effort [level]` | Set reasoning effort for the current model (levels depend on the model) |
|
|
80
|
-
| `/
|
|
80
|
+
| `/connect` | Connect to AI providers. Command Code, [BYOK providers](./byok.md) and API keys |
|
|
81
81
|
| `/login` | Log in to Command Code or a provider |
|
|
82
82
|
| `/logout` | Log out of Command Code or a provider |
|
|
83
83
|
|
|
@@ -57,7 +57,7 @@ The model catalog — every id `/model`, `--model`, `model:effort` shorthand, an
|
|
|
57
57
|
| `gpt-5.6-sol` | GPT-5.6 Sol | 1.05M | low, medium, high, xhigh, max | $5/$30 · cache $0.5 (write $6.25) | GOAT and above | frontier model for complex professional work |
|
|
58
58
|
| `gpt-5.6-terra` | GPT-5.6 Terra | 1.05M | low, medium, high, xhigh, max | $2/$12 · cache $0.2 (write $2.5) | Pro and above | balances intelligence and cost |
|
|
59
59
|
| `gpt-5.6-luna` | GPT-5.6 Luna | 1.05M | low, medium, high, xhigh, max | $0.2/$1.2 · cache $0.02 (write $0.25) | Go and above | optimized for cost-sensitive workloads |
|
|
60
|
-
| `gpt-5.5` | GPT-5.5 |
|
|
60
|
+
| `gpt-5.5` | GPT-5.5 | 400K | low, medium, high, xhigh | $5/$30 · cache $0.5 (write $0) | Pro and above | latest frontier model for general complex work |
|
|
61
61
|
| `gpt-5.4` | GPT-5.4 | 400K | low, medium, high, xhigh | $2.5/$15 · cache $0.25 (write $0) | Pro and above | frontier model for general complex work |
|
|
62
62
|
| `gpt-5.3-codex` | GPT-5.3 Codex | 400K | low, medium, high, xhigh | $2/$8 · cache $0.5 (write $0) | Pro and above | frontier coding model |
|
|
63
63
|
| `gpt-5.4-mini` | GPT-5.4 Mini | 400K | low, medium, high | $0.75/$4.5 · cache $0.075 (write $0) | Pro and above | fast, cost-effective model for everyday tasks |
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
- /mcp: Manage MCP server connections
|
|
37
37
|
- /model: Switch between Command Code models
|
|
38
38
|
- /effort: Set reasoning effort for the current model
|
|
39
|
-
- /
|
|
39
|
+
- /connect: Connect to AI providers. Command Code, BYOK providers and API keys
|
|
40
40
|
- /compact: Compact the conversation history
|
|
41
41
|
- /compact-mode: Select a compact mode to compact sessions
|
|
42
42
|
- /config: Search and change settings, including which model runs each built-in task
|
|
@@ -123,6 +123,7 @@
|
|
|
123
123
|
- --theme <theme>: Set the color theme (dark or light)
|
|
124
124
|
- --config <key=value>: Set any setting headlessly, e.g. --config theme=dark (repeatable) — the CLI form of /config
|
|
125
125
|
- --list-models: List the models available for use
|
|
126
|
+
- --local-only: For BYOK: local-only with your BYOK providers, no Command Code traffic (same as CMD_LOCAL_ONLY=1)
|
|
126
127
|
- --plan: Start in plan mode
|
|
127
128
|
- --permission-mode <mode>: Set permission mode (standard, plan, auto-accept)
|
|
128
129
|
- --auto-accept: Start in auto-accept mode
|
|
@@ -10,7 +10,6 @@ The executable registry is authoritative. Run `cmd config list --scope effective
|
|
|
10
10
|
| `permissions.defaultMode` | user | enum | `default`, `plan`, `auto-accept`, `dont-ask` | Default permission mode for tool usage. A long-lived host may also apply the change to its current session. "bypass" cannot be set here. |
|
|
11
11
|
| `theme` | user | enum | `dark`, `light`, `auto` | Terminal color theme (same setting as /theme). Auto automatically detects your terminal background and uses light or dark to match. |
|
|
12
12
|
| `compact-mode` | user | enum | `default`, `fast` | Auto-compact aggressiveness when context fills up (same setting as /compact-mode). |
|
|
13
|
-
| `force-oauth` | user | boolean | `true`, `false` | Require OAuth login and block API-key authentication. |
|
|
14
13
|
| `tree-filter-mode` | user | enum | `default`, `no-tools`, `user-only`, `labeled-only`, `all` | Default filter when opening /tree. |
|
|
15
14
|
| `on-demand-tool-descriptions` | user | boolean | `true`, `false` | Explain shell commands on permission prompts only when you press ctrl+e (default). Turn off to generate every explanation upfront. |
|
|
16
15
|
| `image-vision` | user | enum | `ask`, `enabled`, `disabled` | Let a text-only model read attached images by describing them with the vision model ("Ask on first use" prompts the first time you attach an image). |
|