text-translate/module.yaml
flemming-it 4d6acab6a1
Some checks failed
CI / Linux x86_64 (Forgejo) (push) Failing after 2s
sign-bundle / sign (push) Failing after 1m48s
feat: api accepts 'vllm' as a first-class value
'openai' reads as the cloud company — an operator running
self-hosted vLLM should be able to write what they mean. The new
value speaks the identical OpenAI wire (a guard test asserts the
emitted request stays byte-identical to api: openai, so the alias
can never drift into a dialect) but yields vLLM-specific error
hints (vllm serve, port 8000) instead of generic OpenAI prose.
Manifest + docs name the value in DE and EN.

Signed-off-by: flemming-it <sf@flemming.it>
2026-08-20 17:13:42 +02:00

125 lines
4 KiB
YAML

schema_version: 3
provider: chain
name: text-translate
version: 0.2.0
provides:
- capability: text.translate
version: 0.2.0
inputs:
text:
type: text
description:
en: Source text to translate.
de: Quelltext, der übersetzt werden soll.
target_language:
type: text
description:
en: |
Target language name in plain English (e.g. "German",
"French", "ja-JP" — anything the configured LLM
understands).
de: |
Zielsprache in Klartext (z. B. "German", "French",
"ja-JP" — alles was das konfigurierte LLM versteht).
source_language:
type: text
description:
en: |
Optional source language hint. Empty = let the model
auto-detect.
de: |
Optionaler Hinweis zur Quellsprache. Leer = das Modell
erkennt sie selbst.
endpoint:
type: text
description:
en: |
Chat endpoint URL matching the selected api:
ollama "http://localhost:11434/api/chat",
openai "http://localhost:8000/v1/chat/completions"
(vLLM etc.), anthropic "https://.../v1/messages".
de: |
Chat-Endpunkt-URL passend zum gewählten api:
ollama "http://localhost:11434/api/chat",
openai "http://localhost:8000/v1/chat/completions"
(vLLM u. a.), anthropic "https://.../v1/messages".
api:
type: text
description:
en: |
Optional wire format: "ollama" (default), "vllm"
(self-hosted vLLM), "openai" (OpenAI or other
OpenAI-compatible servers such as LM Studio), or
"anthropic" (Messages API). vllm and openai speak the
same wire; the separate value exists so you can write
what you mean and get vLLM-specific hints. Empty = ollama.
de: |
Optionales Wire-Format: "ollama" (Default), "vllm"
(selbst gehostetes vLLM), "openai" (OpenAI oder andere
OpenAI-kompatible Server wie LM Studio) oder "anthropic"
(Messages API). vllm und openai sprechen dieselbe Wire;
der eigene Wert existiert, damit Du schreibst, was Du
meinst, und vLLM-spezifische Hinweise bekommst.
Leer = ollama.
model:
type: text
description:
en: Model identifier as registered with the endpoint (e.g. "qwen2.5:14b").
de: Modell-Identifier wie am Endpunkt registriert (z. B. "qwen2.5:14b").
api_key:
type: text
description:
en: |
Optional API key. Sent as "Authorization: Bearer" for
ollama/openai and as "x-api-key" for anthropic. Empty
for local endpoints.
de: |
Optionaler API-Key. Bei ollama/openai als
"Authorization: Bearer", bei anthropic als "x-api-key"
gesendet. Leer für lokale Endpunkte.
outputs:
translation:
type: text
description:
en: The translated text.
de: Der übersetzte Text.
source_language:
type: text
description:
en: Echo of the source-language input for downstream audit.
de: Echo des source_language-Inputs für Downstream-Audit.
target_language:
type: text
description:
en: Echo of the target-language input.
de: Echo des target_language-Inputs.
model_endpoint:
type: text
description:
en: Endpoint the translation was generated against.
de: Endpunkt, gegen den die Übersetzung erzeugt wurde.
model_name:
type: text
description:
en: Model identifier as supplied to the LLM API.
de: An die LLM-API übergebenes Modell.
model_digest:
type: text
description:
en: |
SHA-256 digest of the served model, best-effort probe.
Ollama only — empty for other endpoints (OpenAI / vLLM /
Anthropic expose no digest API).
de: |
SHA-256-Digest des bedienten Modells (Best-Effort-Probe).
Nur bei Ollama — leer bei anderen Endpunkten (OpenAI /
vLLM / Anthropic bieten keine Digest-API).
permissions:
- "net: localhost"
- "net: 127.0.0.1"
- "net: api.openai.com"
- "net: api.anthropic.com"