Conditional date generation given (DOW, MON, LEAP, DEC) conditions, with four research-backed generative models trained from scratch on a Google Colab GPU runtime.
- Click the Open In Colab badge above (or open
notebook.ipynbon Colab manually via File -> Open notebook -> GitHub tab). - Runtime -> Change runtime type -> GPU (T4).
- Run all cells. The first cell clones this public repo into
/content/dates-generator,!pip install -r requirements.txt, then the notebook trains all four models (~60-90 min total on T4), evaluates, runs the CFG ablation, and writes apredictions.txtfrom the example input.
conda env create -f environment.yml
conda activate dates-generator
cd model
python predict.py -i ../data/example_input.txt -o ../predictions.txt
Pick a different model with --model {cvae,acgan,maskgit,mdlm}. Default: cvae.
python model/train.py --data data/data.txt --out model/weights \
--models cvae acgan maskgit mdlm
pytest
model/predict.py-- CLI entry pointmodel/train.py-- training orchestratormodel/training.py-- per-model trainersmodel/tokenizer.py,model/data.py,model/metrics.py,model/evaluation.pymodel/models/{cvae,acgan,maskgit,mdlm}.py-- the four model implementationsmodel/weights/{cvae,acgan,maskgit,mdlm}.pt-- trained weightsmodel/weights_legacy/-- previous submission's weights (kept for comparison)tests/-- pytest testsnotebook.ipynb-- Colab walkthroughreport/-- assignment write-upscripts/run_final_eval.py,scripts/run_cfg_ablation.pyresults/-- CSR tables, diversity, figures
| # | Model | Class | Citation |
|---|---|---|---|
| 1 | CVAE + CFG dropout | In-course | Sohn 2015; Ho & Salimans 2022 |
| 2 | AC-GAN hybrid MLE + WGAN-GP + projection-D | In-course (required GAN) | Odena 2017; Che 2017; Gulrajani 2017; Miyato/Koyama 2018 |
| 3 | MaskGIT | Out-of-course | Chang et al. CVPR 2022 |
| 4 | MDLM + CFG + joint head | Out-of-course | Sahoo et al. NeurIPS 2024 |
See docs/superpowers/specs/2026-05-17-dates-generator-research-backed-redesign-design.md
for the design rationale.
Seed 0 everywhere (torch, numpy, random). Dates range [1-1-1800, 31-12-2200] per the assignment constraint.