Class BaseLoader

java.lang.Object
com.hw.langchain.document.loaders.base.BaseLoader
Direct Known Subclasses:
DirectoryLoader, NotionDirectoryLoader, TextLoader, WebBaseLoader

public abstract class BaseLoader extends Object
Interface for loading documents.

Implementations should implement the lazy-loading method using generators to avoid loading all documents into memory at once.

Author:
HamaWhite
  • Constructor Details

    • BaseLoader

      public BaseLoader()
  • Method Details

    • load

      public abstract List<Document> load()
      Load data into document objects.
      Returns:
      a List which is materialized in memory.
    • errorMessage

      protected String errorMessage(String filePath)