Skip to content

feat(cloud): Kaggle GPU training path and a guard against Modal GPU on production - #82

Merged
abrichr merged 1 commit into
mainfrom
feat/kaggle-training-modal-gpu-guard
Oct 17, 2026
Merged

abrichr merged 1 commit into
mainfrom
feat/kaggle-training-modal-gpu-guard

Conversation

@abrichr

@abrichr abrichr commented Oct 17, 2026

Copy link
Copy Markdown
Member

On 2026-10-16, GPU training exhausted the spend limit on the production Modal workspace (abrichr), and Modal then disabled the hosted runner, compiler and recorder behind app.openadapt.ai. The decision: Modal keeps the hosted services only, and GPU training moves to Kaggle.

  • openadapt_ml.cloud.kaggle_cloud: stage builds a private dataset (bundle, config, optional checkpoint/) and a script kernel whose kernel-metadata.json turns on GPU and internet, on T4 or P100. push runs kaggle datasets create/version and then kaggle kernels push. status and pull use kaggle kernels output. To resume, stage again with the pulled results passed as --checkpoint.
  • kaggle_train_kernel.py: exits 3 when the session has no GPU or no internet, so a run that falls back to CPU can't count as a GPU run. (This happened with earlier Kaggle kernels on an unverified account.)
  • modal_gpu_guard: modal_cloud train and serve, and both app builders, refuse unless OPENADAPT_ALLOW_MODAL_GPU=1, MODAL_ENVIRONMENT is not main/prod/production, and the active Modal profile is not a production workspace (OPENADAPT_MODAL_PROD_WORKSPACES, default abrichr).
  • Docs: Kaggle usage, plus setting a Modal workspace budget and spend limit. Starter-plan budgets apply to the whole workspace, so GPU work belongs in a separate workspace.

Tests: ruff check and format pass; pytest tests/ gives 534 passed, 2 skipped. The new guard and staging tests need no network. Nothing was pushed to Kaggle or Modal.

Opened by an agent session for Richard Abrich.

…n production

Production Modal (runner/compiler/recorder for app.openadapt.ai) was disabled
on 2026-10-16 when GPU training exhausted the workspace spend limit.

- kaggle_cloud: stage dataset + GPU script kernel (kernel-metadata.json with
  enable_gpu/internet, private), push via kaggle datasets/kernels, status,
  pull results; checkpoints re-upload as dataset checkpoint/ for resume.
- kaggle_train_kernel: refuses to run without GPU and internet (exit 3).
- modal_gpu_guard: Modal GPU train/serve refuse unless
  OPENADAPT_ALLOW_MODAL_GPU=1, a non-prod MODAL_ENVIRONMENT, and a
  non-production Modal profile.
- docs: Kaggle usage and setting a Modal workspace budget/spend limit.

Signed-off-by: Richard Abrich <richard.abrich@mldsai.com>
@abrichr
abrichr merged commit 69c74e3 into main Oct 17, 2026
4 checks passed
@abrichr
abrichr deleted the feat/kaggle-training-modal-gpu-guard branch October 17, 2026 02:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant