We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d33c751 commit fd6eee0Copy full SHA for fd6eee0
edenai_apis/llmengine/clients/litellm_client/litellm_client.py
@@ -864,7 +864,11 @@ async def acompletion(
864
kwargs.pop("moderate_content", None)
865
# Register custom model pricing in litellm's registry for extended pricing support
866
if model_pricing:
867
- litellm.model_cost[model_name] = model_pricing
+ # Merge with existing pricing to preserve other fields (max_tokens, mode, etc.)
868
+ if model_name in litellm.model_cost:
869
+ litellm.model_cost[model_name].update(model_pricing)
870
+ else:
871
+ litellm.model_cost[model_name] = model_pricing
872
provider_start_time = time.time_ns()
873
c_response = await acompletion(**call_params, **kwargs)
874
provider_end_time = time.time_ns()
0 commit comments