PDF Chat is a Python Web app that enables users to upload one or more PDF files and to ask questions, which will be answered by Google's Gemini AI from the content of PDF files.
- PDF Upload: Users can upload one or many PDF files.
- Question Answering: Users can ask questions related to the content of the PDF files.
- Gemini AI Integration: PDF Chat uses Google's Gemini AI to provide accurate answers based on the uploaded PDF content.
- Optimised Text Processing: It can also handle PDF files with large amount of content.
To run PDF Chat Website locally:
- Clone this repository to your computer.
git clone https://github.com/Venkat-737/PDF-Chat.git
- Install the required dependencies from requirements.txt:
pip install -r requirements.txt
- Obtain a Google Gemini API Key from ai.google.dev and set it in a .env file as GOOGLE_API_KEY="Your_API_Key_Here".
- Run the app using:
streamlit run chatpdf1.py
- After running app, a web interface will be launched.
- Upload one or more PDF files and click on the "Submit & Process" button.
- Enter your question in the given text input field.
- Press "Enter" to get the answer from Gemini AI.
-
streamlit - Python library used to build interactive web applications.
-
google-generativeai - Integration with Google's Generative AI to answer questions.
-
PyPDF2 - Python library for reading PDF files.
-
python-dotenv - Python library to manage environment variables.
-
langchain - Library for natural language processing tasks.
-
langchain_google_genai - Integration with Google's Generative AI for advanced language processing tasks.
-
faiss-cpu - CPU version of FAISS for similarity search tasks.
Used for accessing Google's Generative AI to answer questions based on PDF content.