https://github.com/cma-png/verbose-adventure
Research-Paper-Q&A-Tool
https://github.com/cma-png/verbose-adventure
fastapi llamaindex-rag ollama pinecone streamlit
Last synced: 4 months ago
JSON representation
Research-Paper-Q&A-Tool
- Host: GitHub
- URL: https://github.com/cma-png/verbose-adventure
- Owner: Cma-png
- Created: 2024-08-28T03:46:04.000Z (10 months ago)
- Default Branch: main
- Last Pushed: 2024-08-30T14:30:02.000Z (10 months ago)
- Last Synced: 2024-10-10T09:21:37.722Z (8 months ago)
- Topics: fastapi, llamaindex-rag, ollama, pinecone, streamlit
- Language: Python
- Homepage:
- Size: 31.3 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Research Paper Q&A Tool
A powerful tool for document search and analysis using advanced language models. Upload PDFs, convert them to vectors, and query your documents with ease.
https://github.com/user-attachments/assets/1161b9f2-7f42-4cc5-b15e-da7f1f6401c3
## Features
- **PDF Upload and Vectorization**: Upload PDFs and convert them into vectors using Pinecone.
- **Advanced Querying**: Leverage the Ollama model for intelligent document querying.
- **User-Friendly Interface**: Built with Streamlit for a seamless user experience.
![]()
![]()
## Quick Start
### Prerequisites
- Python 3.10
- Docker
- Pinecone API Key
- Ollama Model (pre-configured in the application)### Setup
#### 1. Create a Pinecone Account and API Key
1. Sign up for a Pinecone account at [Pinecone](https://www.pinecone.io/).
2. Create an index and generate your API key.
3. Save your API key and index name, as you'll need them to run the application.#### 2. Configure the Models in the Code
1. Open `backend/core/embedding_service.py`.
2. Find the section where the models are defined:```python
# Example configuration
LLM_MODEL_NAME = "your_llm_model_name"
EMBEDDING_MODEL_NAME = "your_embedding_model_name"
```
3. Replace "your_llm_model_name" and "your_embedding_model_name" with the actual names of the models you downloaded.### 4. Build and Run
#### 4.1. With Docker1. Ensure Docker is installed on your system.
2. From the project root, run:
```bash
docker-compose up --build
```
3. Access the app at `http://localhost:8501`.#### 4.2. Without Docker
1. Install dependencies:
```bash
pip install -r backend/requirements.txt
```
2. Start the FastAPI server:
```bash
python backend/scripts/main.py
```
3. In a new terminal, start the Streamlit frontend:
```
streamlit run frontend/streamlit_ui.py
```
4. Open `http://localhost:8501` to use the app.### 5. Enter Pinecone API Key and Index to Use
After starting the Streamlit frontend, enter the Pinecone API key and index:### 6. Upload your document pdf
+ Push the buttom to convert your pdf to vector and store to the vectorDB
+ Now, you may start to ask the llm question about your pdf