← Back to library

Route tracker tickets to the right repo by label

bibstha on Hacker News wanted one Linear account as a control plane: tasks arrive from Telegram or OpenClaw, and each is routed to the right repository with a pull request opened for review. Cyrus does this through labels that map work to repos.

  • OutcomeSend tasks from chat into one issue tracker and let labels decide which repository and which model a coding agent uses, ending in pull requests for review.
  • SetupAn afternoon+
  • LevelAdvanced
  • Creditbibstha on Hacker News
View original
Works with
Claude CodeCustom agentOpenClaw

Published Oct 23, 2026Updated Oct 23, 2026AI dry run on sample input: passed Oct 23, 2026Source verified Oct 24, 2026

When should you use it?

  • You maintain several unrelated repos
  • Tasks arrive from chat on the go
  • You want PRs, not direct pushes

Not for: Single-repo projects; Teams without review discipline

What do you need, and what do you get?

You need

  • Issue tracker with labels
  • Repos and branch rules
  • Model choices

You get

  • Each task landing in its matching codebase
  • Draft PRs awaiting your read

How does it work, step by step?

  1. Create the routing labelsOne label per repository and optionally per model.
  2. Feed tasks inSend tasks to the tracker from chat.
  3. Map labels to worktreesConfigure the agent so each label builds in the matching repo.
  4. Open pull requestsHave every job end as a PR, never a direct push.
  5. Review and mergeRead each PR yourself before merging.

The prompt

Our own prompt, inspired by bibstha on Hacker News and written to work in Claude Code, Custom agent and OpenClaw. Values in lime are placeholders.

Fill in the blanks (optional; the copied prompt uses your values)

Prompt3 variables
New task from chat: {task}
Rewrite it as a ticket with a clear title, acceptance criteria and test notes. Suggest the repo label from {repo_labels} and the model label from {model_labels}, with a reason. Do not create the ticket until I confirm.

Inspired by bibstha on Hacker News: Hacker News comment on routing Linear tickets to coding agents. The prompt above is written by playbooks.bot in our own words; nothing from the original is quoted.

What can go wrong?

  • A wrong label sends work to the wrong repo; check labels on creation.
  • Chat-triggered tasks can be vague; require acceptance criteria.

Our take

Labels are an underrated control surface: humans already understand them, trackers already enforce them, and they leave a visible record of why a task went where it did. Using them to route work across repositories beats fragile freeform routing. bibstha wanted one Linear workspace to control work across several unrelated repositories, with tasks arriving from chat. Labels do the routing: one per repository, and optionally one per model, so each job builds in the right place and leaves a visible reason for where it went. Every job should end as a pull request, never a direct push, and you read each one before merging. Two failure points deserve attention. A wrong label sends work to the wrong repo, so check labels when tasks are created. Tasks sent from a phone are often vague, so require a line of acceptance criteria before anything is picked up. Single-repo projects do not need this, and teams without review discipline should not try it.

Where the time goes back: Tasks reach the right codebase without you opening each project, and you spend time only on review.

FAQ

Why two tools?
He uses one for automated runs from chat and another for hands-on sessions.
Do labels also choose a model?
Yes, in his setup labels also select which model handles the task.

Source and credit

Inspired by bibstha on Hacker News. We describe the idea in our own words, link to the original, and wrote the prompt ourselves; nothing is quoted.

Inspired by
Hacker News comment on routing Linear tickets to coding agents
Creator
bibstha on Hacker News
Published on
Hacker News
Original date
Sep 8, 2026
License
Not openly licensed (the poster keeps all rights), so we quote nothing and link to the original
Originally for
Custom agent
AI dry run
Oct 23, 2026: passed. Dry-run tested by our AI test agent on sample input. PASS: Gates held on desk check; no live sends or purchases.
AI dry run on sample data; not run with live connected accounts. The playbooks.bot test agent filled the prompt with synthetic inputs, produced the output and checked it against the page's stated outputs and guardrails.
Verified
Oct 24, 2026: source link resolves to the original, the credited creator published it, our excerpt or prompt matches it, and the license allows our use.

Are you the creator? Claim or correct this page.

More in IT & Security

All 82 IT & Security playbooks →

Related playbooks

IT & SecurityWorkflow✓ AI dry run

Fix a scheduled agent digest that never arrives

Get your scheduled digest delivered again by finding why the job returned nothing and switching off the setting that swallowed its output.

Credit: Alex Rezvov

Under an hour
IT & SecurityWorkflow✓ AI dry run

Get consent first, then audit with a second agent

Have a different coding agent review your work in an isolated copy with editing turned off, and require it to ask before using any account or login.

Credit: u/Bulldagshunter on r/ClaudeCode

Under an hour
IT & SecurityWorkflow✓ AI dry run

Read an unknown compiled program with an agent's help

Understand an unknown compiled program when you barely know Ghidra, by letting an agent call it over MCP and explain what the code does.

Credit: Huli

An afternoon+
IT & SecurityWorkflow✓ AI dry run

Split coding work across six bots, from issue to draft PR

Run each code change through separate bots for research, routing, building, testing, review and a risk check, so a draft pull request arrives with its context and checks attached.

Credit: Morlex (@0xMorlex)

An afternoon+