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 cohere / cohere_chat when timeout is None

Ishaan Jaffe734568b5a25
diff --git a/litellm/main.py b/litellm/main.py
index 1840a900a60..6200d8cb18a 100644
--- a/litellm/main.py
+++ b/litellm/main.py
@@ -3387,7 +3387,7 @@ def embedding(
client=client,
aembedding=aembedding,
)
- elif custom_llm_provider == "cohere":
+ elif custom_llm_provider == "cohere" or custom_llm_provider == "cohere_chat":
cohere_key = (
api_key
or litellm.cohere_key
@@ -3404,7 +3404,7 @@ def embedding(
logging_obj=logging,
model_response=EmbeddingResponse(),
aembedding=aembedding,
- timeout=float(timeout),
+ timeout=timeout,
client=client,
)
elif custom_llm_provider == "huggingface":