langchain.document_loaders.arxiv.ArxivLoader¶
- class langchain.document_loaders.arxiv.ArxivLoader(query: str, load_max_docs: Optional[int] = 100, load_all_available_meta: Optional[bool] = False)[source]¶
Bases:
BaseLoaderLoads a query result from arxiv.org into a list of Documents.
Each document represents one Document. The loader converts the original PDF format into the text.
Methods
__init__(query[, load_max_docs, ...])A lazy loader for Documents.
load()Load data into Document objects.
load_and_split([text_splitter])Load Documents and split into chunks.
Attributes
The query to be passed to the arxiv.org API.
The maximum number of documents to load.
Whether to load all available metadata.
- load_and_split(text_splitter: Optional[TextSplitter] = None) List[Document]¶
Load Documents and split into chunks. Chunks are returned as Documents.
- Parameters
text_splitter – TextSplitter instance to use for splitting documents. Defaults to RecursiveCharacterTextSplitter.
- Returns
List of Documents.
- load_all_available_meta¶
Whether to load all available metadata.
- load_max_docs¶
The maximum number of documents to load.
- query¶
The query to be passed to the arxiv.org API.