ubiquitous-invention/docs/templates/task-template.md
Randall Stillwell 72aa2a5f0c feat(backlog): workflow_prompt with task → epic → plan inheritance
Adds the data layer for per-item agent prompts. Markdown frontmatter
gets an `agent_prompt:` block scalar that survives the importer
round-trip (newlines preserved), and `resolveWorkflowPrompt()` walks
task → epic → plan → built-in default returning both the resolved
string and the source level. Walk is slug-based, not parent_id-based,
because the importer leaves parent_id briefly null mid-transaction.

tRPC `backlog.getWorkflowPrompt` returns ownOverride + effectivePrompt
so future UI can render the override box + preview without two
queries. `backlog.updateWorkflowPrompt` is owner/admin-gated (prompts
change downstream Cursor/Claude behavior) and audit-logged on every
write.

UI deferred — apps/web doesn't have a backlog-item detail panel yet;
the existing object-detail panel is for the objects table. Follow-up
filed at Task-workflow-prompt-task-detail-ui.md.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-02 22:18:18 -05:00

55 lines
1.2 KiB
Markdown

---
kind: task
slug: "<task-slug>"
title: "<Task title>"
plan_slug: "<plan-slug>"
epic_slug: "<epic-slug>"
status: ready
priority: P2
tenant_id: "<tenant-uuid-or-placeholder>"
owner: "<name-or-unassigned>"
cursor_todo_id: null
updated_at: "<ISO-8601>"
# Uncomment to set a task-specific agent prompt. Most tasks inherit from
# the epic or plan; only set this when the task needs different first-message
# context (e.g. a security-sensitive change, or one with a non-standard
# verification protocol).
# agent_prompt: |
# You are completing one focused task. Read the task body before writing
# any code. Validate inputs with zod. Run lint/type-check/test before
# declaring done.
---
# Task summary
One or two sentences.
## Description
Implementation notes, context links, and technical constraints.
## Subtasks
- [ ]
- [ ]
## Owner or assignee
`<owner>`
## Status
`<draft | ready | in_progress | blocked | done | cancelled>`
## Estimation
`<e.g. S / M / L or hours>`
## Acceptance criteria
- [ ]
## Links to related Epic / Plan
- Epic: `./Epic-<epic-slug>.md` (same directory as this task)
- Plan: `../Plan-<plan-slug>.md` (parent of `Epic-<epic-slug>/`; matches `plans/Plan-<plan-slug>/Plan-<plan-slug>.md`)