import type { Rules } from '../rules/index.js' /** What a worker gets with a range (the coordinator's lease). */ export interface Lease { range: { id: number; group: string; start: number; end: number; next: number } rules: Rules } /** * A group lease (REBUILD.md, "Voyager 3: window indexing", 1): the group a worker thread holds, the rules, and the * snapshot of the group's window when there is one (its next article; the body comes from GET groups/:id/snapshot). */ export interface GroupLease { group: { id: number; name: string; priority: number } rules: Rules snapshot: { next: number } | null } /** The group's next range in article order, leased to the holder (POST groups/:id/next; 204 when caught up). */ export interface NextRange { range: { id: number; start: number; end: number; next: number } }