Skip to content

ecubeproject/GENAI_P3_QUIZ_GENERATOR

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 

Repository files navigation

GENAI_P3_QUIZ_GENERATOR

Project Type: Django-based Quiz Generator (Generative AI)


Project Overview

GENAI_P3_QUIZ_GENERATOR is a web application built on Django that generates custom quizzes (MCQs) from user-provided text input. Using the OpenAI GPT-3.5 Turbo API, it creates questions and answers on-the-fly and stores the results in both the database and downloadable text files.

Features:

  • Quiz generation on any user-provided topic
  • Results saved both in Django database and as .txt files
  • Clean web interface using HTML, CSS, Django templating
  • Built on Django—robust backend framework trusted by apps like Instagram and Pinterest

Demo Video

See the app in action via this YouTube demo:

Watch the demo


Folder Structure

.
├── manage.py
├── quiz_generator/
│   ├── __init__.py
│   ├── admin.py
│   ├── apps.py
│   ├── models.py        # Quiz/Question models
│   ├── views.py         # Handles quiz generation & saving
│   ├── templates/
│   │   ├── quiz_form.html
│   │   └── quiz_results.html
│   ├── static/          # CSS & JS assets
│   └── urls.py
├── project_name/        # Django project settings
│   ├── settings.py
│   ├── urls.py
│   └── wsgi.py
├── requirements.txt
└── README.md            # This file

Setup & Usage

  1. Clone the repository

    git clone <repo-url>
    cd GENAI_P3_QUIZ_GENERATOR
  2. Create & activate a virtual environment

    python3 -m venv venv
    source venv/bin/activate
  3. Install dependencies

    pip install -r requirements.txt
  4. Set your OpenAI API key (via environment or settings.py)

    python manage.py migrate  
  5. Set your OpenAI API key (via environment or settings.py)

  6. Apply database migrations

python manage.py migrate
  1. Run the development server
python manage.py runserver
  1. Access the app at http://127.0.0.1:8000/ and submit topic text to generate quizzes.

How It Works

  1. You input a topic or paragraph.
  2. The backend sends this to GPT-3.5 Turbo via OpenAI API.
  3. The AI returns MCQs with correct answers.
  4. Results display on the web and are saved to both the database and a .txt file for download.

Future Enhancements

  1. Quiz Customization: Specify number of questions, choose between MCQ and true/false formats
  2. User Management & History: Enable login, quiz history access, and personalized dashboards
  3. Admin Analytics: Track export stats, quiz frequency, and popular topics
  4. Export Features: Add PDF/CSV download support
  5. UI Improvement: Responsive design and richer front-end interactivity

Notes & Disclaimer

  1. Requires a valid OpenAI API key
  2. Optimized for educational and demonstration purposes
  3. Do not hard-code API keys—use secure environment variables

Developer: [Tejas Desai]

LinkedIn: [https://www.linkedin.com/in/tejasddesaiindia/]


License: Released under the MIT License

About

this is a quiz generator project using the django framework , html, css and open AI API key in the back ground

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors