diff --git a/lib/crewai/src/crewai/rag/chromadb/config.py b/lib/crewai/src/crewai/rag/chromadb/config.py index 54908c6b7..14b48c917 100644 --- a/lib/crewai/src/crewai/rag/chromadb/config.py +++ b/lib/crewai/src/crewai/rag/chromadb/config.py @@ -58,6 +58,7 @@ def _default_embedding_function() -> ChromaEmbeddingFunctionWrapper: OpenAIEmbeddingFunction( api_key=os.getenv("OPENAI_API_KEY"), model_name="text-embedding-3-small", + api_key_env_var="OPENAI_API_KEY", ), ) diff --git a/lib/crewai/src/crewai/utilities/agent_utils.py b/lib/crewai/src/crewai/utilities/agent_utils.py index b74724b9f..24b8f3303 100644 --- a/lib/crewai/src/crewai/utilities/agent_utils.py +++ b/lib/crewai/src/crewai/utilities/agent_utils.py @@ -398,7 +398,6 @@ def is_context_length_exceeded(exception: Exception) -> bool: return ( LLMContextLengthExceededError(str(exception)) ._is_context_limit_error(str(exception)) - ._is_context_limit_error(str(exception)) )