Skip to main content

BitsyGrader

BitsyGrader is an autograding service designed for educational environments. It integrates with JupyterHub and Learning Management Systems through LTI 1.3, providing automated grading capabilities for Jupyter notebooks with support for custom test cases and modular execution environments. It's inspired of nbgrader which is great but lacks support of LMS synchronization and isolated execution environments for the autograding.

Documentation

Installation Instructions

Overview

BitsyGrader consists of two main components:

  • Backend Service: A Tornado application that provides RESTful APIs for managing courses, assignments, and submissions with automated grading capabilities
  • JupyterLab Extension: A TypeScript/React frontend that extends JupyterLab with an interface for instructors and students

The system supports LTI 1.3 integration with platforms like Moodle, allowing grade synchronization and user provisioning through LTI Advantage services (Assignment and Grade Services, Names and Role Provisioning Service).

Showcase

Courses

Courses

Assignments

Assignments

Create Assignment (Step 1)

Create assignment step 1

Create Assignment (Step 2)

Create assignment step 2

Create Assignment (Step 3)

Create assignment step 3

Graded Submission

Graded submission

Key Features

Assignment Management

  • Create and manage programming assignments with multiple notebook files
  • Configure automated tests and grading criteria
  • Set due dates, late submission policies, and point allocations
  • Allow students to fetch solutions for an assignment with conditions.

Automated Grading

  • Execute student submissions in isolated environments
  • Run automated test suites with timeout and resource limits
  • Aggregate scores across multiple notebooks and test cases

LTI 1.3 Integration

  • Secure authentication via LTI launch from LMS platforms
  • Automatic course and user synchronization through NRPS
  • Grade passback to LMS via Assignment and Grade Service (AGS)
  • Support for deep linking and resource selection

Installation

Prerequisites

  • Python 3.11 or higher
  • Node.js 18 or higher
  • Database (SQLite, PostgreSQL, etc.)
  • JupyterHub

Setup

  1. Install the package
uv sync
uv pip install -e .
  1. Set up BitsyGrader configuration Please see example/bitsygrader_config.py for an example configuration.

  2. Add the service to JupyterHub (managed or external)

c.JupyterHub.services = [
    {
        "name": "bitsygrader",
        "api_token": "1442555d6d82d96fc8a69776f19978e442873859c6a003f7be15e61d669e2e1c", # generate via `openssl rand -hex 32`
        "url": "http://127.0.0.1:10101",
    }
]
  1. Start the service
export JUPYTERHUB_SERVICE_PREFIX="/services/bitsygrader/"
export JUPYTERHUB_API_TOKEN="1442555d6d82d96fc8a69776f19978e442873859c6a003f7be15e61d669e2e1c"
export JUPYTERHUB_API_URL="http://127.0.0.1:8000/hub/api"
export JUPYTERHUB_SERVICE_NAME="bitsygrader"
export JUPYTERHUB_SERVICE_URL="http://0.0.0.0:10101"
export BITSYGRADER_LOG_LEVEL="DEBUG"
bitsygrader serve --config bitsygrader_config.py

Docker Deployment

WIP, currently broken.

Usage

For Instructors

  1. Create a Course: Navigate to the Courses panel in JupyterLab
  2. Create Assignment Notebooks:: Notebooks must be created via the nbgrader extension. BitsyGrader is compatible with nbgrader's notebooks format.
  3. Create an Assignment: Use the assignment wizard to configure:
    • Notebook and asset files to include
    • Due dates and late policies
    • Solution policies
  4. Distribute to Students: Assignment notebooks are automatically preprocessed and distributed
  5. Review Submissions: View automated grades and provide manual feedback

For Students

  1. Access Assignments: Launch JupyterLab via LTI from your LMS
  2. Fetch Assignment: Open the assignment and get the starter notebook
  3. Complete Work: Write code in designated solution cells
  4. Submit: Click submit to send for automated grading
  5. View Results: See test results after autograding

Development

Building the Extension

jlpm build

Documentation

The documentation site uses MkDocs Material and is published to GitHub Pages.

uv pip install -r docs/requirements.txt
uv run mkdocs serve

Validate documentation changes before pushing:

uv run mkdocs build --strict

The source is in docs/ and the site configuration is in mkdocs.yml.

Project Structure

bitsygrader/
├── bitsygrader/              # Python backend
│   ├── autograde/          # Grading queue and workers
│   ├── cli/                # Command-line interface
│   ├── config/             # Configuration system
│   ├── core/               # Core models, auth, database
│   ├── extensions/         # JupyterLab server extension
│   ├── handlers/           # Tornado request handlers
│   ├── preprocessors/      # Notebook preprocessors
│   ├── repositories/       # Data access layer
│   ├── schemas/            # Pydantic request/response schemas
│   ├── services/           # Business logic
│   └── tasks/              # Background tasks
├── src/                    # TypeScript frontend
│   ├── components/         # React components
│   ├── hooks/              # Custom React hooks
│   ├── services/           # API client
│   ├── stores/             # State management
│   └── widgets/            # JupyterLab widgets
├── docker/                 # Docker configurations
├── tests/                  # Test suite (TBD)
└── docs/                   # MkDocs documentation

License

This project is licensed under the BSD 3-Clause License. See the LICENSE file for details.

Acknowledgments

Developed as part of the BYTE Challenge initiative to enhance computer science education for students.

BitsyGrader builds upon the work of the nbgrader project. The core project architecture, notebook format, preprocessor patterns, and notebook manipulation strategies were inspired by nbgrader's approach. I am grateful to the nbgrader team for providing their software as open source. Without them this project would have never existed.

Metadata

Release files for bitsygrader 0.0.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for bitsygrader 0.0.3
File Size Uploaded Provenance Actions
bitsygrader-0.0.3.tar.gz 3.9 MB With provenance Details for bitsygrader-0.0.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for bitsygrader 0.0.3
File Interpreter ABI Platform Actions
bitsygrader-0.0.3-py3-none-any.whl Python 3 none any Details for bitsygrader-0.0.3-py3-none-any.whl

Total release size: 11.3 MB

Release files / bitsygrader-0.0.3.tar.gz

Download URL bitsygrader-0.0.3.tar.gz
Size 3.9 MB
Tags Source
SHA-256 checksum
How to use checksums
cbeb94775e1afb7fef629f6e021b6fd17343357f8b1c2d8ad5e3ff5583f87098
BLAKE2b-256 checksum
How to use checksums
749d902dece26223c874d04f57c3f597caee2bc9df1ee8a29eb97e0c8e39887e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 10, 2026.

Transparency log

Release files / bitsygrader-0.0.3-py3-none-any.whl

Download URL bitsygrader-0.0.3-py3-none-any.whl
Size 7.4 MB
Tags Python 3
SHA-256 checksum
How to use checksums
07d165864f5caf21f7ed8f15580609ad76eb243c08189a2a838cfbb8090d5906
BLAKE2b-256 checksum
How to use checksums
5438406b7b752f1b6b145ecfa76ff752476f280a38f42206904da57fc707e485
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 10, 2026.

Transparency log

Security for bitsygrader 0.0.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for bitsygrader-0.0.3.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 10, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.0.3 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page