Linear's Template-Based Agent Constraint Pattern
TRIGGER
Routine engineering requests from non-engineering teams (like ops) create a recurring coordination burden—each request requires an engineer to understand context, implement a similar change, and handle the handoff, even when the pattern is well-established.
APPROACH
Mercury created a Linear Asks template that starts from Slack: ops fills out 5 required fields, which generates a ticket with a task description at the top and a 'notes for AI' section at the bottom containing guidance like 'Copy this approach' or 'Refer to this PR as an example.' Input: 5-field Slack form submission. Output: agent-generated PR ready for human review. The ticket auto-assigns to an agent via Linear template, the agent picks it up, works, and creates a PR. Engineers review the PR like any other. Used for internal configuration UIs that operators use to review activities.
PATTERN
“Constrain the solution space and you'll get reliable agents; improve the agent and you'll get expensive disappointment. The 'notes for AI' section works because you're asking the agent to replicate a known-good approach in a new context, not figure out the right approach from scratch.”
✓ WORKS WHEN
- Task follows a repeatable pattern with existing examples in the codebase
- Non-engineering stakeholders can specify what they need via structured fields
- The change scope is bounded (e.g., configuration UI, not core business logic)
- Human review of agent output is fast because the pattern is familiar
- Request volume is high enough (more than 3-5 per month) to justify template creation
✗ FAILS WHEN
- Each request requires novel architectural decisions with no prior examples
- Stakeholders cannot articulate requirements in structured fields
- Changes touch sensitive areas requiring deep contextual judgment (payments, auth)
- The codebase lacks clear examples of the pattern to reference
- Request volume is too low to amortize template setup cost