This is the complete documentation for the repository: Document-Question-and-Answer
Document-Question-and-Answer/
├── .devcontainer/ # Development container settings
├── .github/ # GitHub workflows and configurations
├── .gitignore # Git ignored files
├── LICENSE # Apache License 2.0
├── README.md # Project overview
├── requirements.txt # Python dependencies
└── streamlit_app.py # Main Streamlit app
- 📄 Document Upload: Upload PDF documents for question answering.
- 💬 Interactive Q&A: Ask questions about the uploaded document and get relevant responses.
- ♾️ Unlimited Conversations: Continue asking follow-up questions with context retention.
- 🤖 GPT-3.5 Integration: Uses OpenAI GPT-3.5 for natural language understanding.
- 🖥️ Streamlit Frontend: Clean, web-based user interface for interaction.
- Python 3.7+
- OpenAI API Key
- Clone the repository
git clone https://github.com/vchaitanyachowdari/Document-Question-and-Answer.git
cd Document-Question-and-Answer
- Install dependencies
pip install -r requirements.txt
- Set environment variable for OpenAI API key
export OPENAI_API_KEY="your-api-key-here"
- Run the Streamlit app
streamlit run streamlit_app.py
Open your browser and navigate to: http://localhost:8501
- Upload your document using the provided upload button.
- Ask any question related to the document in the input field.
- Receive AI-generated answers that are contextually aligned with the document.
- Continue conversation by asking follow-up questions.
streamlit_app.py
: Core application logic. Handles UI, file parsing, and model integration.requirements.txt
: Contains all necessary Python packages..devcontainer/
: Config files for containerized development..github/
: Placeholder for GitHub Actions or other workflows.
Licensed under the Apache License, Version 2.0. See LICENSE for full terms.
- Keep your API key secure and never commit it to the repository.
- Currently designed for PDF format. Other formats can be added with small adjustments.
- Easily extendable for chatbot features, support for other models (e.g., Claude, Gemini), or multi-doc support.
Contributions are welcome. Please open an issue or submit a PR with enhancements.
Author: V Chaitanya Chowdari
Repository: https://github.com/vchaitanyachowdari/Document-Question-and-Answer