submit_job
Submits a batch job after runbook checks and records it in the local ledger, requiring a script path, purpose, and human approval for expensive jobs.
Instructions
Submit a batch job after the runbook checks (see check_job) and record it in the local ledger.
script: the path of the job script on the cluster, relative to cwd (default: the configured workdir); script
text is refused (check a draft with check_job(script_text=...), then save it in the project, push_files, submit).
The job is submitted on hold, checked against Slurm's own reading of it, and released (or cancelled if Slurm
reads it differently and it then breaks the rules). purpose: one line on what the job is for. approval: the
human's explicit approval in their words (who, what, limit); required above the approval limits ([limits] in the
config; by default ≥ 4 nodes at once, > 20 tokens including your other jobs), for B200 and long/priority QoS; a job
of 16 or more nodes (headsup_nodes) needs an approval that names its node count, even inside an approved budget. Refused when a model, container, env or input the script reads does
not exist on the cluster (unless the job has a --dependency, or allow_missing=True for a job that fetches or
creates them itself before use: then a warning). Pass each sbatch option and its value as separate items.
expected_minutes: your runtime estimate (a --time far above it is flagged).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cwd | No | ||
| script | Yes | ||
| purpose | Yes | ||
| approval | No | ||
| sbatch_args | No | ||
| script_args | No | ||
| allow_missing | No | ||
| expected_minutes | No |