diff options
Diffstat (limited to '')
| -rw-r--r-- | README.md | 31 |
1 files changed, 26 insertions, 5 deletions
| @@ -55,11 +55,32 @@ export OPENCODE_API_KEY=... # or write it to ~/.config/agent686/key | |||
| 55 | ./agent686 --yolo "..." # approve every tool call | 55 | ./agent686 --yolo "..." # approve every tool call |
| 56 | ``` | 56 | ``` |
| 57 | 57 | ||
| 58 | Provider is OpenCode Go, `chat/completions`, model `deepseek-v4.1-flash` by | 58 | The provider is a *type* plus a URL, both speaking OpenAI-compatible chat |
| 59 | default; `--provider ollama|openai|openrouter|vllm|llamacpp` switches to another | 59 | completions: |
| 60 | OpenAI-compatible endpoint, with `--lenient` for servers that omit `[DONE]`. | 60 | |
| 61 | `HTTPS_PROXY`/`NO_PROXY` are honoured. Every request carries a stable | 61 | - `opencode` (default) — `https://opencode.ai/inference/go/openai/v1`, and it |
| 62 | `x-opencode-session` header, which the service uses for routing and prompt caching. | 62 | requires a stable `x-opencode-session` header per conversation. |
| 63 | - `openai-compatible` — any endpoint (Ollama, llama.cpp, vLLM, OpenRouter, …), | ||
| 64 | given via `--base-url`/`AGENT686_BASE_URL`/config `url`; no session header. | ||
| 65 | |||
| 66 | `--lenient` tolerates servers that omit `[DONE]`/`usage`; `HTTPS_PROXY`/`NO_PROXY` | ||
| 67 | are honoured. | ||
| 68 | |||
| 69 | ## Config file | ||
| 70 | |||
| 71 | `~/.config/agent686/config.toml` (override with `AGENT686_CONFIG`) sets defaults | ||
| 72 | the CLI and environment can then override: | ||
| 73 | |||
| 74 | ```toml | ||
| 75 | provider = "opencode" # or "openai-compatible" | ||
| 76 | url = "http://localhost:11434/v1" # for openai-compatible | ||
| 77 | model = "deepseek-v4.1-flash" | ||
| 78 | lenient = false | ||
| 79 | system_ca = false | ||
| 80 | yolo = false | ||
| 81 | allow_home = false # permit --yolo in $HOME or / | ||
| 82 | allow_nogit = false # permit --yolo outside a git repository | ||
| 83 | ``` | ||
| 63 | 84 | ||
| 64 | In a terminal: up/down walks history, bracketed paste arrives as one block | 85 | In a terminal: up/down walks history, bracketed paste arrives as one block |
| 65 | (multi-line is fine), ctrl-c abandons the line, ctrl-d exits. `/undo` reverts the | 86 | (multi-line is fine), ctrl-c abandons the line, ctrl-d exits. `/undo` reverts the |
