Skip to content

The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]

fix: add call type aresponses

Yuta Saitobc02d462ff37
diff --git a/litellm/litellm_core_utils/litellm_logging.py b/litellm/litellm_core_utils/litellm_logging.py
index 45eceea9fb1..f8c932db4d3 100644
--- a/litellm/litellm_core_utils/litellm_logging.py
+++ b/litellm/litellm_core_utils/litellm_logging.py
@@ -1855,10 +1855,11 @@ class Logging(LiteLLMLoggingBaseClass):
)
litellm_params = self.model_call_details.get("litellm_params", {})
is_async_logging_request = (
- litellm_params.get("acompletion", False) is not True
- and litellm_params.get("aembedding", False) is not True
- and litellm_params.get("aimage_generation", False) is not True
- and litellm_params.get("atranscription", False) is not True
+ litellm_params.get(CallTypes.acompletion.value, False) is not True
+ and litellm_params.get(CallTypes.aresponses.value, False) is not True
+ and litellm_params.get(CallTypes.aembedding.value, False) is not True
+ and litellm_params.get(CallTypes.aimage_generation.value, False) is not True
+ and litellm_params.get(CallTypes.atranscription.value, False) is not True
)
try:
## BUILD COMPLETE STREAMED RESPONSE
@@ -2700,9 +2701,13 @@ class Logging(LiteLLMLoggingBaseClass):
return
litellm_params = self.model_call_details.get("litellm_params", {})
is_async_logging_request = (
- litellm_params.get("acompletion", False) is not True
- and litellm_params.get("aembedding", False) is not True
+ litellm_params.get(CallTypes.acompletion.value, False) is not True
+ and litellm_params.get(CallTypes.aresponses.value, False) is not True
+ and litellm_params.get(CallTypes.aembedding.value, False) is not True
+ and litellm_params.get(CallTypes.aimage_generation.value, False) is not True
+ and litellm_params.get(CallTypes.atranscription.value, False) is not True
)
+
try:
start_time, end_time = self._failure_handler_helper_fn(
exception=exception,