The agent engineering platform.
Python agentsaiai-agentsanthropicchatgptdeepagentsenterpriseframeworkgeminigenerative-ailangchainlanggraphllmmultiagentopen-sourceopenaipydanticpythonragtypescript
Remove pydantic restricted namespaces from HuggingFaceInferenceAPIEmbedings (#26744)
Gabriel Altaybb40a0fb32b4
diff --git a/libs/community/langchain_community/embeddings/huggingface.py b/libs/community/langchain_community/embeddings/huggingface.pyindex 817a817299..cc2e073160 100644--- a/libs/community/langchain_community/embeddings/huggingface.py+++ b/libs/community/langchain_community/embeddings/huggingface.py@@ -396,6 +396,8 @@ class HuggingFaceInferenceAPIEmbeddings(BaseModel, Embeddings):additional_headers: Dict[str, str] = {}"""Pass additional headers to the requests library if needed."""+ model_config = ConfigDict(extra="forbid", protected_namespaces=())+@propertydef _api_url(self) -> str:return self.api_url or self._default_api_url