Contract-Driven Ticket Execution
Announce at start: "I'm using the ticket-work skill."
Usage
/ticket-work PROJ-1807
/ticket-work PROJ-1807 --autonomous
/ticket-work PROJ-1807 --skip-to implement
Execution
Step 1 — Parse arguments
ticket_id→ Linear ticket ID (required)--autonomous→ skip human gates (for pipeline/overnight use)--skip-to→ resume from named phase
Step 2 — Initialize node (contract verification)
onex run-node node_ticket_work \
--input '{"ticket_id": "<ticket_id>", "autonomous": false, "skip_to": null}' \
--timeout 300
On non-zero exit, a SkillRoutingError JSON envelope is returned — surface it directly, do not produce prose. Note: handler is a structural placeholder; full migration is tracked separately.
Step 3 — Execute ticket phases via tracker DI
This skill uses ProtocolProjectTracker DI (resolved via resolve_project_tracker()) for all
Linear operations. The tracker adapter handles routing automatically.
- INTAKE: Fetch ticket via
tracker.get_issue(); parse contract YAML block - RESEARCH: Read relevant code, check existing implementations — see Research Enrichment below
- QUESTIONS: Surface blockers → human gate (skipped in
--autonomousmode) - SPEC: Write implementation spec to ticket description
- IMPLEMENT: Write code in git worktree; run tests; pre-commit clean
- REVIEW: Run local-review skill; address findings
- DONE: Create PR; update Linear ticket status to In Review
Step 4 — Report
Write ModelSkillResult to $ONEX_STATE_DIR/skill-results/{context_id}/ticket-work.json.
Display: phase reached, PR URL, any blocking questions.
Research Enrichment Flow
Before proceeding from RESEARCH to QUESTIONS, the node dispatches a context request to
node_ticket_research_enrichment_compute. This enriches the research phase with assembled
knowledge context based on the ticket's repo, description, and linked files.
onex run-node node_ticket_research_enrichment_compute \
--input '{
"ticket_id": "<ticket_id>",
"repo": "<repo>",
"description": "<ticket_description>",
"linked_files": ["<file1>", "<file2>"],
"context_timeout_s": 10.0
}' \
--timeout 15
Output written to: $ONEX_STATE_DIR/knowledge-context/<ticket_id>.md
Non-blocking by design: if the context assembler times out (>10s default) or errors,
research continues without context — enrichment is advisory, not required. The result
status (ok | timeout | error | skipped) is logged but does not gate phase progression.
Enrichment statuses:
| Status | Meaning |
|---|---|
ok |
Context assembled and written to audit path |
timeout |
Assembler exceeded context_timeout_s; research proceeds without context |
error |
Assembler raised an exception; research proceeds without context |
skipped |
No assembler configured (default; safe to ignore) |
Architecture
SKILL.md -> thin shell (this file)
node -> omnimarket/src/omnimarket/nodes/node_ticket_work/ (structural placeholder)
contract -> node_ticket_work/contract.yaml
enrichment -> omnimarket/src/omnimarket/nodes/node_ticket_research_enrichment_compute/