CortexDB Docs
Integrations

Groq

Route CortexDB's answer and extraction LLM calls through Groq's fast inference API.

Groq exposes an OpenAI-compatible API, so CortexDB's LLM routers point straight at it for very low-latency answer generation.

Set both the extraction and answer lanes

CORTEX_LLM_* is the entity-extraction lane; /v1/answer uses the separate CORTEX_ANSWER_* lane (default anthropic/claude-opus-4-6). Setting CORTEX_LLM_* alone leaves /v1/answer on the disabled default — set both. See Self-hosting defaults.

Deployment configuration

# Extraction lane
CORTEX_LLM_URL=https://api.groq.com/openai/v1
CORTEX_LLM_MODEL=llama-3.3-70b-versatile
CORTEX_LLM_API_KEY=$GROQ_API_KEY

# Answer lane — Groq is OpenAI-compatible, so use the openai provider + Groq URL
CORTEX_ANSWER_PROVIDER=openai
CORTEX_ANSWER_URL=https://api.groq.com/openai/v1
CORTEX_ANSWER_MODEL=llama-3.3-70b-versatile
CORTEX_ANSWER_API_KEY=$GROQ_API_KEY

Embeddings run elsewhere

Groq does not serve embeddings — keep CORTEX_EMBEDDING_* on OpenAI or a local Ollama (nomic-embed-text). See Embeddings.

Restart the service, then confirm /v1/answer routes to Groq via diagnostics.answer_model.

Per-request override

client.answer(scope="org:acme/user:alice", question="…", answer_model="openai/llama-3.3-70b-versatile")

See also

On this page