langchain.agents.loading
.load_agent¶
- langchain.agents.loading.load_agent(path: Union[str, Path], **kwargs: Any) Union[BaseSingleActionAgent, BaseMultiActionAgent] [source]¶
Deprecated since version 0.1.0.
Unified method for loading an agent from LangChainHub or local fs.
- Parameters
path (Union[str, Path]) – Path to the agent file.
kwargs (Any) – Additional keyword arguments passed to the agent executor.
- Returns
An agent executor.
- Raises
RuntimeError – If loading from the deprecated github-based Hub is attempted.
- Return type