DirectoryLoader document loaders. For detailed documentation of all DirectoryLoader features and configurations head to the API reference.
This example goes over how to load data from folders with multiple files. The second argument is a map of file extensions to loader factories. Each file will be passed to the matching loader, and the resulting documents will be concatenated together.
Example folder:
概述
集成详情
设置
要访问DirectoryLoader document loader,你需要install the langchain package.
安装
LangChain 的 DirectoryLoader 集成位于langchain 包中:
实例化
Now we can instantiate our model object and load documents:Load
API 参考
有关所有DirectoryLoader 功能和配置的详细文档,请前往 API 参考。
将这些文档连接到 Claude、VSCode 等工具,通过 MCP 获取实时答案。

