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: broaden RAG ingestion config cleanup to cover AWS endpoint/identity fields

Yuneng Jiang30cb459d1c92
diff --git a/litellm/rag/ingestion/base_ingestion.py b/litellm/rag/ingestion/base_ingestion.py
index 1317c557d67..f66fc2a6c5e 100644
--- a/litellm/rag/ingestion/base_ingestion.py
+++ b/litellm/rag/ingestion/base_ingestion.py
@@ -73,7 +73,7 @@ class BaseRAGIngestion(ABC):
This allows users to specify a credential name in the vector_store config
which will be resolved from litellm.credential_list. When a stored
credential is used, its values take precedence over caller-supplied
- equivalents so the api_key / api_base pair stays consistent with the
+ equivalents so endpoint and identity fields stay consistent with the
credential definition.
"""
from litellm.litellm_core_utils.credential_accessor import CredentialAccessor
@@ -87,11 +87,16 @@ class BaseRAGIngestion(ABC):
return
for key, value in credential_values.items():
self.vector_store_config[key] = value
- if (
- "api_base" in self.vector_store_config
- and "api_base" not in credential_values
+ for key in (
+ "api_base",
+ "aws_sts_endpoint",
+ "aws_web_identity_token",
):
- del self.vector_store_config["api_base"]
+ if (
+ key in self.vector_store_config
+ and key not in credential_values
+ ):
+ del self.vector_store_config[key]
@property
def custom_llm_provider(self) -> str: