LLM Bot Service

Configure the optional LLM-backed bot service for summaries, titles, NER, clustering, and sentiment.

llm-bot is an optional HTTP service used by worker bots for LLM-backed analysis. The Compose deployment includes it as ghcr.io/taranis-ai/taranis-llm-bot:${TARANIS_BOT_TAG:-stable}.

It talks to an OpenAI-compatible Responses API and exposes endpoints for:

EndpointPurpose
/summarizeGenerate a story summary.
/titleGenerate a concise story title.
/nerExtract named entities.
/clusterCluster related stories.
/sentimentAnalyze sentiment.
/ner-linkExtract entities and link them to candidates.
/linkLink supplied entities to candidates.
/healthReadiness check.
/infoNon-secret service capabilities and active config.

Compose configuration

Set these values in docker/.env:

VariablePurpose
BOT_API_KEYShared secret used by workers when calling bot services.
LLM_BASE_URLBase URL of the upstream OpenAI-compatible API.
LLM_API_KEYUpstream API key.
LLM_MODELModel name, unless the upstream provides a default.
LLM_TIMEOUTUpstream request timeout in seconds.
LLM_BOT_PORTInternal service port, default 8000.

Advanced optional settings:

VariablePurpose
LLM_REASONING_PROFILEPrompt handling profile for models that emit reasoning text. Supported values include none, ministral, and gemma.
LLM_REASONING_EFFORTOptional upstream reasoning effort value, for example low, medium, or high.
LLM_STRIP_REASONING_OUTPUTStrip reasoning blocks before parsing model output.
LLM_PARSE_REASONING_AS_OUTPUTUse structured reasoning text as fallback output when the provider emits no final message.
LOOKUP_BASE_URLOptional lookup API used by entity linking.
LOOKUP_API_KEYAPI key for the lookup API.
LOOKUP_DEFAULT_LANGUAGEDefault language for entity lookup.
LOOKUP_CANDIDATE_LIMITNumber of lookup candidates considered per entity.
NER_LINKING_ENABLEDEnables linked NER output paths.
NER_LINKING_MODEdeterministic or llm.
SUMMARY_ROUTE_PATHOverride the summary route path. Default: /summarize.
NER_ROUTE_PATHOverride the NER route path. Default: /ner.

Keep LLM_API_KEY, BOT_API_KEY, and any provider credentials out of logs and shared files. The service should stay on the private application network; do not publish it directly to the internet.

Worker integration

The Compose deployment wires these worker endpoints to llm-bot by default:

Worker variableDefault endpoint
SUMMARY_API_ENDPOINThttp://llm-bot:8000/summarize
NLP_API_ENDPOINThttp://llm-bot:8000/ner
STORY_API_ENDPOINThttp://llm-bot:8000/cluster

Bot endpoint parameters saved in the admin UI take precedence over worker defaults. If an upgraded instance still has old standalone bot hostnames such as http://summary_bot:8000, http://nlp_bot:8000, or http://story_bot:8000, update those bot parameters to the llm-bot endpoints or clear the override.

For title generation, set TITLE_ENDPOINT on the Summary Bot to:

http://llm-bot:8000/title

For sentiment analysis, set the Sentiment Analysis Bot BOT_ENDPOINT to:

http://llm-bot:8000/sentiment

Each bot can override the default endpoint and timeout with its own parameters. See Bots for the user-facing bot settings.

Canonical llm-bot paths are accepted with or without a trailing slash.

Validation

Check service health from inside the application network:

curl http://llm-bot:8000/health

If API_KEY is configured on the service, protected task endpoints require:

Authorization: Bearer <BOT_API_KEY>

Use /info to confirm endpoint paths and non-secret feature settings. It reports whether lookup and linking are configured without exposing API keys.