feat(opencode): remplace le provider Ollama par llama.cpp
Le tool-calling local ne fonctionnait jamais via Ollama. Refonte du support local d'OpenCode autour de llama.cpp: profil, catalogue, matérialisation de la config OpenCode et surface first-run alignés sur llama-server (backend + frontend). QA vert (commandes réelles): domain 244, application 81+64, infra 263 (10 échecs = bind-port sandbox identiques sur develop, non-régression), frontend 574, tsc propre. Réserve E2E live non bloquante faute de llama-server joignable. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@ -662,10 +662,31 @@ export interface HttpChatConfig {
|
||||
maxToolIterations?: number;
|
||||
}
|
||||
|
||||
/** Configuration for an OpenCode process-backed profile. */
|
||||
/**
|
||||
* Configuration for an OpenCode process-backed profile pointed at its own
|
||||
* llama.cpp (OpenAI-compatible) endpoint. Mirror of the backend `OpenCodeConfig`
|
||||
* (camelCase wire format: `baseURL`, `apiKey?`, `model`, `reasoning?`,
|
||||
* `attachment?`). OpenCode is a locally-piloted CLI, distinct from the in-process
|
||||
* {@link HttpChatConfig} adapter.
|
||||
*/
|
||||
export interface OpenCodeConfig {
|
||||
/** Full OpenCode model id, for example `ollama/qwen3-coder:30b`. */
|
||||
model?: string;
|
||||
/**
|
||||
* OpenAI-compatible base URL served by `llama-server` (http/https), for
|
||||
* example `http://localhost:8080/v1`.
|
||||
*/
|
||||
baseURL: string;
|
||||
/**
|
||||
* Optional API key forwarded to the provider — the key *itself*, not an env
|
||||
* var name (a local llama.cpp typically needs none / a placeholder). Omitted
|
||||
* when blank (mirrors the backend `skip_serializing_if`).
|
||||
*/
|
||||
apiKey?: string;
|
||||
/** Model name served by `llama-server`, for example `qwen3-coder-30b`. */
|
||||
model: string;
|
||||
/** Enables model reasoning. Effective default: `true`. */
|
||||
reasoning?: boolean;
|
||||
/** Enables attachments. Effective default: `false`. */
|
||||
attachment?: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user