refactor(config): drop agent.provider

This commit is contained in:
Peter Steinberger
2025-12-26 00:43:44 +01:00
parent 8b815bce94
commit 1ef888ca23
14 changed files with 98 additions and 61 deletions

View File

@@ -117,8 +117,7 @@ Example:
{
logging: { level: "info" },
agent: {
provider: "anthropic",
model: "claude-opus-4-5",
model: "anthropic/claude-opus-4-5",
workspace: "~/clawd",
thinkingDefault: "high",
timeoutSeconds: 1800,

View File

@@ -113,7 +113,7 @@ Controls inbound/outbound prefixes and timestamps.
### `agent`
Controls the embedded agent runtime (provider/model/thinking/verbose/timeouts).
Controls the embedded agent runtime (model/thinking/verbose/timeouts).
`allowedModels` lets `/model` list/filter and enforce a per-session allowlist
(omit to show the full catalog).
@@ -141,8 +141,9 @@ Controls the embedded agent runtime (provider/model/thinking/verbose/timeouts).
}
```
`agent.model` can be set as `provider/model` (e.g. `anthropic/claude-opus-4-5`).
When present, it overrides `agent.provider` (which becomes optional).
`agent.model` should be set as `provider/model` (e.g. `anthropic/claude-opus-4-5`).
If you omit the provider, CLAWDIS currently assumes `anthropic` as a temporary
deprecation fallback.
`agent.bash` configures background bash defaults:
- `backgroundMs`: time before auto-background (ms, default 20000)
@@ -165,11 +166,11 @@ When `models.providers` is present, Clawdis writes/merges a `models.json` into
- default behavior: **merge** (keeps existing providers, overrides on name)
- set `models.mode: "replace"` to overwrite the file contents
Select the model via `agent.provider` + `agent.model`.
Select the model via `agent.model` (provider/model).
```json5
{
agent: { provider: "custom-proxy", model: "llama-3.1-8b" },
agent: { model: "custom-proxy/llama-3.1-8b" },
models: {
mode: "merge",
providers: {

View File

@@ -47,14 +47,14 @@ Offer an “API key” option, but for now it is **instructions only**:
Note: environment variables are often confusing when the Gateway is launched by a GUI app (launchd environment != your shell).
### Provider/model safety rule
### Model safety rule
Clawdis should **always pass** `--provider` and `--model` when invoking the embedded agent (dont rely on defaults).
Clawdis should **always pass** `--model` when invoking the embedded agent (dont rely on defaults).
Example (CLI):
```bash
clawdis agent --mode rpc --provider anthropic --model claude-opus-4-5 "<message>"
clawdis agent --mode rpc --model anthropic/claude-opus-4-5 "<message>"
```
If the user skips auth, onboarding should be clear: the agent likely wont respond until auth is configured.