For this to work, the GitbookLoader needs to be initialized with the root path (https://docs.gitbook.com in this example) and have shouldLoadAllPaths set to true.
Copy
Ask AI
import { GitbookLoader } from "@langchain/community/document_loaders/web/gitbook";const loader = new GitbookLoader("https://docs.gitbook.com", { shouldLoadAllPaths: true,});const docs = await loader.load();
Assistant
Responses are generated using AI and may contain mistakes.