langfuse generation spans with token usage; switch llm to vllm (qwen2.5-coder-7b on mcrndeb)

This commit is contained in:
2026-06-03 10:33:22 -03:00
parent bd34c8c5ce
commit 61494362a3
7 changed files with 103 additions and 25 deletions

View File

@@ -13,14 +13,20 @@ spec:
labels:
app: api
spec:
# lng.local.ar resolves to ::1 via the host's dnsmasq → coredns chain,
# which is the pod's own loopback (wrong). Override to the kind bridge
# gateway so traffic from this pod reaches the host's system Caddy and
# gets reverse-proxied to Langfuse on :3000.
hostAliases:
# lng.local.ar resolves to ::1 via the host's dnsmasq → coredns chain,
# which is the pod's own loopback (wrong). Override to the kind bridge
# gateway so traffic from this pod reaches the host's system Caddy and
# gets reverse-proxied to Langfuse on :3000.
- ip: "172.19.0.1"
hostnames:
- "lng.local.ar"
# mcrndeb is the GPU box on the LAN (vLLM lives there). kind-nvi
# pods reach it via routing through the host; we just need the name
# to resolve since coredns doesn't know about LAN hostnames.
- ip: "192.168.1.3"
hostnames:
- "mcrndeb"
containers:
- name: api
image: nvi-api

View File

@@ -13,7 +13,13 @@ data:
# LLM. Supported providers: groq, anthropic, openai.
# Secrets (*_API_KEY) live in the Secret built by kustomize from .env.
LLM_PROVIDER: "groq"
# Flip LLM_PROVIDER to switch — the other configs stay so we can A/B easily.
LLM_PROVIDER: "openai"
# Local vLLM serving Qwen2.5-Coder-7B-Instruct-AWQ on mcrndeb.
OPENAI_BASE_URL: "http://mcrndeb:11000/v1"
OPENAI_MODEL: "Qwen/Qwen2.5-Coder-7B-Instruct-AWQ"
GROQ_MODEL: "llama-3.3-70b-versatile"
ANTHROPIC_MODEL: "claude-sonnet-4-6"