mirror of
https://github.com/sst/opencode.git
synced 2025-07-07 16:14:59 +00:00
docs: readme
This commit is contained in:
parent
676d75ee75
commit
54c86ed43a
1 changed files with 3 additions and 4 deletions
|
@ -73,14 +73,15 @@ model = "claude-sonnet-4-20250514"
|
|||
autoupdate = true
|
||||
```
|
||||
|
||||
You can also extend the models.dev database with your own providers and models by placing a `provider.toml` file in `~/.config/opencode/providers`
|
||||
You can also extend the models.dev database with your own providers by mirroring the structure found [here](https://github.com/sst/models.dev/tree/dev/providers/anthropic)
|
||||
|
||||
Start with a `provider.toml` file in `~/.config/opencode/providers`
|
||||
|
||||
```toml
|
||||
# ~/.config/opencode/providers/openrouter/provider.toml
|
||||
[provider]
|
||||
name = "OpenRouter"
|
||||
env = ["OPENROUTER_API_KEY"]
|
||||
id = "openrouter"
|
||||
npm = "@openrouter/ai-sdk-provider"
|
||||
```
|
||||
|
||||
|
@ -104,8 +105,6 @@ context = 200_000
|
|||
output = 50_000
|
||||
```
|
||||
|
||||
This mirrors the structure found [here](https://github.com/sst/models.dev/tree/dev/providers/anthropic)
|
||||
|
||||
### Project Config
|
||||
|
||||
Project configuration is optional. You can place an `opencode.json` file in the root of your repo and is meant to be checked in and shared with your team.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue