An educational-standards-driven autograding tool that transforms assignment grading into an engaging learning experience.
Features • Write an assignment • Quick Start • Architecture • API • GitHub Action • Docs • Community
Important
The Autograder is in active development. New features are being added continuously, and we welcome contributions from the community. We would love to hear your suggestions or feature requests! Don't hesitate on opening an issue on GitHub.
The Autograder grades student submissions against a rubric the teacher writes once, a versioned grading definition, and explains every grade in a report written for the student. It runs as an HTTP service that grades many submissions, or as a GitHub Action that grades the repository it runs in.
- Tree-structured rubrics: required criteria, extra credit and penalties, grouped into weighted subjects at any depth (how scores work).
- Programs and web pages: run command-line programs in Python, Java, JavaScript (Node.js), C and C++ against expected output; check HTML, CSS and JavaScript files; forbid imports or language constructs.
- Multi-language assignments: one definition accepts several languages, each with its own files and build steps.
- Validation before students see it: a definition is checked completely when you validate or publish it, with the exact place of every mistake.
- Configurations with revisions: the HTTP service stores each assignment's definition and binds every submission to the exact revision it was graded with.
- A report that explains the score: every criterion, its points and the reason it failed, ordered by what cost the most, with linked learning resources.
- English and Brazilian Portuguese reports and messages.
- Clear failures: a missing file or a compilation error is explained, never turned into a silent zero.
- Progress between attempts: the HTTP service compares two graded submissions criterion by criterion.
- REST API with durable, restart-safe acceptance of submissions.
- GitHub Action that grades one checkout and keeps a canonical outcome artifact.
- Isolated execution: student code runs in a disposable sandbox per grading, with no network, bounded memory and processes, and confirmed cleanup.
- Extensible evaluators: add one with its implementation, parameter contract and registration (recipe).
The tutorial builds three assignments, each with a good and a bad submission that the test suite grades in real sandboxes. A definition is one JSON document:
{
"schema_version": "2.0",
"languages": ["python"],
"criteria": {
"base": {
"tests": [
{
"id": "sum",
"type": "expect_output",
"name": "Adds two numbers",
"parameters": {"program_command": "python3 main.py", "inputs": ["2", "3"], "expected_output": "5"}
}
]
}
},
"preparation": {"languages": {"python": {"required_files": ["main.py"]}}},
"feedback": {"enabled": true}
}Every check a criterion type can name, with its parameters, is in the
generated evaluator reference. Trusted Python
code can add its own evaluators (recipe);
definitions sent over HTTP or used by the Action use the built-in ones.
The browser demo creates configurations, submits example programs and shows the results of a running API:
make start-autograder # the API, see Quick Start
make examples-demoOpen http://localhost:8080/demo/ and enter the API's address and its
integration token (AUTOGRADER_INTEGRATION_TOKEN) on the first page.
Setup lives in one place, the Development Guide. In short, with uv (it provides Python 3.13, the only supported version) and GNU Make:
git clone https://github.com/webtech-network/autograder.git
cd autograder
make install # .venv from the committed uv.lock
make verify # hermetic core/library check: no Docker, no databaseCI runs the same commands, plus the Docker and PostgreSQL tiers
(make test-integration, make test-e2e, make test-http, make test-postgres); make help
lists them all.
To run the system:
- Sandbox images: the runtime images named in
sandbox_config.yml(make sandbox-list) must be present before a host starts:docker pullthe published references, ormake sandbox-build-allto build them from this checkout. - Web API: export
SANDBOX_API_TOKENandAUTOGRADER_INTEGRATION_TOKEN(long random secrets), thenmake start-autograder, a development-only stack (Docker and Docker Compose; the host-wide sandbox budgetgeneral.max_sandboxesand the runtimes are configured insandbox_config.yml; size the budget by CPU, about 8 on 12 CPUs, see JOBS.md). See Run your first grading workflow; deployments follow Deploying the HTTP service. - GitHub Action: see the GitHub Action section.
The core (autograder/) owns grading semantics: the versioned definition, the
evaluator contract, assessment, scoring and feedback. Hosts (web/,
github_action/) collect files, authenticate, persist and publish. They pass
execution, fixture and AI providers to the core as HostCapabilities, composed in
execution_host/ on top of sandbox_manager/. The core imports none of them, and
a test enforces it. The full map is
Responsibilities and Dependencies.
from autograder import compile_definition, evaluate_submission
# One versioned grading definition, compiled before execution.
compiled = compile_definition(definition_json)
outcome = evaluate_submission(submission, definition=compiled).model_dump(mode="json")Integrators start with the definition and terminal outcome contracts.
The Autograder provides a FastAPI-based REST API for integration with learning management systems.
📚 Complete API Documentation →
Includes endpoints for:
- Creating grading configurations
- Submitting assignments for grading
- Retrieving results
The Autograder GitHub Action grades one ordinary checkout and writes a versioned outcome artifact and workflow summary. Cloud publication is optional and happens after grading completes. Repository write permissions are unnecessary.
jobs:
assess:
permissions:
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: webtech-network/autograder@main
with:
definition-path: .github/autograder/definition.json
- uses: actions/upload-artifact@v4
if: always()
with:
name: grading-outcome
path: .autograder/- Module overview and internals: docs/github_action/README.md
- Configuration reference and troubleshooting: docs/github_action/configuration.md
- Reference implementation: webtech-network/demo-autograder
- How to adapt the demo to your course: docs/github_action/quick-start.md
Full documentation is available at GitHub Pages, organized by task: author an assignment, integrate, extend, operate.
Releases follow Semantic Versioning, from 1.0.0.
Versions and stability states which surfaces a
version promises and how breaking changes and deprecations are handled,
CHANGELOG.md lists each release's changes, and
upgrading to 1.0.0 covers earlier
tags and deployments. Pin a release in uses:
(webtech-network/autograder@<version>) for reproducible grading; @main
follows the newest verified commit of main.
Capacity depends on hardware, configuration and assignments, so the project publishes measurements rather than typical numbers. Run the capacity benchmark against your own stack; JOBS.md holds the reference result with its hardware and workload.
We are committed to building a welcoming and inclusive community.
- Code of Conduct: CODE_OF_CONDUCT.md
- Contributing Guide: CONTRIBUTING.md
- Security Policy: SECURITY.md
- Support: SUPPORT.md
- Issue Templates:
.github/ISSUE_TEMPLATE - PR Template:
.github/pull_request_template.md
For questions, suggestions, or support:
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Email: [email protected]
Star this repo if you find it useful!
Made by educators, for educators