Commit Graph

14 Commits

Author SHA1 Message Date
VuQuangBao 03467aeaf2 Attach real input/output/token usage to provider spans for Langfuse cost tracking
Langfuse showed $0.00 cost on every trace even after tracing was wired up:
provider.bedrock_converse.* spans carried only latency, no content or usage.
Converse's own response already includes token usage -- it just wasn't being
read. Captured on the adapter (last_usage, no interface change) and attached
to the span using Langfuse's own OTel attribute convention
(langfuse.observation.*), which its docs say takes precedence over generic
GenAI attributes. Verified live: a fresh trace now shows real prompt/completion
tokens and Langfuse computes real cost once given the model's actual per-token
price.
2026-08-25 16:44:55 +07:00
VuQuangBao f3eaab0948 Make a Langfuse trace worth opening: question, answer, session, no probe noise 2026-08-21 14:45:32 +07:00
VuQuangBao 53582b6030 Add Langfuse as a self-hosted eval and trace viewer 2026-08-21 10:35:25 +07:00
VuQuangBao a1de4715a4 Add read-only production runtime audit 2026-08-17 11:17:40 +07:00
VuQuangBao 057d4ed9dc Wire up query history: localStorage session persistence + sidebar UI 2026-08-14 17:44:36 +07:00
VuQuangBao a4819b8653 Fix migration workflow: upload as artifact instead of scp to practice EC2 2026-08-13 11:14:25 +07:00
VuQuangBao 7ebbe1f309 Add production condition retrieval smoke test 2026-08-11 14:58:28 +07:00
VuQuangBao 59e6ad2d0d Verify exact production traces and record rollout 2026-08-11 11:29:59 +07:00
VuQuangBao 97cb6d16f4 Remove corpus counts from chat chrome 2026-08-10 17:26:58 +07:00
VuQuangBao 46469468bb Wire token-budget packing into the overview/rerank fallback path 2026-08-10 12:02:31 +07:00
VuQuangBao 60b4397032 Fix ai-service Dockerfile: bake in drug_entities.json, override its path 2026-08-10 10:35:13 +07:00
VuQuangBao a4b8e1c4db Checkpoint frontend UI/UX overhaul and ingestion embed benchmark work 2026-08-06 17:21:21 +07:00
VuQuangBao 1e8cbdb586 Fix live multi-turn: pass the resolved drug, stop did-you-mean garbage 2026-08-05 16:54:35 +07:00
VuQuangBao ef08b4929e Wire the guarded conversational RAG answer layer end-to-end 2026-08-05 14:33:13 +07:00