feat: Embeddings über llama.cpp im Gateway anbieten

This commit is contained in:
2026-11-18 20:02:37 +01:00
parent 3509e731cd
commit 2c1a3d487a
12 changed files with 268 additions and 14 deletions

View File

@ -2,8 +2,8 @@
//!
//! Stand M2.3: `GET /v1/models`, `GET /v1/models/{id}`,
//! `POST /v1/chat/completions` (mit SSE-Streaming), `POST /v1/audio/speech` (Sprachausgabe), `GET /gateway/v1/health`,
//! API-Key-Authentifizierung und das OpenAI-Fehlerformat. Weitere Endpunkte
//! (Completions, Embeddings, Bilder) und die Gateway-Verwaltung folgen später.
//! `POST /v1/embeddings`, API-Key-Authentifizierung und das OpenAI-Fehlerformat.
//! Weitere Endpunkte (Completions, Bilder) folgen später.
//!
//! Seit 0.1.5 teilt der Scheduler (Modul `runtime`, Logik in
//! `nexus-scheduler`) jeder Anfrage eine Instanz zu: Ressourcen je GPU,
@ -50,6 +50,7 @@ pub fn router(state: Arc<AppState>) -> Router {
.route("/v1/models/{id}", get(models::retrieve))
.route("/v1/chat/completions", post(chat::completions))
.route("/v1/audio/speech", post(chat::speech))
.route("/v1/embeddings", post(chat::embeddings))
.route("/gateway/v1/health", get(health))
.route("/gateway/v1/metrics", get(metrics_endpoint))
.route("/gateway/v1/status", get(status_endpoint))