|
|
--- |
|
|
title: PaperMate |
|
|
emoji: π |
|
|
colorFrom: blue |
|
|
colorTo: purple |
|
|
sdk: gradio |
|
|
sdk_version: 5.49.1 |
|
|
app_file: app.py |
|
|
pinned: false |
|
|
license: mit |
|
|
--- |
|
|
|
|
|
# PaperMate - Your Personal Assistant for Exploring arXiv Papers |
|
|
|
|
|
PaperMate helps you explore and understand research papers from arXiv using RAG (Retrieval-Augmented Generation) and advanced reranking. |
|
|
|
|
|
## Features |
|
|
|
|
|
- π Semantic search across arXiv papers |
|
|
- π§ LLM-powered question answering |
|
|
- π Advanced reranking for better results |
|
|
- π¬ Interactive Gradio interface |
|
|
|
|
|
## How to Use |
|
|
|
|
|
1. Enter your question about research papers in the text box |
|
|
2. Click "Ask" to get an answer based on the arXiv knowledge base |
|
|
3. The system will retrieve relevant papers, rerank them, and generate a comprehensive answer |
|
|
|
|
|
## Example Questions |
|
|
|
|
|
- "What is the NEMO paper all about?" |
|
|
- "Do you know something about Indian system to help Indians better understand each other?" |
|
|
- "What are the latest developments in transformer architectures?" |
|
|
|
|
|
## Configuration |
|
|
|
|
|
This Space uses the Hugging Face Inference API. You'll need to set the following secret: |
|
|
|
|
|
- `HUGGINGFACE_TOKEN`: Your Hugging Face API token (get one at https://huggingface.co/settings/tokens) |
|
|
|
|
|
The default model is `mistralai/Mistral-7B-Instruct-v0.2`, but you can change it in the settings. |
|
|
|
|
|
## Local Development |
|
|
|
|
|
1. Clone the repository |
|
|
2. Install dependencies: `pip install -r requirements.txt` |
|
|
3. Download the vector store from [here](https://drive.google.com/uc?export=download&id=1LhkfxMzpbhNNz0OLPt31nb8NYR0lekGB) |
|
|
4. Place the `vector_store` directory in the root |
|
|
5. Set your `HUGGINGFACE_TOKEN` environment variable |
|
|
6. Run: `python app.py` |
|
|
|
|
|
## Tech Stack |
|
|
|
|
|
- **Framework**: LangChain |
|
|
- **UI**: Gradio |
|
|
- **Vector Store**: FAISS |
|
|
- **Embeddings**: Sentence Transformers |
|
|
- **LLM**: Hugging Face Inference API |
|
|
- **Reranking**: Custom reranker with BM25 |
|
|
|
|
|
## License |
|
|
|
|
|
MIT |
|
|
|