How mahnoorahmed-dev/research-paper-rag works
Research Paper RAG is a local Streamlit application for searching a user’s PDF collection, producing cited answers, critiquing methodology drafts, and checking claims against the indexed corpus. The principal workflow is PDF upload or selection, extraction and indexing, then question or claim retrieval, reranking, and evidence-grounded generation. Critique adds section-by-section analysis; novelty adds a corpus-scoped verdict. The README documents these capabilities, while some retrieval and UI wiring was only partially sampled, so uncertain internal links are omitted.
Main entry points: app.py Streamlit app · critique.py Methodology critique · chain.py Question answering · novelty.py Novelty assessment
Components 18
User interface
- Streamlit app
app.py
Corpus indexing
- Indexing orchestration
src/ingest.py - Page extraction
src/ingest.py - Section tagging
src/ingest.py - Text chunking
src/ingest.py - Local embeddings
src/ingest.py - Chroma index
chroma_db
Evidence analysis
- Question answering
src/chain.py - Single-paper retrieval
src/chain.py - Multi-paper retrieval
src/chain.py - Candidate reranking
src/chain.py - Methodology critique
src/critique.py - Draft sectioning
src/critique.py - Novelty assessment
src/novelty.py
Response generation
- Evidence formatting
src/chain.py - Groq language model
Other components
- Researcher
- Paper PDFs
data/pdfs
Connections 29
- Researcher → Streamlit app: uses
- Streamlit app → Paper PDFs: uploads PDFs
- Streamlit app → Indexing orchestration: adds PDFs
- Indexing orchestration → Page extraction: extracts pages
- Paper PDFs → Page extraction: provides PDFs
- Page extraction → Section tagging: tags sections
- Section tagging → Text chunking: segments text
- Text chunking → Local embeddings: embeds chunks
- Local embeddings → Chroma index: writes vectors
- Streamlit app → Question answering: asks question
- Streamlit app → Methodology critique: submits draft
- Streamlit app → Novelty assessment: submits claim
- Question answering → Single-paper retrieval: retrieves candidates
- Single-paper retrieval → Chroma index: searches vectors
- Single-paper retrieval → Candidate reranking: reranks candidates
- Methodology critique → Draft sectioning: splits draft
- Methodology critique → Multi-paper retrieval: retrieves per section
- Novelty assessment → Multi-paper retrieval: retrieves claim evidence
- Multi-paper retrieval → Chroma index: searches per paper
- Multi-paper retrieval → Candidate reranking: reranks candidates
- Question answering → Evidence formatting: formats evidence
- Methodology critique → Evidence formatting: formats evidence
- Novelty assessment → Evidence formatting: formats evidence
- Evidence formatting → Groq language model: supplies context
- Question answering → Groq language model: generates answer
- Methodology critique → Groq language model: generates critique
- Novelty assessment → Groq language model: generates assessment
- Groq language model → Streamlit app: returns results
- Chroma index → Streamlit app: lists indexed papers