feat: add remote config overrides to memorySearch
This commit is contained in:
committed by
Peter Steinberger
parent
4086408b10
commit
ba316a10cc
@@ -81,8 +81,28 @@ Defaults:
|
||||
|
||||
Remote embeddings **require** an OpenAI API key (`OPENAI_API_KEY` or
|
||||
`models.providers.openai.apiKey`). Codex OAuth only covers chat/completions and
|
||||
does **not** satisfy embeddings for memory search. If you don't want to set an
|
||||
API key, use `memorySearch.provider = "local"` or set
|
||||
does **not** satisfy embeddings for memory search.
|
||||
|
||||
If you want to use a **custom OpenAI-compatible endpoint** (like Gemini, OpenRouter, or a proxy),
|
||||
you can use the `remote` configuration:
|
||||
|
||||
```json5
|
||||
agents: {
|
||||
defaults: {
|
||||
memorySearch: {
|
||||
provider: "openai",
|
||||
model: "text-embedding-3-small",
|
||||
remote: {
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta/openai/",
|
||||
apiKey: "YOUR_GEMINI_API_KEY",
|
||||
headers: { "X-Custom-Header": "value" }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
If you don't want to set an API key, use `memorySearch.provider = "local"` or set
|
||||
`memorySearch.fallback = "none"`.
|
||||
|
||||
Config example:
|
||||
|
||||
@@ -241,6 +241,14 @@ Save to `~/.clawdbot/clawdbot.json` and you can DM the bot from that number.
|
||||
prompt: "HEARTBEAT",
|
||||
ackMaxChars: 300
|
||||
},
|
||||
memorySearch: {
|
||||
provider: "openai",
|
||||
model: "text-embedding-004",
|
||||
remote: {
|
||||
baseUrl: "https://generativelanguage.googleapis.com/v1beta/openai/",
|
||||
apiKey: "${GEMINI_API_KEY}"
|
||||
}
|
||||
},
|
||||
sandbox: {
|
||||
mode: "non-main",
|
||||
perSession: true,
|
||||
|
||||
Reference in New Issue
Block a user