Skip to content

Commit 9f927c7

Browse files
jwaldripclaude
andcommitted
fix(plugin): improve ticket description formatting and structure
Ticket descriptions were rendering as raw text with literal \n characters. Added structured templates for both epic and unit ticket descriptions with explicit guidance to use real newlines. Tickets now include Overview, Completion Criteria, Dependencies, and Technical Notes sections. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 036ef7e commit 9f927c7

File tree

2 files changed

+63
-4
lines changed

2 files changed

+63
-4
lines changed

plugin/providers/ticketing.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,17 @@ description: Default ticketing provider behavior for AI-DLC
2121
- **Reviewer rejects** → Add review feedback as ticket comment, keep In Progress
2222

2323
## Ticket Content
24-
- Include unit success criteria as a checklist in the ticket description
25-
- Link to the `.ai-dlc/` artifact path or branch for developer reference
24+
25+
**CRITICAL**: Always pass description strings with real newlines (multiline), never escaped `\n` literals. MCP tool description fields accept markdown — use it.
26+
27+
Structure ticket descriptions with these sections (omit any that are empty):
28+
29+
1. **Overview** — unit description (the prose from the unit file, not just the title)
30+
2. **Completion Criteria** — checklist (`- [ ] criterion`)
31+
3. **Dependencies** — blocked-by units with ticket keys if known
32+
4. **Technical Notes** — implementation guidance, constraints, or architectural notes from the unit file
33+
34+
The goal is a ticket that gives a developer full context without needing to read `.ai-dlc/` files.
2635

2736
## Provider Config
2837

plugin/skills/elaborate/SKILL.md

Lines changed: 52 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -830,17 +830,67 @@ Read the provider config schema for reference: `${CLAUDE_PLUGIN_ROOT}/schemas/pr
830830

831831
1. **Epic handling**:
832832
- If `epic` field in intent.md frontmatter is already populated (provided by product), use that existing epic — do not create a new one
833-
- If `epic` is empty, create an epic from the intent (title from intent title, description from Problem + Solution) using the ticketing MCP tools (e.g., `mcp__*jira*__create*`, `gh issue create`), then store the epic key in intent.md frontmatter
833+
- If `epic` is empty, create an epic from the intent using the ticketing MCP tools (e.g., `mcp__*jira*__create*`, `gh issue create`), then store the epic key in intent.md frontmatter
834+
- Epic title: intent title
835+
- Epic description (multiline markdown, NOT escaped `\n`):
836+
```markdown
837+
## Problem
838+
839+
{problem statement from intent.md}
840+
841+
## Solution
842+
843+
{solution description from intent.md}
844+
845+
## Units
846+
847+
{numbered list of unit titles from the decomposition}
848+
1. {unit-01 title}
849+
2. {unit-02 title}
850+
...
851+
```
834852

835853
2. **Create tickets** per unit, using config fields:
836854
- Title: unit title (from unit filename slug, humanized)
837-
- Description: unit completion criteria as checklist
855+
- Description: see **Ticket Description Format** below
838856
- Issue type: `config.issue_type` (fall back to "Task")
839857
- Issue type ID: `config.issue_type_id` (overrides name lookup if set)
840858
- Labels: `config.labels[unit.discipline]` (if configured, apply discipline-mapped labels)
841859
- Story points: estimate and set if `config.story_points` = "required"
842860
- Details: include additional content per `config.details` requirements
843861

862+
### Ticket Description Format
863+
864+
**CRITICAL**: Always pass description strings with real newlines (multiline), never escaped `\n` literals. MCP tool description fields accept markdown — use it.
865+
866+
Build the description from the unit file content using this structure:
867+
868+
```markdown
869+
## Overview
870+
871+
{unit description from the unit file body — the paragraph(s) after the frontmatter heading}
872+
873+
## Completion Criteria
874+
875+
- [ ] {criterion 1}
876+
- [ ] {criterion 2}
877+
- [ ] {criterion 3}
878+
879+
## Dependencies
880+
881+
{if unit has depends_on, list them here with their ticket keys if known}
882+
- Blocked by: {dependency unit title} ({ticket key})
883+
884+
{if unit has no dependencies}
885+
None — this unit can start immediately.
886+
887+
## Technical Notes
888+
889+
{include any implementation guidance, constraints, or architectural notes from the unit file body — omit this section if the unit has no technical detail beyond the criteria}
890+
```
891+
892+
Omit sections that have no content (e.g., skip "Dependencies" if none, skip "Technical Notes" if the unit file has no implementation detail). The goal is a ticket that gives a developer full context without reading the `.ai-dlc/` files.
893+
844894
**Every unit ticket MUST be linked to the intent epic** (unless `config.epic_link` is explicitly set to `"none"`). The epic is the single parent that groups all unit work — without this link, tickets are orphaned and invisible to project tracking. This applies regardless of provider: Jira epic links, Linear parent issues, GitHub milestones/tracked-by, GitLab epic associations.
845895

846896
3. **Map DAG to blocked-by** (if `config.issue_links` != "none"):

0 commit comments

Comments
 (0)