Skip to main content

Terminal-based test reviewer generator on formatted notes

Project description

Reviewer Generator

A small package to help you review for tests and exams based on your notes! It is a terminal-based question-and-answer reviewer.

How It Works

Reviewer Generator will read your notes formatted specifically for it. It currently supports JSON files for two (2) types of notes: (1) definitions and (2) enumerations.

Below is a sample note structure that Reviewer Generator supports:

{
  "definitions": {
    "No one | None": [
      "Who owns the internet?"
    ],
    "Internet | The Internet": [
      "It is not owned by any individual or group.",
      "It is a worldwide collection of interconnected networks (internetwork or internet for short), cooperating with each other to exchange information using common standards."
    ],
    "Small Home | Small Home Networks | Small Home Network": [
      "Connect a few computers to each other and to the internet."
    ],
    "SOHO Network | SOHO | Small Office Home Office | Small Office Home Office Network | SOHO Networks | Small Office Home Office Networks": [
      "Allows computers in a home office or a remote office to connect to a corporate network.",
      "Allows computers in a home office or a remote office to connect to a corporate network, or access centralized, shared resources."
    ],
    "Medium to Large Networks | Medium to Large | Medium to Large Network": [
      "It can have many locations with hundreds or thousands of interconnected hosts."
    ],
    "World Wide Networks | World Wide | World Wide Network": [
      "The internet is a network of networks that connects hundreds of millions of computers world-wide."
    ],
    ...
  },
  "enums": {
    "Types of Networks": [
      "Small Home | Small Home Networks | Small Home Network",
      "SOHO Network | SOHO | Small Office Home Office | Small Office Home Office Network | SOHO Networks | Small Office Home Office Networks",
      "Medium to Large Networks | Medium to Large | Medium to Large Network",
      "World Wide Networks | World Wide | World Wide Network"
    ],
    "Examples of Mobile Devices": [
      "Smartphone | Smart phone | Smart phones | Smartphones",
      "Tablet | Tablets",
      "Smart watch | Smart watch | Smart watches | Smartwatches",
      "Smart glass | Smart glasses | Smartglass | Smartglasses"
    ],
    ...
  }
}

The note structure JSON consists of two (2) main keys: (1) definitions and (2) enums. Each key consist of similarly associated values - lists or arrays.

Under definitions, the keys contains pipe (|) characters as a delimiter. This delimiter serves as a separator for each acceptable answer for the array of definitions associated with it.

Under enums, the associated values contains pipe (|) characters as a deliimiter also for each acceptable answer.

Usage

Review Generator is fairly straight-forward to use in your project. Below is a sample use-case scenario:

# Import Reviewer Module
from ReviewerParser import ReviewParser

# Load JSON Notes
my_notes = ReviewParser.LoadNotesFromJson(r'./Notes.json')

# Extracting each note types
definitions = my_notes['definitions']
enums = my_notes['enums']

# Instantiation
reviewer = ReviewParser([definitions], [enums], sequence=['enums'])

# Start reviewing
reviewer.start()

When loading the JSON notes, the package has an optional helper method to load the notes for you. This can be alternatively achieved by loading the JSON file yourself via the following:

import json

notes_path = r'path/to/json/notes'
with open(notes_path) as file:
  notes_dict = json.load(file)

Reviewer Options

Reviewer Generator currently supports three (3) types of questions: (1) identification, (2) enumeration, and (3) multiple choice. By default, Reviewer Generator generates these questions at random if you do not explicitly supply a sequence.

When a sequence is supplied, Reviewer Generator will generate questions following the question-type sequence provided.

# Specify sequence upon instantiation
reviewer = ReviewParser([definitions], [enums], sequence=['enums', 'qa', 'choices'])

# Specificy sequence for a single session
reviewer.start(sequence=['enums', 'qa', 'choices'])

Note: The following sequence list will only recognize enums, qa, choices as valid values for the sequence

You can optionally disable all other question types and only generate specific question types.

# Specify question types upon instantiation
reviewer = ReviewParser([definitions], [enums], options={
  'identification': True,
  'multiple_choice': False,
})

# Specify question types for a single session
reviewer.start(options={
  'identification': True,
  'multiple_choice': False,
  'enumeration': True
})

Note: Omitting a question type will automatically give a False value.

Supported Question Types: identification, multiple_choice, and enumeration

Supported Types and Options

Supported Sequence Values (Used by sequence parameter)

  • enums
  • qa
  • choices

Supported Question Type Values (Used by options parameter)

  • identification
  • multiple_choice
  • enumeration

Bug Reports

There is currently no active repository for this package. For direct inquries, you can message this address: shnmyklsnc@gmail.com

Recommendations

Planned upon future releases of this package are:

  • Return a list of question-answer tuples instead of running a game loop to allow wide range of applications of the generated questions.

  • Additional question types and options to be added.

Collaborations are well accepted. Feedbacks and recommendations are also welcome. Email shnmyklsnc@gmail.com for those matter.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

reviewer-generator-0.0.2.tar.gz (9.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

reviewer_generator-0.0.2-py3-none-any.whl (7.5 kB view details)

Uploaded Python 3

File details

Details for the file reviewer-generator-0.0.2.tar.gz.

File metadata

  • Download URL: reviewer-generator-0.0.2.tar.gz
  • Upload date:
  • Size: 9.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.2

File hashes

Hashes for reviewer-generator-0.0.2.tar.gz
Algorithm Hash digest
SHA256 833f2a01c8304252deb68c6f2bb445d454a72d6226532704a7eb08b200bfad78
MD5 bf4904b754c3e22459da16919b522aeb
BLAKE2b-256 90d3be5517f7694c87167e0e095d36368a1127d30360c0a919d4e4210218fc6b

See more details on using hashes here.

File details

Details for the file reviewer_generator-0.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for reviewer_generator-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 8620054298ee9c92fa85d74c6800cb9ffc95a6117481d5f9064e0d2c1a699c96
MD5 229a7eaef5e85cb263a013ad4b5e8db8
BLAKE2b-256 9d2092bfb1cd3e51a24e72353e00a2a81b0f61688e8706cee787add58b61bf74

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page