This application uses RAG (Retrieval-Augmented Generation) to generate multiple-choice questions and short answer questions from PDF documents. It leverages LangChain, FAISS, Azure OpenAI, and Streamlit to create an interactive question generation system.
- Upload PDF documents
- Extract and process content using LangChain
- Store document chunks in FAISS vector store
- Generate 5 MCQs with options and answers
- Generate 5 Short Answer Questions
- Interactive Streamlit interface
- Create a
.envfile in the project root with your Azure OpenAI credentials:
AZURE_OPENAI_ENDPOINT=your_endpoint
AZURE_OPENAI_API_VERSION=your_api_version
AZURE_OPENAI_API_KEY=your_api_key
AZURE_OPENAI_DEPLOYMENT_NAME=your_deployment_name
- Install the required dependencies:
pip install -r requirements.txt- Run the Streamlit application:
streamlit run APP.py- Open the application in your web browser
- Upload a PDF document using the file uploader
- Wait for the processing to complete
- View the generated MCQs and Short Answer Questions
- Python 3.8+
- Azure OpenAI API access
- Internet connection for API calls