7/34
Part 2 of 5 · AdmissionLearn and do

A few priority bands, tied to quota

When jobs compete, something has to rank them.

BandWhat runs thereMay preempt by priorityQuota per team
productionretrains and inference with deadlinesstandard and best effort, never productionsmall
standardteam trainingbest effortlarger
best effortsweeps, backfill, anything opportunisticnothingunlimited, and preemptible

Give priorities a few named bands, not a free-for-all of integers. Borg uses bands that don't overlap: monitoring, production, batch and best effort, from highest to lowest. Notebooks often get their own small quota rather than a band.

Bands stop two failures. The first is a preemption cascade: a job bumps a slightly lower one, which bumps another, and so on down. Borg's fix is that tasks in the production band can't preempt each other.

The second is priority inflation, where every team marks everything urgent. Tie the bands to quota, so high priority stays scarce. In Borg, quota at a higher priority costs more than quota at a lower one. Every user has unlimited quota at priority zero, but that's often hard to use, because the resources are oversubscribed.

In the editor, write may_preempt(band, victim) and a band-aware admit(band, gpus, used, quota). BANDS lists the table's bands, highest first, and QUOTA and USED hold one team's GPUs in each band.