Manhattan University Knowledge Base

Importing Moodle Quizzes Using Moodle XML Format and Chat GPT

Updated on

You can streamline the Moodle quiz creation process using ChatGPT to convert your quiz document into a Moodle-friendly import format.

Create a Quiz Document

Start with a quiz in a document format such as a Word document or PDF.  The document should include the questions, answer choices, and correct answers.  Correct answers can be listed below each question or provided as an answer key at the bottom of the quiz or in a separate document.

Convert Quiz Format Using ChatGPT

In ChatGPT start a new chat.  Use the attachment function to upload the quiz document(s). Then, enter the following prompt:

Prompt: Convert the multiple choice questions in this quiz to Moodle XML format so that I can download the file and upload it into Moodle. The question ID number is 2 digits.  For example, 01, 02, 03, etc.

Chat GPT will analyze the document and then create an XML file for you to download.  Click on the download link to download the file to your computer.

On occasion, ChatGPT may provide you with code rather than a downloadable file.  If this happens, respond by asking again for a downloadable file.

Create a Moodle Quiz

Go to your Moodle course and create a new Moodle quiz.  If you already have an existing Moodle quiz, you can click on the quiz and skip to Step 3.

1. Click "Add an activity or resource" and select "Quiz"

2. Enter the quiz information, then scroll down and click "Save and display"

3. Click on the Question bank tab

Perform the Import

1. Click on the dropdown menu in the upper left corner of the screen and select Import

2. Select Moodle XML as the file format.

3. Choose the category the questions will be imported to

Click on the arrow to expand the General section.  Then for Import category, use the dropdown to select the name of the quiz you have created.

4. Upload the import file

Under Import questions from file, drag the XML file you downloaded from ChatGPT into the file upload area.  Then click Import.

If the import is successful, green notification messages will indicate that the questions were parsed and imported from the file.  Scroll down and click on Continue.

Add imported questions to quiz

Importing the questions has converted the questions to Moodle format and housed them in your question bank.  Next you must add them to the quiz.

1. Click on the Question tab

2. Choose the option to add questions

Click the Add link and select from question bank from the list of options.

3. Select the associated question category

To the right of Category, use the dropdown the select the category entitled "Default for" along with the name of the quiz.  Then click the Apply filters button.

4. Select questions to add

Click the checkbox at the top to select all questions within the quiz category.  Then click Add selected questions to the quiz to place the questions in the quiz.  You can also select questions individually if you only want to add a portion of the questions.

The questions have now been added to the quiz.  You can make adjustments to order, pagination, and other quiz settings as you normally would.

0 Comments

Add your comment

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Previous Article Importing Questions into a Moodle Quiz using VLE Tools
Next Article Creating Quizzes with Questions Randomly Selected from a Pool of Questions