Giter Site home page Giter Site logo

shreekeshavan / optimalquest_objective-questions-with-multiple-correct-answers Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 9.11 MB

📂OptimalQuest, an innovative project designed to convert text content from PDF files into engaging multiple-choice questions with multiple correct answers.🤔💭

Home Page: https://github.com/ShreeKeshavan/OptimalQuest_Objective-Questions-with-Multiple-Correct-Answers

Jupyter Notebook 67.30% Python 32.70%
artificial-intelligence natural-language-processing pypdf2 python random spacy

optimalquest_objective-questions-with-multiple-correct-answers's Introduction

OptimalQuest_Objective-Questions-with-Multiple-Correct-Answers (Creation of Objective Questions with Multiple Correct Answers)

Welcome to OptimalQuest, an innovative project designed to convert text content from PDF files into engaging multiple-choice questions with multiple correct answers.

Features

  • Extract text from PDFs.
  • Generates multiple-choice questions.
  • Each question can have multiple correct answers.
  • Utilizes machine learning and natural language processing for question generation.

Installation

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.

  1. Clone the repository: git clone https://github.com/ShreeKeshavan/OptimalQuest_Objective-Questions-with-Multiple-Correct-Answers.git
  2. Install required libraries: pip install spacy PyPDF2

Libraries Used

  • Spacy: For natural language processing tasks.
  • Random: To generate randomness for question generation.
  • PyPDF2: To read PDF files.
  • Warnings: To suppress warnings.

How to Use

  1. Load the English language model using Spacy.

    import spacy
    nlp_model = spacy.load("en_core_web_sm")
  2. Extracting Text from PDFs: The extract_text_from_pdfs function is used to extract text from one or more PDF documents and concatenate it into a single text string. This is done using the PdfReader object from the PyPDF2 library. Each page from each PDF is read and the text is extracted and appended to the output string.

    Here is an example of how to use this function:

    # Define the PDF documents to extract text from
    pdf_files = ['chapter-2.pdf', 'chapter-3.pdf', 'chapter-4.pdf']
    
    # Extract text
    extracted_text = extract_text_from_pdfs(pdf_files)
  3. Call the get_mca_questions function with the extracted text from the PDF and the number of questions as arguments. This will generate a list of multiple-choice questions.

    get_mca_questions(text_context, num_of_questions)

optimalquest_objective-questions-with-multiple-correct-answers's People

Contributors

shreekeshavan avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.