@codyswann/lisa 2.3.0 → 2.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,318 @@
1
+ ---
2
+ name: confluence-to-jira
3
+ description: >
4
+ Break down a Confluence PRD page into JIRA epics, stories, and sub-tasks. Use this skill whenever the
5
+ user shares a Confluence PRD URL and wants it converted into JIRA tickets, or asks to "break down
6
+ this Confluence spec", "create tickets from a Confluence page", "turn this Confluence doc into JIRA",
7
+ or similar. This skill mirrors `lisa:notion-to-jira` for projects whose PRDs live in Confluence —
8
+ the workflow, gates, dry-run mode, and validation rules are identical; only the source-of-truth tool
9
+ surface differs (Confluence MCP instead of Notion MCP).
10
+ allowed-tools: ["Skill", "Bash", "mcp__atlassian__getConfluencePage", "mcp__atlassian__getConfluencePageDescendants", "mcp__atlassian__getConfluencePageFooterComments", "mcp__atlassian__getConfluencePageInlineComments", "mcp__atlassian__getConfluenceCommentChildren", "mcp__atlassian__searchConfluenceUsingCql", "mcp__atlassian__getAccessibleAtlassianResources", "mcp__atlassian__getJiraIssueRemoteIssueLinks"]
11
+ ---
12
+
13
+ # Confluence PRD to JIRA Breakdown
14
+
15
+ Convert a Confluence PRD into a structured JIRA ticket hierarchy: Epics > Stories > Sub-tasks.
16
+ Each sub-task is scoped to exactly one repo and includes an empirical verification plan.
17
+
18
+ This skill is the Confluence counterpart of `lisa:notion-to-jira`. The two skills share the same
19
+ phases, gates, dry-run contract, and per-ticket validation logic. Only the PRD-side fetch / comment
20
+ tools differ. When changing workflow logic, change BOTH skills together so the two source vendors
21
+ stay behaviorally identical.
22
+
23
+ ## Modes
24
+
25
+ This skill supports two modes, controlled by a `dry_run` flag in `$ARGUMENTS`:
26
+
27
+ - **`dry_run: false`** (default — full mode): run all phases, write tickets via `lisa:jira-write-ticket`, run the preservation gate, report.
28
+ - **`dry_run: true`** (planning + validation only — no writes): run Phases 1, 1.5, 1.6, 2, 3, 4 to plan the hierarchy and draft each ticket spec, then call `lisa:jira-validate-ticket` (with `--spec-only`) on every drafted ticket. Aggregate the per-ticket validator reports into a single dry-run report. **Skip Phase 5 (sub-task creation), Phase 5.5 (preservation gate), and Phase 6 (results report)** — none of those make sense without writes. Return the dry-run report so the caller (e.g. `lisa:confluence-prd-intake`) can decide whether to proceed.
29
+
30
+ Dry-run output format is identical to `lisa:notion-to-jira`'s. Reuse the same fields, including
31
+ `prd_anchor` and `prd_section`. The only difference: `prd_anchor` is the inline-comment anchor text
32
+ that `createConfluenceInlineComment` accepts (typically the full selected substring; truncate if it
33
+ exceeds the tool's max anchor length and emit `null` if no resolvable anchor exists).
34
+
35
+ ```text
36
+ ## confluence-to-jira dry-run: <PRD title>
37
+
38
+ ### Planned hierarchy
39
+ - Epic: <summary>
40
+ prd_section: "<heading text from the PRD that produced this epic>"
41
+ prd_anchor: "<inline-comment anchor text>" # null if no specific section
42
+ - Story 1.1: <summary>
43
+ prd_section: "<heading or user-story line>"
44
+ prd_anchor: "<anchor>"
45
+ - Sub-task [<repo>]: <summary>
46
+ prd_section: "<heading or AC bullet>"
47
+ prd_anchor: "<anchor>"
48
+ - ...
49
+ - Story 1.2: ...
50
+
51
+ ### Per-ticket validation
52
+ - <ticket-id>: PASS | FAIL — <count> failures
53
+ prd_section: "<heading text>"
54
+ prd_anchor: "<anchor>"
55
+ failures:
56
+ - gate: <gate-id>
57
+ category: <category from validator>
58
+ product_relevant: <true|false>
59
+ what: <plain-language description from validator>
60
+ recommendation: <1–3 candidate resolutions from validator>
61
+
62
+ ### Verdict: PASS | FAIL
63
+ ### Total failures: <n>
64
+ ```
65
+
66
+ The dry-run mode never writes to JIRA and never calls `mcp__atlassian__createJiraIssue`. It also never
67
+ modifies the source Confluence page, never adds/removes labels, and never posts comments — that is the
68
+ orchestrating skill's responsibility (`lisa:confluence-prd-intake`).
69
+
70
+ ## Hard Rule: All Writes Go Through `lisa:jira-write-ticket`
71
+
72
+ **Every JIRA ticket created by this skill — every epic, story, and sub-task — MUST be created by invoking the `lisa:jira-write-ticket` skill. Never call `mcp__atlassian__createJiraIssue`, `mcp__atlassian__editJiraIssue`, `mcp__atlassian__createIssueLink`, or any other Atlassian write tool directly from this skill or from any sub-agent it spawns.**
73
+
74
+ `lisa:jira-write-ticket` enforces gates this skill does not:
75
+ - 3-audience description (Context / Technical Approach / Acceptance Criteria)
76
+ - Gherkin acceptance criteria
77
+ - Epic parent validation
78
+ - Explicit issue-link discovery (`blocks` / `is blocked by` / `relates to` / `duplicates` / `clones`)
79
+ - Single-repo scope check on Bug / Task / Sub-task
80
+ - Sign-in account and target environment recorded in description
81
+ - Post-create verification
82
+
83
+ Bypassing `lisa:jira-write-ticket` produces thin tickets that the rest of the lifecycle (triage, ticket-verify, journey, evidence) treats as broken. The Atlassian read tools (`getJiraIssue`, `searchJiraIssuesUsingJql`, `getJiraIssueRemoteIssueLinks`, `getAccessibleAtlassianResources`, `getJiraProjectIssueTypesMetadata`, `getVisibleJiraProjects`, and the Confluence read endpoints listed in `allowed-tools` above) ARE allowed for context gathering and the Phase 5.5 preservation gate.
84
+
85
+ ## Input
86
+
87
+ A Confluence PRD page URL or page ID. The PRD is expected to have:
88
+ - A main page with context, problems, and child pages for each Epic
89
+ - Epic child pages with User Stories and functional/non-functional requirements
90
+ - Page comments (footer + inline) with engineering notes and product decisions
91
+
92
+ URL parsing — Confluence URLs come in two common shapes:
93
+
94
+ ```text
95
+ https://<host>/wiki/spaces/<SPACE>/pages/<PAGE-ID>/<slug>
96
+ https://<host>/wiki/spaces/<SPACE>/pages/<PAGE-ID>
97
+ ```
98
+
99
+ Extract `<PAGE-ID>` (the numeric segment after `/pages/`). If only a space URL is provided
100
+ (`/wiki/spaces/<SPACE>` with no `/pages/...`), stop and report — single-PRD mode requires a specific
101
+ page. The caller wanted `lisa:confluence-prd-intake` (batch mode).
102
+
103
+ ## Configuration
104
+
105
+ This skill reads project-specific configuration from environment variables. If these are not set,
106
+ ask the user for the values before proceeding.
107
+
108
+ | Variable | Purpose | Example |
109
+ |----------|---------|---------|
110
+ | `JIRA_PROJECT` | JIRA project key for ticket creation | `SE` |
111
+ | `JIRA_SERVER` | Atlassian instance URL (site host) | `mycompany.atlassian.net` |
112
+ | `CONFLUENCE_HOST` | Confluence host (often same as `JIRA_SERVER`) | `mycompany.atlassian.net` |
113
+ | `E2E_TEST_PHONE` | Test user phone number for verification plans | `0000000099` |
114
+ | `E2E_TEST_OTP` | Test user OTP code | `555555` |
115
+ | `E2E_TEST_ORG` | Test organization name | `Arsenal` |
116
+ | `E2E_BASE_URL` | Frontend base URL for Playwright tests | `https://dev.example.io/` |
117
+ | `E2E_GRAPHQL_URL` | GraphQL API URL for curl verification | `https://gql.dev.example.io/graphql` |
118
+
119
+ If env vars are not available, ask the user to provide them explicitly before proceeding.
120
+ Do not retrieve credentials from repository files or local agent settings.
121
+
122
+ ## Workflow
123
+
124
+ ### Phase 1: Fetch & Analyze the PRD
125
+
126
+ 1. **Resolve the Atlassian cloud ID** via `mcp__atlassian__getAccessibleAtlassianResources`. Confluence MCP calls require it.
127
+ 2. **Fetch the main PRD page** via `mcp__atlassian__getConfluencePage` with the page ID. Capture body, labels, and child page references.
128
+ 3. **Identify all Epic child pages** via `mcp__atlassian__getConfluencePageDescendants` (one level deep first; recurse if the PRD nests epics under a "Specs" parent).
129
+ 4. **Fetch all Epic pages** in parallel via `getConfluencePage`.
130
+ 5. **Fetch full comments** for the main page and every epic page in parallel:
131
+ - `mcp__atlassian__getConfluencePageFooterComments` — page-level threaded comments (equivalent to Notion's page-level discussions)
132
+ - `mcp__atlassian__getConfluencePageInlineComments` — block-anchored comments tied to specific text spans
133
+ - For any comment with replies, walk the tree via `mcp__atlassian__getConfluenceCommentChildren` until exhausted
134
+ 6. **Synthesize decisions and blockers** from the PRD content + all comments:
135
+ - Decisions already confirmed by the team (look for agreement in comment threads)
136
+ - Open questions that need product/engineering input
137
+ - Engineering comments (prefixed with "Engineering:" or wrench emoji) that identify technical constraints
138
+ - Cross-PRD dependencies (references to other features or shared infrastructure)
139
+
140
+ ### Phase 1.5: Extract Source Artifacts
141
+
142
+ PRDs typically reference external design, UX, and data artifacts (Figma files, Lovable prototypes, Loom walkthroughs, screenshots, example payloads, peer Confluence pages). These MUST be preserved onto the resulting tickets — otherwise developers picking up a ticket lose the source of truth. This is the failure mode this step exists to prevent.
143
+
144
+ 1. **Scan the PRD main page, all Epic child pages, and every fetched comment thread** for:
145
+ - URLs to design/prototype tools (Figma, FigJam, Figma Make, Lovable, Framer, Penpot)
146
+ - URLs to recording/walkthrough tools (Loom, YouTube, Vimeo, Descript)
147
+ - URLs to collaborative docs (Google Docs/Slides/Sheets, peer Confluence pages, Notion peer pages)
148
+ - URLs to code sandboxes (CodeSandbox, StackBlitz, Replit, GitHub permalinks/gists)
149
+ - URLs to diagramming tools (Miro, Mural, Excalidraw, Mermaid Live, draw.io, Lucid)
150
+ - URLs to data/observability tools (Grafana, Datadog, Sentry, Metabase, Looker)
151
+ - Embedded images and file attachments on the page itself
152
+ - Fenced code blocks with example data (JSON, SQL, GraphQL, cURL request/response)
153
+
154
+ 2. **Classify each artifact and apply taxonomy rules** by invoking the `lisa:jira-source-artifacts` skill. That skill is the single source of truth for: domains (`ui-design` / `ux-flow` / `data` / `ops` / `reference`), per-tool classification rules (Figma `/proto/` vs design, Lovable as `ux-flow`, Loom, screenshots), and coverage smells. Do not restate the rules here — invoke the skill so any drift in the rules propagates uniformly.
155
+
156
+ 3. **Build an `artifacts` map** keyed by domain. Each entry: `{ url, title, domain, source_page, source_page_url, classification_reason }`. The `classification_reason` makes disambiguation auditable. The `source_page` lets you trace each reference back to where it appeared in the PRD.
157
+
158
+ 4. **Surface coverage smells** as defined in `lisa:jira-source-artifacts` §5. Record any detected smells on the epic.
159
+
160
+ ### Phase 1.6: Source Precedence & Conflict Resolution
161
+
162
+ Source precedence rules and cross-axis conflict handling are defined in `lisa:jira-source-artifacts` §3 and §4. Apply them during ticket synthesis: every conflict between artifacts must be recorded under `## Open Questions` on the affected ticket, never silently reconciled.
163
+
164
+ The existing-component reuse expectation is defined in `lisa:jira-source-artifacts` §7. Encode it on every UI-touching story.
165
+
166
+ ### Phase 2: Codebase + Live Product Research
167
+
168
+ Identical to `lisa:notion-to-jira` Phase 2. Two complementary inputs ground PRD analysis: the **code** (what's there to reuse / extend) and the **live product** (what users see today). Skipping either produces tickets that misjudge the change.
169
+
170
+ **2a. Codebase research.** If the session doesn't already have codebase context, explore the repos to understand what exists. Use Explore agents for repos not yet examined.
171
+
172
+ **2b. Live product walkthrough.** If the PRD touches existing user-facing surfaces, invoke the `lisa:product-walkthrough` skill against `E2E_BASE_URL` using the test user from config.
173
+
174
+ Skip 2b only when the work is purely backend with no user-visible surface, or affects a screen that does not yet exist in dev/prod.
175
+
176
+ Walkthrough findings are attached to the originating Confluence PRD as a **footer comment** (Confluence has no general "page-level discussion attached to a heading" — footer comments are the page-level equivalent), via `mcp__atlassian__createConfluenceFooterComment`. Title the comment "Current product walkthrough — `<route>`". Inherited onto the resulting epic / stories under a `## Current Product` subsection.
177
+
178
+ ### Phase 3: Create Epics
179
+
180
+ > **Mode guard**: In `dry_run: true` mode, do not invoke `lisa:jira-write-ticket` in this phase. Instead, draft the epic spec (summary, description_body, artifacts) and validate it with `lisa:jira-validate-ticket --spec-only`. Record the drafted spec (including a placeholder epic key like `DRY-RUN-EPIC-1`) for Phase 4 to use as parent references. In `dry_run: false` mode (default), proceed as described below.
181
+
182
+ For each PRD epic, **invoke the `lisa:jira-write-ticket` skill** (do not call `createJiraIssue` directly). Pass it everything it needs to enforce its quality gates:
183
+
184
+ - `project_key`: from `JIRA_PROJECT` config
185
+ - `issue_type`: `Epic`
186
+ - `summary`: epic title from the PRD
187
+ - `description_body`: a draft of the 3-audience description containing:
188
+ - **Context / Business Value**: epic summary from the PRD, originating Confluence URL, business outcome
189
+ - **Technical Approach**: cross-cutting integration points and constraints surfaced in Phase 2 codebase research
190
+ - List of user stories the epic contains
191
+ - Key decisions from comments (with attribution)
192
+ - Blockers and open questions
193
+ - Dependencies on other epics or PRDs
194
+ - A **Source Artifacts** section listing every artifact extracted in Phase 1.5 (grouped by domain)
195
+ - `artifacts`: the full Phase 1.5 artifact list — every artifact, regardless of domain. The epic is the canonical hub. No filtering at the epic level.
196
+ - `priority`, `labels`, `components`, `fix_version`: as appropriate
197
+
198
+ Capture the returned epic key — Phase 4 needs it as the parent for stories.
199
+
200
+ ### Phase 4: Create Stories
201
+
202
+ > **Mode guard**: In `dry_run: true` mode, do not invoke `lisa:jira-write-ticket` in this phase. Instead, draft each story spec and validate it with `lisa:jira-validate-ticket --spec-only`. Use placeholder keys (e.g. `DRY-RUN-STORY-1.1`) for any downstream references. In `dry_run: false` mode (default), proceed as described below.
203
+
204
+ For each Epic, plan two kinds of stories:
205
+ - **One "X.0 Setup" story** for data model and infrastructure prerequisites
206
+ - **One story per user story** from the PRD (numbered to match the PRD)
207
+
208
+ **Story naming convention**: Prefix the summary with a short code derived from the PRD title (e.g., `[CU-1.1]` for "Contract Upload").
209
+
210
+ For each story, **invoke `lisa:jira-write-ticket`** with:
211
+
212
+ - `project_key`: from `JIRA_PROJECT` config
213
+ - `issue_type`: `Story`
214
+ - `epic_parent`: the Epic key captured in Phase 3 (mandatory)
215
+ - `summary`: prefixed per the naming convention above
216
+ - `description_body`: 3-audience description as in `lisa:notion-to-jira` Phase 4
217
+ - `artifacts`: the Phase 1.5 artifacts filtered by domain per the inheritance table below
218
+
219
+ | Story type | Inherits domains |
220
+ |------------|------------------|
221
+ | Frontend / UI | `ui-design`, `ux-flow`, `reference` |
222
+ | Backend / API / data model | `data`, `reference` |
223
+ | Infrastructure | `ops`, `reference` |
224
+ | Mixed / setup ("X.0") | All domains |
225
+
226
+ Capture each returned story key — Phase 5 needs it as the parent for sub-tasks.
227
+
228
+ ### Phase 5: Create Sub-tasks
229
+
230
+ Delegate sub-task creation to **parallel agents** (one per epic or batch of stories) for efficiency. **Every spawned agent must invoke `lisa:jira-write-ticket` for each sub-task — no agent may call `createJiraIssue` directly.**
231
+
232
+ Each sub-task MUST:
233
+ 1. **Be scoped to exactly ONE repo** — indicated in brackets in the summary: `[repo-name]`
234
+ 2. **Include an Empirical Verification Plan** — real user-like verification, NOT unit tests, linting, or typechecking
235
+
236
+ Sub-tasks inherit their parent story's artifacts by reference (the parent link). Do not pass the same artifact list to every sub-task.
237
+
238
+ ### Phase 5.5: Artifact Preservation Gate (mandatory)
239
+
240
+ Run the preservation gate defined in `lisa:jira-source-artifacts` §8 against the artifacts extracted in Phase 1.5 and the tickets just created. Do NOT restate or modify the gate logic here — invoke the rules from `lisa:jira-source-artifacts`.
241
+
242
+ To run the gate, this skill must:
243
+
244
+ 1. Pull the remote links of every epic and story created in this run via `mcp__atlassian__getJiraIssueRemoteIssueLinks`.
245
+ 2. Apply the §8 preservation matrix and verdict rules.
246
+ 3. If the gate fails: list each dropped/misrouted artifact and either re-attach via `lisa:jira-write-ticket` (UPDATE mode) or stop and ask the human.
247
+ 4. If the gate passes: print the matrix compactly and proceed to Phase 6.
248
+
249
+ This gate is not optional.
250
+
251
+ ### Phase 6: Report Results
252
+
253
+ After all tickets are created, present a summary table to the user:
254
+ - All Epics with keys and URLs
255
+ - All Stories grouped by Epic
256
+ - All Sub-tasks grouped by Story with repo tags
257
+ - Repo distribution
258
+ - **Artifact Preservation Matrix**
259
+ - Blockers list with recommendations and alternatives
260
+ - Cross-PRD dependencies
261
+
262
+ ## Handling Ambiguities and Blockers
263
+
264
+ When you encounter something the PRD + comments + codebase can't resolve:
265
+
266
+ 1. **Don't guess** — mark the ticket with a BLOCKER section
267
+ 2. **Include your recommendation** with rationale
268
+ 3. **List 2-3 alternatives** so the user/product can choose
269
+ 4. **State what's needed to unblock**
270
+
271
+ ## Agent Prompt Template for Sub-task Creation
272
+
273
+ When delegating to agents, provide this context. **The "MUST invoke jira-write-ticket" instruction is load-bearing — do not edit it out when adapting this template.**
274
+
275
+ ```text
276
+ Create JIRA sub-tasks in the [PROJECT] project at [CLOUD_ID].
277
+
278
+ CRITICAL: For each sub-task, invoke the `lisa:jira-write-ticket` skill via the Skill tool.
279
+ Do NOT call `mcp__atlassian__createJiraIssue` directly. The `lisa:jira-write-ticket` skill
280
+ enforces required quality gates (Gherkin acceptance criteria, 3-audience description,
281
+ single-repo scope, sign-in/environment fields, post-create verification). Bypassing it
282
+ produces broken tickets that downstream skills (triage, journey, evidence) cannot use.
283
+
284
+ For each sub-task, invoke `lisa:jira-write-ticket` with:
285
+ - issue_type: "Sub-task"
286
+ - parent: the parent story key
287
+ - project_key: [PROJECT]
288
+ - summary: prefixed with the repo in brackets, e.g. "[backend-api] Add audit log table"
289
+ - description_body: a 3-section draft (Context / Technical Approach / Acceptance Criteria)
290
+ - gherkin_acceptance_criteria: derived from the story's functional requirements
291
+ - sign_in_account: [test user credentials from config — name + role + how to obtain]
292
+ - target_environment: "dev"
293
+ - empirical_verification_plan: real user-like verification (curl + auth token,
294
+ Playwright browser flow, CLI check after deploy) using the test credentials.
295
+ NOT unit tests, linting, or typechecking.
296
+
297
+ Each sub-task must:
298
+ 1. Be scoped to ONE repo only — repo named in brackets in the summary
299
+ 2. Include the Empirical Verification Plan in the description
300
+ 3. Be created via `lisa:jira-write-ticket`, not via direct MCP calls
301
+
302
+ If `lisa:jira-write-ticket` rejects a sub-task, fix the input and re-invoke. Do NOT fall back
303
+ to a direct `createJiraIssue` call to bypass the gate.
304
+
305
+ Test user info: [credentials from config]
306
+
307
+ [Then list all sub-tasks grouped by parent story with details]
308
+ ```
309
+
310
+ ## Cross-PRD Shared Infrastructure
311
+
312
+ Track tickets that are shared across PRDs to avoid duplication. When a sub-task overlaps with an existing ticket, reference it instead of creating a duplicate. Search JIRA for existing tickets in the project before creating new ones for shared infrastructure.
313
+
314
+ ## Confluence-specific notes
315
+
316
+ - **Page bodies** come back from `getConfluencePage` as either Atlassian Document Format (ADF / storage format) or rendered HTML depending on flags. Treat headings (`<h1>`–`<h3>`) as section markers for `prd_section`. For ADF, walk the document tree.
317
+ - **Inline comment anchors**: `prd_anchor` is the inline-comment selection text (the exact substring `createConfluenceInlineComment` will match). If the section is too long for an inline anchor (Confluence has a practical upper bound on selection length), pick the first sentence of the section. If the section has no stable anchor (e.g., a generated table cell), set `prd_anchor: null` and the caller will fall back to a footer comment.
318
+ - **Comment threading**: Confluence has separate footer and inline comment streams. When fetching comments in Phase 1, merge both into the analysis — they are equally authoritative for capturing decisions and engineering notes.
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: intake
3
- description: "Vendor-agnostic batch scanner for Status=Ready queues. Given a Notion PRD database URL → finds Ready PRDs and runs lisa:plan per item. Given a JIRA project key or JQL filter → finds Ready tickets and runs lisa:implement per item. Designed as the cron target for /schedule — one cycle per invocation, processes everything currently Ready, exits cleanly on empty. Symmetric counterpart to the single-item lisa:plan and lisa:implement skills."
4
- allowed-tools: ["Skill", "Bash", "mcp__claude_ai_Notion__notion-fetch", "mcp__claude_ai_Notion__notion-search", "mcp__atlassian__getAccessibleAtlassianResources", "mcp__atlassian__searchJiraIssuesUsingJql", "mcp__atlassian__getJiraIssue"]
3
+ description: "Vendor-agnostic batch scanner for Ready queues. Given a Notion PRD database URL → finds Ready PRDs and runs lisa:plan per item. Given a Confluence space or parent page URL → finds prd-ready PRDs and runs lisa:plan per item. Given a JIRA project key or JQL filter → finds Ready tickets and runs lisa:implement per item. Designed as the cron target for /schedule — one cycle per invocation, processes everything currently Ready, exits cleanly on empty. Symmetric counterpart to the single-item lisa:plan and lisa:implement skills."
4
+ allowed-tools: ["Skill", "Bash", "mcp__claude_ai_Notion__notion-fetch", "mcp__claude_ai_Notion__notion-search", "mcp__atlassian__getConfluencePage", "mcp__atlassian__getConfluenceSpaces", "mcp__atlassian__searchConfluenceUsingCql", "mcp__atlassian__getAccessibleAtlassianResources", "mcp__atlassian__searchJiraIssuesUsingJql", "mcp__atlassian__getJiraIssue"]
5
5
  ---
6
6
 
7
7
  # Intake: $ARGUMENTS
@@ -40,11 +40,21 @@ Detect the queue type from `$ARGUMENTS` and route:
40
40
  | If `$ARGUMENTS` is... | Queue type | Per-item dispatch |
41
41
  |------------------------|------------|---------------------|
42
42
  | A Notion **database** URL or database ID | PRD queue (Notion) | Invoke `lisa:notion-prd-intake` (which scans the DB for Status=Ready, claims each, runs `lisa:plan` per PRD via the dry-run validate → branch → write pipeline) |
43
+ | A Confluence **space** URL or space key (e.g. `https://acme.atlassian.net/wiki/spaces/PRD` or `PRD`) | PRD queue (Confluence) | Invoke `lisa:confluence-prd-intake` (which CQL-queries the space for `label = "prd-ready"`, claims each by relabeling to `prd-in-review`, runs the dry-run validate → branch → write pipeline) |
44
+ | A Confluence **parent page** URL or page ID (the page whose descendants are PRDs) | PRD queue (Confluence, narrowed) | Invoke `lisa:confluence-prd-intake` with the parent ID (CQL: `ancestor = <id> AND label = "prd-ready"`) |
43
45
  | A JIRA project key (e.g. `SE`) | Work queue (JIRA) | Invoke `lisa:jira-build-intake` (which scans the project for Status=Ready, claims each via In Progress, runs `lisa:implement` per ticket, transitions to On Dev on success) |
44
46
  | A full JQL filter (e.g. `project = SE AND component = "frontend"`) | Work queue (JIRA, narrowed) | Invoke `lisa:jira-build-intake` with the JQL |
45
47
  | A Linear / GitHub Issues queue | Not yet implemented | Stop and report — no `linear-tracker` or `github-tracker` adapter has been built. Don't fall back. |
46
48
 
47
- The single-item skills (`lisa:plan`, `lisa:implement`) and the per-vendor batch skills (`lisa:notion-prd-intake`, `lisa:jira-build-intake`) are internal — Intake is the public entry point. Developers schedule `/lisa:intake <queue>`; the rest is composition.
49
+ Disambiguation rules:
50
+
51
+ - A `notion.so` / `notion.site` URL → Notion queue.
52
+ - An Atlassian Confluence URL containing `/wiki/spaces/<KEY>` with no `/pages/...` segment → Confluence space queue.
53
+ - An Atlassian Confluence URL containing `/wiki/spaces/<KEY>/pages/<ID>/...` → Confluence parent-page queue (the page is the parent whose descendants are PRDs). If the user actually meant "this single page is a PRD, plan it", route to `lisa:plan` instead — this skill is batch-only.
54
+ - A bare alphanumeric token that matches the configured `JIRA_PROJECT` regex (uppercase letters / digits / hyphen, ≤10 chars) is treated as a JIRA project key by default. A token that does not match the regex is treated as a Confluence space key. The only time to stop and ask is when the token matches the JIRA_PROJECT regex AND is also a confirmed reachable Confluence space key (verified via Atlassian API) — in that specific overlap the user must disambiguate which queue to scan.
55
+ - A string starting with `project = ` or containing JQL operators (`AND`, `OR`, `=`, `!=`, `~`, etc.) → JQL filter.
56
+
57
+ The single-item skills (`lisa:plan`, `lisa:implement`) and the per-vendor batch skills (`lisa:notion-prd-intake`, `lisa:confluence-prd-intake`, `lisa:jira-build-intake`) are internal — Intake is the public entry point. Developers schedule `/lisa:intake <queue>`; the rest is composition.
48
58
 
49
59
  ## Cycle behavior
50
60
 
@@ -52,7 +62,8 @@ The single-item skills (`lisa:plan`, `lisa:implement`) and the per-vendor batch
52
62
  2. **Pre-flight check** — for JIRA, confirm `In Progress` and `On Dev` are reachable transitions before doing any per-ticket work. Stop with a clear error if the workflow is misconfigured.
53
63
  3. **Find Ready items** — query the queue. Empty → exit cleanly with `"No items with Status=Ready. Nothing to do."` This is the common idle case for a scheduled run.
54
64
  4. **Process each Ready item serially** (claim-first ordering for idempotency):
55
- - Notion PRDs → `lisa:notion-prd-intake` handles per-item: claim, dry-run validate, branch to Blocked or Ticketed, coverage audit
65
+ - Notion PRDs → `lisa:notion-prd-intake` handles per-item: claim (Status=In Review), dry-run validate, branch to Blocked or Ticketed, coverage audit
66
+ - Confluence PRDs → `lisa:confluence-prd-intake` handles per-item: claim (relabel to `prd-in-review`), dry-run validate, branch to `prd-blocked` or `prd-ticketed`, coverage audit
56
67
  - JIRA tickets → `lisa:jira-build-intake` handles per-item: claim, dispatch to `lisa:jira-agent`, transition to On Dev on success
57
68
  5. **Failure isolation** — one item failing does not stop the cycle; record under "Errors" and continue.
58
69
  6. **Summary report** — per-item outcomes, total processed, total errors.
@@ -61,6 +72,7 @@ The single-item skills (`lisa:plan`, `lisa:implement`) and the per-vendor batch
61
72
 
62
73
  ```text
63
74
  /schedule "every 30 minutes" /lisa:intake https://www.notion.so/<workspace>/<database-id>
75
+ /schedule "every 30 minutes" /lisa:intake https://acme.atlassian.net/wiki/spaces/PRD
64
76
  /schedule "every 30 minutes" /lisa:intake SE
65
77
  /schedule "every hour" /lisa:intake "project = SE AND component = 'frontend'"
66
78
  ```
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: plan
3
- description: "Decompose a single PRD or specification into ordered work items in the configured tracker. Vendor-agnostic — the source can be a Notion PRD URL, an existing JIRA epic key, a markdown file, or a free-form description; the destination tracker is whatever the project is configured to use (JIRA today; Linear/GitHub Issues are pluggable). Single-PRD mode only — for batch scanning of all Status=Ready PRDs in a queue, use the lisa:intake skill."
3
+ description: "Decompose a single PRD or specification into ordered work items in the configured tracker. Vendor-agnostic — the source can be a Notion PRD URL, a Confluence PRD URL, an existing JIRA epic key, a markdown file, or a free-form description; the destination tracker is whatever the project is configured to use (JIRA today; Linear/GitHub Issues are pluggable). Single-PRD mode only — for batch scanning of all Ready PRDs in a queue, use the lisa:intake skill."
4
4
  allowed-tools: ["Skill", "Bash", "Read", "Glob", "Grep"]
5
5
  ---
6
6
 
@@ -22,6 +22,8 @@ Detect the input type from `$ARGUMENTS` and route to the appropriate source skil
22
22
  |------------------------|-------------|
23
23
  | A Notion **page** URL or page ID (single PRD) | `lisa:notion-to-jira` (with the PRD URL; runs the full pipeline: extract artifacts → walk live product → validate → write tickets → coverage audit) |
24
24
  | A Notion **database** URL or database ID | Stop and report — single-PRD mode only. Direct the caller to `lisa:intake` for batch scanning of a database. |
25
+ | A Confluence **page** URL containing `/wiki/spaces/<KEY>/pages/<ID>/...` (single PRD) | `lisa:confluence-to-jira` (with the PRD URL; same full pipeline as the Notion path) |
26
+ | A Confluence **space** URL (`/wiki/spaces/<KEY>` with no `/pages/...`) | Stop and report — single-PRD mode only. Direct the caller to `lisa:intake` for batch scanning of a space. |
25
27
  | A JIRA ticket ID/URL of an Epic (existing epic *is* the spec) | `lisa:jira-agent` (read epic, decompose into stories/sub-tasks) |
26
28
  | A Linear / GitHub Issues URL or key | Not yet implemented. Stop and tell the user the adapter doesn't exist yet — the architecture supports it, but no `linear-prd-source` / `github-prd-source` skill has been built. Don't fall back. |
27
29
  | A file path (`@plan.md`, `./spec.md`) | Read the file as the spec; run the Plan flow's core decomposition with the file content as input. |
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: prd-ticket-coverage
3
- description: "Verifies that every requirement in a Notion PRD is covered by at least one created JIRA ticket — no silent drops. Parses the PRD into atomic items (goals, user stories, functional/non-functional requirements, acceptance criteria, important notes), maps each to the created tickets, and produces a coverage matrix and verdict (COMPLETE / COMPLETE_WITH_SCOPE_CREEP / GAPS_FOUND / NO_TICKETS_FOUND). Used by notion-prd-intake post-write to gate the Status=Ticketed transition; can also be invoked standalone for after-the-fact audits."
4
- allowed-tools: ["Skill", "mcp__claude_ai_Notion__notion-fetch", "mcp__claude_ai_Notion__notion-get-comments", "mcp__atlassian__getJiraIssue", "mcp__atlassian__searchJiraIssuesUsingJql", "mcp__atlassian__getAccessibleAtlassianResources"]
3
+ description: "Verifies that every requirement in a PRD (Notion or Confluence) is covered by at least one created JIRA ticket — no silent drops. Parses the PRD into atomic items (goals, user stories, functional/non-functional requirements, acceptance criteria, important notes), maps each to the created tickets, and produces a coverage matrix and verdict (COMPLETE / COMPLETE_WITH_SCOPE_CREEP / GAPS_FOUND / NO_TICKETS_FOUND). Used by notion-prd-intake / confluence-prd-intake post-write to gate the Ticketed transition; can also be invoked standalone for after-the-fact audits."
4
+ allowed-tools: ["Skill", "mcp__claude_ai_Notion__notion-fetch", "mcp__claude_ai_Notion__notion-get-comments", "mcp__atlassian__getConfluencePage", "mcp__atlassian__getConfluencePageDescendants", "mcp__atlassian__getConfluencePageFooterComments", "mcp__atlassian__getConfluencePageInlineComments", "mcp__atlassian__getConfluenceCommentChildren", "mcp__atlassian__getJiraIssue", "mcp__atlassian__searchJiraIssuesUsingJql", "mcp__atlassian__getAccessibleAtlassianResources"]
5
5
  ---
6
6
 
7
7
  # PRD Ticket Coverage Audit: $ARGUMENTS
@@ -9,9 +9,16 @@ allowed-tools: ["Skill", "mcp__claude_ai_Notion__notion-fetch", "mcp__claude_ai_
9
9
  `$ARGUMENTS` is one of:
10
10
 
11
11
  1. A PRD URL alone — auto-discover created tickets via the PRD's epic remote link.
12
- 2. A PRD URL plus an explicit list of ticket keys — `<PRD URL> tickets=[KEY-1,KEY-2,...]`. Use this when called from `lisa:notion-prd-intake` (which knows the keys it just created).
12
+ 2. A PRD URL plus an explicit list of ticket keys — `<PRD URL> tickets=[KEY-1,KEY-2,...]`. Use this when called from `lisa:notion-prd-intake` or `lisa:confluence-prd-intake` (which know the keys they just created).
13
13
 
14
- Verify that every atomic item in the PRD is covered by at least one of the listed/discovered JIRA tickets. The output gates whether the PRD's `Status` should remain `Ticketed` or revert to `Blocked`.
14
+ The PRD URL can be a **Notion page URL** or a **Confluence page URL**. Detect the vendor from the host:
15
+
16
+ - `notion.so` / `notion.site` → Notion. Fetch with `mcp__claude_ai_Notion__notion-fetch` (`include_discussions: true`) and `mcp__claude_ai_Notion__notion-get-comments`.
17
+ - Atlassian Confluence host (e.g. `*.atlassian.net/wiki/...`) → Confluence. Fetch with `mcp__atlassian__getConfluencePage`, `mcp__atlassian__getConfluencePageDescendants` (for child epic pages), `mcp__atlassian__getConfluencePageFooterComments`, `mcp__atlassian__getConfluencePageInlineComments`, and `mcp__atlassian__getConfluenceCommentChildren` for nested replies.
18
+
19
+ Both vendors produce the same downstream artifact-extraction and coverage-matrix logic — only the fetch surface differs. The rest of this skill is vendor-agnostic.
20
+
21
+ Verify that every atomic item in the PRD is covered by at least one of the listed/discovered JIRA tickets. The output gates whether the PRD's lifecycle should remain at `Ticketed` (Notion `Status = Ticketed`, Confluence `prd-ticketed` label) or revert to `Blocked`.
15
22
 
16
23
  ## Why this exists
17
24
 
@@ -22,12 +29,17 @@ Per-ticket gates (`lisa:jira-validate-ticket`) prove each created ticket is well
22
29
  ### Phase 1 — Resolve inputs
23
30
 
24
31
  1. Parse `$ARGUMENTS`:
25
- - PRD URL → extract page ID.
32
+ - PRD URL → detect vendor from host, extract page ID.
26
33
  - Optional `tickets=[...]` → list of explicit ticket keys.
27
- 2. Fetch the PRD via `notion-fetch` with `include_discussions: true`. Capture: title, body, child Epic pages, all comment threads.
28
- 3. If the PRD has child Epic sub-pages (a multi-epic PRD like Home revamp), fetch each in parallel with `include_discussions: true`. The audit walks the full PRD tree.
34
+ 2. Fetch the PRD using the vendor-appropriate tool surface:
35
+ - **Notion**: `notion-fetch` with `include_discussions: true`. Capture: title, body, child Epic pages, all comment threads.
36
+ - **Confluence**: `getConfluencePage` (capture title, body, labels), `getConfluencePageFooterComments` + `getConfluencePageInlineComments` (capture all comments; walk replies via `getConfluenceCommentChildren` for any thread with children).
37
+ 3. If the PRD has child Epic sub-pages (a multi-epic PRD), fetch each in parallel:
38
+ - **Notion**: `notion-fetch` per child page with `include_discussions: true`.
39
+ - **Confluence**: enumerate descendants via `getConfluencePageDescendants`, then `getConfluencePage` per child plus its comment streams.
40
+ The audit walks the full PRD tree.
29
41
  4. If `tickets=[...]` not provided, locate the JIRA epic by:
30
- - Looking for a JIRA URL in the PRD body, comments, or the PRD's most recent "Ticketed by Claude" comment posted by `lisa:notion-prd-intake`.
42
+ - Looking for a JIRA URL in the PRD body, comments, or the PRD's most recent "Ticketed by Claude" comment posted by `lisa:notion-prd-intake` / `lisa:confluence-prd-intake`.
31
43
  - Searching JIRA via `searchJiraIssuesUsingJql` for an epic whose summary or description references the PRD title or page ID.
32
44
  - If no epic found, return verdict `NO_TICKETS_FOUND` with a clear remediation — coverage cannot be assessed without the ticket set.
33
45
  5. Once the epic is known, fetch all child stories and sub-tasks via JQL: `"Epic Link" = <EPIC-KEY>` and recursively for sub-tasks.
@@ -132,7 +144,7 @@ Atomic PRD items extracted: <n>
132
144
  ### Scope-creep count: <n>
133
145
  ```
134
146
 
135
- `prd_anchor` and `prd_section` are built the same way as in `lisa:notion-to-jira` the start/end snippets locate the source heading or bullet for `selection_with_ellipsis`. Set both to `null` only when the gap is not anchored to any specific section (rare).
147
+ `prd_anchor` and `prd_section` are built the same way as in `lisa:notion-to-jira` / `lisa:confluence-to-jira`. For Notion, `prd_anchor` is the `selection_with_ellipsis` start/end snippet; for Confluence, it's the inline-comment selection text accepted by `createConfluenceInlineComment`. The downstream caller knows which vendor it's writing to and uses the right API; this skill just emits the anchor that vendor expects. Set both to `null` only when the gap is not anchored to any specific section (rare).
136
148
 
137
149
  `category` is drawn from the same fixed taxonomy used by `lisa:jira-validate-ticket` so downstream callers can apply one consistent comment-formatting policy. Most coverage gaps map to `scope` (item not represented in any ticket) or `product-clarity` (item too vague to map). Use `acceptance-criteria` for missing pass/fail conditions and `design-ux` for missing visuals.
138
150
 
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lisa-cdk",
3
- "version": "2.3.0",
3
+ "version": "2.4.0",
4
4
  "description": "AWS CDK-specific plugin",
5
5
  "author": {
6
6
  "name": "Cody Swann"
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lisa-expo",
3
- "version": "2.3.0",
3
+ "version": "2.4.0",
4
4
  "description": "Expo/React Native-specific skills, agents, rules, and MCP servers",
5
5
  "author": {
6
6
  "name": "Cody Swann"
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lisa-nestjs",
3
- "version": "2.3.0",
3
+ "version": "2.4.0",
4
4
  "description": "NestJS-specific skills (GraphQL, TypeORM) and hooks (migration write-protection)",
5
5
  "author": {
6
6
  "name": "Cody Swann"
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lisa-rails",
3
- "version": "2.3.0",
3
+ "version": "2.4.0",
4
4
  "description": "Ruby on Rails-specific hooks — RuboCop linting/formatting and ast-grep scanning on edit",
5
5
  "author": {
6
6
  "name": "Cody Swann"
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lisa-typescript",
3
- "version": "2.3.0",
3
+ "version": "2.4.0",
4
4
  "description": "TypeScript-specific hooks — Prettier formatting, ESLint linting, and ast-grep scanning on edit",
5
5
  "author": {
6
6
  "name": "Cody Swann"
@@ -0,0 +1,63 @@
1
+ ---
2
+ name: confluence-prd-intake
3
+ description: PRD intake agent for Confluence-hosted PRDs. Runs one intake cycle against a Confluence space or parent page — claims `prd-ready` PRDs (relabels to `prd-in-review`), validates each through the dry-run pipeline, and routes to `prd-blocked` (with clarifying comments) or `prd-ticketed` (with JIRA tickets created). Confluence counterpart of `notion-prd-intake`. Designed to be invoked manually via /confluence-prd-intake or autonomously via a scheduled cron.
4
+ skills:
5
+ - confluence-prd-intake
6
+ - confluence-to-jira
7
+ - jira-validate-ticket
8
+ - jira-source-artifacts
9
+ - product-walkthrough
10
+ - jira-write-ticket
11
+ - prd-ticket-coverage
12
+ ---
13
+
14
+ # PRD Intake Agent (Confluence)
15
+
16
+ You are a PRD intake agent. Your single job is to run one intake cycle against the Confluence scope (a space or a parent page) given to you, then report what happened.
17
+
18
+ This agent is the Confluence counterpart of `notion-prd-intake`. The behavior is identical apart from the source-of-truth tool surface; if you have a Notion database, use the Notion agent instead.
19
+
20
+ ## Confirmation policy
21
+
22
+ Once you have a space or parent-page URL, RUN. Do not ask the caller whether to proceed, do not preview projected scope, do not offer "proceed / skip / dry-run" choices. The caller has already authorized the run by invoking you; re-prompting defeats the purpose of a background batch. `prd-blocked` is a valid terminal state of the lifecycle, not a failure mode — large PRDs and PRDs full of open questions are exactly what this skill is for. The `confluence-prd-intake` skill defines the only legitimate early-exit conditions (missing scope, unreachable space/parent, empty Ready set); ask only when one of those applies.
23
+
24
+ ## Workflow
25
+
26
+ ### 1. Receive the scope URL or key
27
+
28
+ The invoking caller (a slash command, a scheduled cron, or a parent agent) hands you a Confluence space URL/key or a parent page URL/ID. You do not pick the scope yourself.
29
+
30
+ If no scope is provided, stop and ask. Never run intake against a default or guessed scope — the side effects (label changes, JIRA tickets created) are too high to act without an explicit target.
31
+
32
+ ### 2. Run the intake skill
33
+
34
+ Invoke the `confluence-prd-intake` skill with the scope as `$ARGUMENTS`. The skill owns the cycle logic — claim, dry-run, branch, write or comment, label transitions, summary. Do not duplicate that logic here.
35
+
36
+ Treat the skill's output as the source of truth. If it reports `prd-ticketed: 3 / prd-blocked: 1 / Errors: 0`, that's what you report.
37
+
38
+ ### 3. Surface the summary
39
+
40
+ Pass the skill's summary block through to the caller verbatim — do not paraphrase or condense. The caller (often a human running `/confluence-prd-intake` ad-hoc, or a scheduled cron) needs the structured record:
41
+
42
+ - Total processed
43
+ - Per-PRD outcomes (`prd-ticketed` → which tickets created; `prd-blocked` → how many gate failures; Errors → reason)
44
+ - JIRA ticket count
45
+
46
+ If the cycle errored before processing any PRDs (e.g. space unreachable, missing config, label convention not yet adopted), surface the failure cause in plain language and stop.
47
+
48
+ ### 4. Suggest next actions when warranted
49
+
50
+ After a successful cycle, if any PRDs ended in `prd-blocked`, mention to the caller that those PRDs need product attention before they can be re-ticketed. Do not auto-notify product — Confluence comments on the PRDs are the channel; the caller decides whether to ping anyone.
51
+
52
+ When reporting `prd-blocked` outcomes, distinguish the cause: **pre-write gate failure** (per-ticket validator caught a problem before any tickets were created) vs **post-write coverage gap** (tickets were created and remain in JIRA, but the PRD has uncovered requirements that the next intake cycle will address). Both result in `prd-blocked`, but the implication for product is different — coverage gaps mean some tickets are already real and product should not re-author the PRD from scratch.
53
+
54
+ If all PRDs ended in `prd-ticketed` with coverage `COMPLETE`, mention that the next step is for product to monitor the created tickets and apply the `prd-shipped` label after delivery. If any are `COMPLETE_WITH_SCOPE_CREEP`, point that out so product can review the flagged tickets.
55
+
56
+ ## Rules
57
+
58
+ - **Never run a cycle without an explicit scope.** Side effects are too high to default.
59
+ - **Never modify the lifecycle**: only `prd-ready → prd-in-review → prd-blocked|prd-ticketed`. Never touch `prd-draft` or `prd-shipped`. Never invent new labels.
60
+ - **Never write JIRA tickets directly.** All writes go through the skill chain (intake → confluence-to-jira → jira-write-ticket).
61
+ - **Never edit a PRD's body.** Communication with product happens only via Confluence comments on the PRD.
62
+ - **Never start a second cycle while one is in flight against the same scope.** Serial execution; the scheduling layer is responsible for not double-firing.
63
+ - **Stop and surface failures rather than retry-loop.** If `confluence-to-jira` returns an error, the skill records it under `Errors` in the summary; pass that through.
@@ -1,6 +1,6 @@
1
1
  ---
2
- description: "Vendor-agnostic batch scanner for Status=Ready queues. Notion PRD database URL → finds Ready PRDs and runs lisa:plan per item. JIRA project key or JQL → finds Ready tickets and runs lisa:implement per item. Designed as the cron target for /schedule."
3
- argument-hint: "<Notion-PRD-database-URL | JIRA-project-key | JQL-filter>"
2
+ description: "Vendor-agnostic batch scanner for Ready queues. Notion PRD database URL → finds Status=Ready PRDs and runs lisa:plan per item. Confluence space or parent-page URL → finds prd-ready PRDs and runs lisa:plan per item. JIRA project key or JQL → finds Ready tickets and runs lisa:implement per item. Designed as the cron target for /schedule."
3
+ argument-hint: "<Notion-PRD-database-URL | Confluence-space-URL | Confluence-parent-page-URL | JIRA-project-key | JQL-filter>"
4
4
  ---
5
5
 
6
- Use the /lisa:intake skill to scan the queue for Status=Ready items and dispatch each one through the appropriate single-item lifecycle skill. $ARGUMENTS
6
+ Use the /lisa:intake skill to scan the queue for Ready items and dispatch each one through the appropriate single-item lifecycle skill. $ARGUMENTS