Level 1 A basic labeling schedule
A labeling platform has t tasks (ids 0..t-1), m models (0..m-1) and h human labelers (0..h-1). A schedule is a list of (task, model, human) tuples: that human labels that model's output on that task.
Write build_basic_schedule(t, m, h, k) -> list[tuple[int, int, int]] | None such that:
- every human appears in exactly
ktuples (this is the shortest schedule where everyone does at leastk), - no human labels the same task twice,
- every id is in range.
Return None if any of t, m, h is not positive, if k is negative, or if no schedule exists. Return [] when k == 0. Think first about when a schedule is impossible. Any valid schedule is accepted, and the model can be anything in range.
build_basic_schedule(3, 2, 2, 2)
# e.g. [(0, 0, 0), (1, 0, 0), (1, 0, 1), (2, 0, 1)]
build_basic_schedule(2, 1, 5, 3) # None: a human can do at most 2 distinct tasks