Back to directory

PaperQA2

A high-accuracy retrieval-augmented-generation package for answering questions from scientific PDFs, text, Office documents and source code, with citations back to the source passages.

PaperQA2

PaperQA2 is a package for high-accuracy retrieval-augmented generation (RAG) over PDFs, text files, Microsoft Office documents and source-code files, with a focus on scientific literature. Given a folder of paper PDFs, it fetches their metadata, including citation counts with a retraction check, parses and caches them into a full-text search index, and answers a question with an LLM agent, citing the source passages it used.

It can be used from the command line or as a Python library, with either an agentic mode that adds and queries documents autonomously or a manual mode without an agent. It supports asynchronous operation, a choice of hosted or locally hosted models, a configurable embedding model including local sentence-transformer models, code and HTML as input, multimodal documents, and an external or vector database for the index and for caching, with settings for adjusting the number of sources used and customizing prompts.

It installs as a Python package and is released under the Apache-2.0 license.

More in RAG

See all 540
  • ai·rete·rag

    ai-rete-rag.com

    A platform that pairs a Rete rule engine with retrieval-augmented generation, so deterministic rules decide an outcome and grounded retrieval explains the decision in plain language.

  • Xtriever

    github.com

    A hybrid retrieval engine for retrieval-augmented generation, written in Rust to run on-device on a phone or a laptop, combining lexical BM25 search, dense embedding search, reciprocal-rank fusion and cross-encoder re-ranking with no server.

  • FileFlux

    github.com

    A .NET library that turns PDF, DOCX, HWP and other documents into optimized chunks for RAG systems, through a five-stage pipeline built on high-performance Rust FFI readers.