forked from phoenix/litellm-mirror
fix langfuse log metadata
This commit is contained in:
parent
edb34a5439
commit
d6ba50319c
1 changed files with 7 additions and 3 deletions
|
@ -1310,9 +1310,13 @@ class Logging:
|
||||||
verbose_logger.info(f"\033[92m{curl_command}\033[0m\n")
|
verbose_logger.info(f"\033[92m{curl_command}\033[0m\n")
|
||||||
|
|
||||||
# check if user wants the raw request logged to their logging provider (like LangFuse)
|
# check if user wants the raw request logged to their logging provider (like LangFuse)
|
||||||
_litellm_params = self.model_call_details.get("litellm_params", {})
|
try:
|
||||||
_metadata = _litellm_params.get("metadata", {}) or {}
|
# [Non-blocking Extra Debug Information in metadata]
|
||||||
_metadata["raw_request"] = curl_command
|
_litellm_params = self.model_call_details.get("litellm_params", {})
|
||||||
|
_metadata = _litellm_params.get("metadata", {}) or {}
|
||||||
|
_metadata["raw_request"] = str(curl_command)
|
||||||
|
except:
|
||||||
|
pass
|
||||||
|
|
||||||
if self.logger_fn and callable(self.logger_fn):
|
if self.logger_fn and callable(self.logger_fn):
|
||||||
try:
|
try:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue