Skip to content

Agent Handoff Queue ​

The Agent Handoff Queue is the 3.1 operating layer for choosing LLM-ready work from a workspace. It is not a new database, worker runtime, or dashboard source. It is a CLI-first layer over workspace-queues/v1, ticket handoff, and the normal ticket lifecycle.

Source Contract ​

workspace-queues/v1 remains the source contract. It is computed from GitHub issues, labels, PRs, checks, reviews, readiness reports, and workspace config.

CommandSchemaMutatesPurpose
gira queue listqueue-list/v1NoInventory queue items by canonical queue name.
gira queue nextqueue-next/v1NoSelect the first agent_ready item and print handoff/run commands.
gira queue handoffqueue-handoff/v1NoEmbed worker-handoff/v1 and stop if the selected ticket is not worker-ready.
gira queue take --dry-runqueue-take/v1NoPreview selection, handoff readiness, and delegated ticket start.
gira queue take --applyqueue-take/v1YesDelegate to ticket start for a handoff-safe and worker-ready item.

queue take --apply is the only mutating queue command. It preserves the existing ticket start branch policy and status behavior. It does not run Codex, call an LLM, or start a long-running worker.

Stop Reasons ​

Stop reasons are policy gates, not noise.

Stop reason familyMeaningUsual next step
no_agent_ready_itemNo item is eligible for automatic handoff.Inspect queue list.
queue_not_handoff_safeThe ticket is in review, finish, blocked, failed, or human-decision state.Run the item's next_safe_command.
worker_handoff_not_readyworker-handoff/v1 found weak or missing ticket context.Refine or view the ticket.
readiness_needs_refinement, finding_*, next_refine_ticketTicket readiness named concrete missing evidence.Add scope, acceptance, doctor impact, or evidence expectations.

Adapters should refuse queue take --apply when any stop reason is present.

Worker Boundary ​

The queue layer stops at selection, handoff, and branch start. External workers still own implementation, verification, PR updates, and provenance.

text
workspace-queues/v1
  -> queue next or queue handoff
  -> worker-handoff/v1
  -> queue take or ticket start
  -> external worker
  -> PR/check/review evidence
  -> ticket finish

gira run start may be printed as a next command so a local runtime can create a worker-run/v1 manifest, but queue commands do not invoke that runtime by default.

The 3.1 queue model resolves the first planning layer for older query, export, and backlog candidates:

CandidateDecision
#643 Query UXQueue filters and workspace-queues/v1 are the first operational query surface.
#641 Export reportsExport/report work should consume workspace-queues/v1 and queue-* JSON.
#645 Backlog localityExecutable work state should converge through GitHub issues, queue contracts, ticket handoff, and queue take.

See also Workspace, Worker Boundary, and Command Reference.

GitHub remains the source of truth.