fix(llmops): 鎖定 langfuse SDK v2.x (避免 v4.x OTLP 不相容)
Some checks failed
CD Pipeline / build-and-deploy (push) Has been cancelled
E2E Health Check / e2e-health (push) Has been cancelled
CD Pipeline (Dev) / build-and-deploy-dev (push) Successful in 2m40s

問題: langfuse>=2.0.0 安裝了 v4.0.5,該版本移除 client.trace() 改用 OTLP
根因: Langfuse server v2.95.11 的 OTLP endpoint (/api/public/otel) 返回 404
     但舊版 /api/public/ingestion endpoint 正常 (HTTP 207)
修復: 鎖定 langfuse>=2.0.0,<4.0.0,保留 client.trace() API 相容性

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
OG T
2026-04-01 22:49:00 +08:00
parent fccc69972d
commit 2aeec34735

View File

@@ -40,7 +40,8 @@ opentelemetry-instrumentation-logging>=0.41b0
# Langfuse (LLMOps Observability)
# Phase 15.1: LLM 呼叫追蹤、成本監控、Prompt 版本管理
# ==========================================================================
langfuse>=2.0.0
# 2026-04-01 Claude Code: 鎖定 v2.x — v4.x 改用 OTLP與 langfuse_client.py 的 client.trace() 不相容
langfuse>=2.0.0,<4.0.0
# Development
pytest>=7.4.0