This is a Streamlit application that allows you to upload PDF documents and ask questions about their content. The application uses a combination of sentence transformers for text embeddings and GPT4All (an open-source LLM) to provide answers based on the PDF content.
- Upload and process PDF documents
- Ask questions about the PDF content
- Get answers with source page references
- Uses local models (no API keys required)
- Efficient text search using FAISS
You need to download the LLM model file and place it in the models
folder:
- Install the required dependencies:
pip install -r requirements.txt
- Run the Streamlit application:
streamlit run app.py
- Open the application in your web browser (usually at http://localhost:8501)
- Upload a PDF file using the file uploader
- Click "Process PDF" to analyze the document
- Enter your question in the text input field
- Click "Get Answer" to receive a response
- Uses Sentence Transformers for text embeddings
- FAISS for efficient similarity search
- GPT4All for local LLM inference
- PyPDF2 for PDF text extraction
The first time you run the application, it will download the required models which might take a few minutes depending on your internet connection.