Sdm0 commited on
Commit
784c0b3
·
verified ·
1 Parent(s): 430b93c

Deploy aa69a0b9

Browse files
Files changed (1) hide show
  1. observability.py +6 -1
observability.py CHANGED
@@ -93,7 +93,12 @@ def get_langfuse_handler():
93
  # otherwise the handler receives a disabled client that drops traces.
94
  # Both classes read LANGFUSE_PUBLIC_KEY / LANGFUSE_SECRET_KEY from
95
  # environment variables automatically.
96
- Langfuse()
 
 
 
 
 
97
  return CallbackHandler()
98
  except ImportError:
99
  logger.warning(
 
93
  # otherwise the handler receives a disabled client that drops traces.
94
  # Both classes read LANGFUSE_PUBLIC_KEY / LANGFUSE_SECRET_KEY from
95
  # environment variables automatically.
96
+ #
97
+ # The ``x-langfuse-ingestion-version=4`` header is required for the
98
+ # default OTLP exporter to authenticate properly with Langfuse Cloud.
99
+ Langfuse(
100
+ additional_headers={"x-langfuse-ingestion-version": "4"},
101
+ )
102
  return CallbackHandler()
103
  except ImportError:
104
  logger.warning(