feat(session): adapter HTTP OpenAI-compatible pour profils locaux/LAN (#14)

Ajoute un adapter de session HTTP OpenAI-compatible, purement additif,
permettant d'intégrer des modèles locaux/LAN comme profils IdeA canoniques
avec parité tool-calling/MCP.

- domain: extension du profil et des ports pour l'adapter OpenAI-compatible
- infrastructure: adapter openai_compat + routage factory
- app-tauri: mapping des outils OpenAI (openai_tools) + wiring state/lib
- application: catalogue d'agents + tests de use-cases profils

Validé QA (backend GO): round-trip byte-identique Claude/Codex, mapping
erreurs, dégradation tools, conversation_id None, conformance un seul Final,
routage factory. Suites vertes domain 467 / application 530 /
infrastructure 523 / app-tauri 247, 0 échec.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-07-07 22:09:16 +02:00
parent cb20fabdf4
commit aab4bcafb6
14 changed files with 1794 additions and 25 deletions

View File

@ -16,6 +16,7 @@ application = { workspace = true }
tokio = { workspace = true, features = ["process", "time"] }
uuid = { workspace = true }
async-trait = { workspace = true }
futures-util = { workspace = true }
# Ergonomic error enums for the MCP adapter (tool-mapping / transport errors).
thiserror = { workspace = true }
serde = { workspace = true }
@ -38,7 +39,7 @@ notify = "6"
# §14.5.3). `default-features = false` + `rustls-tls` keeps it OpenSSL-free so the
# AppImage stays portable; pulled in *only* under the `vector-http` feature so the
# zero-dependency default (`none` strategy) compiles nothing extra.
reqwest = { version = "0.12", default-features = false, features = ["json", "rustls-tls"], optional = true }
reqwest = { version = "0.12", default-features = false, features = ["json", "rustls-tls", "stream"] }
# Optional in-process ONNX embedder (LOT C1b, §14.5.3). rustls all the way down
# (HF model download + ort binaries fetched at build time, NOT load-dynamic) so the
# AppImage stays self-contained and OpenSSL-free. Pulled in *only* under the
@ -51,6 +52,6 @@ landlock = "0.4.5"
[features]
# Real HTTP-backed embedders (`localServer` Ollama/llama.cpp, `api` OpenAI/Voyage…).
# OFF by default: the founding posture is `none` ⇒ naïve recall, zero dependency.
vector-http = ["dep:reqwest"]
vector-http = []
# Real in-process ONNX embedder (`localOnnx`). OFF by default, same posture.
vector-onnx = ["dep:fastembed"]