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: forward extra_headers to HuggingFace embedding calls (#23525)

RoomWithOutRoofa0a951b34fd0
diff --git a/litellm/main.py b/litellm/main.py
index 722b4a7aaec..5a1b7f0fe16 100644
--- a/litellm/main.py
+++ b/litellm/main.py
@@ -5122,6 +5122,7 @@ def embedding( # noqa: PLR0915
client=client,
aembedding=aembedding,
litellm_params=litellm_params_dict,
+ headers=headers,
)
elif custom_llm_provider == "bedrock":
if isinstance(input, str):