Modal Dojo
Modal Dojo is an open-source library to get started with production-grade LLM training on Modal.
To get started, you can go through the Quickstart section below, or paste the prompt below into your favorite agent:
Install the `modal-dojo` library. Then, install the skill bundle into the local project with `modal-dojo skills install`. Finally, tell the user that they can ask you to do something like: "Walk through tutorials/rl_basics.py and train Qwen3.5-4B to write 5-7-5 haikus from statworx/haiku."
Quickstart
Requirements:
- Python 3.12
Install the package directly:
uv pip install modal-dojo
Or pin it in pyproject.toml:
modal-dojo = { git = "https://github.com/modal-projects/modal-dojo.git", branch = "main" }
Set up Modal and the dashboard:
modal-dojo setup
And empower your agents with the Modal Dojo's skill bundle:
modal-dojo skills install
Then, it's as easy as:
import re
from modal_dojo import (
HuggingFaceDataset,
Qwen3_5_4B,
Qwen3_5_4B_Recipe,
TrainConfig,
)
model = Qwen3_5_4B()
async def gsm8k_rm(args, sample, **kwargs) -> float:
text = model.parse_response(sample.response or "").content
boxed = re.findall(r"\\boxed\{([^}]+)\}", text)
pred = boxed[-1] if boxed else (re.findall(r"-?[\d,]+(?:\.\d+)?", text) or [""])[-1]
try:
return float(float(pred.replace(",", "")) == float(sample.label))
except ValueError:
return 0.0
config = TrainConfig(
model=model,
dataset=HuggingFaceDataset(
hf_repo="skrishna/gsm8k_only_answer",
hf_split="train[:120]",
input_column="text",
output_column="label",
input_format="text",
),
recipe=Qwen3_5_4B_Recipe(
custom_rm_function=gsm8k_rm,
),
)
if __name__ == "__main__":
run = config.launch()
print(run.training_run_id)
For a step-by-step walkthrough, see the Getting started tutorial.
Supported models
| Family | Models |
|---|---|
| DeepSeek | |
| GLM | |
| Gemma | |
| Inkling | |
| Kimi | |
| Moonlight | |
| Qwen3 | |
| Qwen3.5 | |
| Qwen3.6 | |
| Qwen3.8 |
Metadata
Release files for modal-dojo 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| modal_dojo-0.1.0.tar.gz | 1.4 MB | With provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| modal_dojo-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 2.2 MB
Release files / modal_dojo-0.1.0.tar.gz
| Download URL | modal_dojo-0.1.0.tar.gz |
|---|---|
| Size | 1.4 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e61ad698a8c0b2e6215b86e7db3f386ff0e3f6fa0ffd5aaf9fa2b055a542c7e6
|
|
BLAKE2b-256 checksum How to use checksums |
51f835c40a39225da743a0ab9c27e65475794af2fe96c415c9d49b5368da0ee2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Oct 20, 2026.
Transparency logRelease files / modal_dojo-0.1.0-py3-none-any.whl
| Download URL | modal_dojo-0.1.0-py3-none-any.whl |
|---|---|
| Size | 736.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3f6539dc8e91410591648d782a27b2865c06cf2022c2b196395bb1afcf1f4135
|
|
BLAKE2b-256 checksum How to use checksums |
741b92d3f9ad5cfda5778845d002d0181f8701291418fe1f45432b7f738e3630
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Oct 20, 2026.
Transparency logSecurity for modal-dojo 0.1.0
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
All 2 files in this release have been uploaded with provenance metadata.
Attestation for modal_dojo-0.1.0.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 Oct 20, 2026.
Transparency logA 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.