From 5e4da6566403900c4d3ed540b23fd0ff237b8eae Mon Sep 17 00:00:00 2001 From: Ishaan Jaffer Date: Fri, 31 Oct 2025 20:32:44 -0700 Subject: [PATCH] fail ai test fix --- litellm/litellm_core_utils/llm_cost_calc/utils.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/litellm/litellm_core_utils/llm_cost_calc/utils.py b/litellm/litellm_core_utils/llm_cost_calc/utils.py index 2fd0b44962..d9dbc703d3 100644 --- a/litellm/litellm_core_utils/llm_cost_calc/utils.py +++ b/litellm/litellm_core_utils/llm_cost_calc/utils.py @@ -11,8 +11,8 @@ from litellm.types.utils import ( ImageResponse, ModelInfo, PassthroughCallTypes, - Usage, ServiceTier, + Usage, ) from litellm.utils import get_model_info @@ -716,6 +716,15 @@ class CostCalculatorUtils: model=model, image_response=completion_response, ) + elif custom_llm_provider == litellm.LlmProviders.FAL_AI.value: + from litellm.llms.fal_ai.cost_calculator import ( + cost_calculator as fal_ai_image_cost_calculator, + ) + + return fal_ai_image_cost_calculator( + model=model, + image_response=completion_response, + ) else: return default_image_cost_calculator( model=model,