panopticon-cli 0.4.32 → 0.5.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.
- package/README.md +96 -210
- package/dist/{agents-BDFHF4T3.js → agents-E43Y3HNU.js} +10 -7
- package/dist/chunk-7SN4L4PH.js +150 -0
- package/dist/chunk-7SN4L4PH.js.map +1 -0
- package/dist/{chunk-2NIAOCIC.js → chunk-AAFQANKW.js} +358 -97
- package/dist/chunk-AAFQANKW.js.map +1 -0
- package/dist/chunk-AQXETQHW.js +113 -0
- package/dist/chunk-AQXETQHW.js.map +1 -0
- package/dist/chunk-B3PF6JPQ.js +212 -0
- package/dist/chunk-B3PF6JPQ.js.map +1 -0
- package/dist/chunk-CFCUOV3Q.js +669 -0
- package/dist/chunk-CFCUOV3Q.js.map +1 -0
- package/dist/chunk-CWELWPWQ.js +32 -0
- package/dist/chunk-CWELWPWQ.js.map +1 -0
- package/dist/chunk-DI7ABPNQ.js +352 -0
- package/dist/chunk-DI7ABPNQ.js.map +1 -0
- package/dist/{chunk-VU4FLXV5.js → chunk-FQ66DECN.js} +31 -4
- package/dist/chunk-FQ66DECN.js.map +1 -0
- package/dist/{chunk-VIWUCJ4V.js → chunk-FTCPTHIJ.js} +57 -432
- package/dist/chunk-FTCPTHIJ.js.map +1 -0
- package/dist/{review-status-GWQYY77L.js → chunk-GFP3PIPB.js} +14 -7
- package/dist/chunk-GFP3PIPB.js.map +1 -0
- package/dist/chunk-GR6ZZMCX.js +816 -0
- package/dist/chunk-GR6ZZMCX.js.map +1 -0
- package/dist/chunk-HJSM6E6U.js +1038 -0
- package/dist/chunk-HJSM6E6U.js.map +1 -0
- package/dist/{chunk-XP2DXWYP.js → chunk-HZT2AOPN.js} +164 -39
- package/dist/chunk-HZT2AOPN.js.map +1 -0
- package/dist/chunk-JQBV3Q2W.js +29 -0
- package/dist/chunk-JQBV3Q2W.js.map +1 -0
- package/dist/{chunk-BWGFN44T.js → chunk-JT4O4YVM.js} +28 -16
- package/dist/chunk-JT4O4YVM.js.map +1 -0
- package/dist/chunk-NTO3EDB3.js +600 -0
- package/dist/chunk-NTO3EDB3.js.map +1 -0
- package/dist/{chunk-JY7R7V4G.js → chunk-OMNXYPXC.js} +2 -2
- package/dist/chunk-OMNXYPXC.js.map +1 -0
- package/dist/chunk-PELXV435.js +215 -0
- package/dist/chunk-PELXV435.js.map +1 -0
- package/dist/chunk-PPRFKTVC.js +154 -0
- package/dist/chunk-PPRFKTVC.js.map +1 -0
- package/dist/chunk-WQG2TYCB.js +677 -0
- package/dist/chunk-WQG2TYCB.js.map +1 -0
- package/dist/{chunk-HCTJFIJJ.js → chunk-YLPSQAM2.js} +2 -2
- package/dist/{chunk-HCTJFIJJ.js.map → chunk-YLPSQAM2.js.map} +1 -1
- package/dist/{chunk-6HXKTOD7.js → chunk-ZTFNYOC7.js} +53 -38
- package/dist/chunk-ZTFNYOC7.js.map +1 -0
- package/dist/cli/index.js +5103 -3165
- package/dist/cli/index.js.map +1 -1
- package/dist/{config-BOAMSKTF.js → config-4CJNUE3O.js} +7 -3
- package/dist/dashboard/prompts/merge-agent.md +217 -0
- package/dist/dashboard/prompts/review-agent.md +409 -0
- package/dist/dashboard/prompts/sync-main.md +84 -0
- package/dist/dashboard/prompts/test-agent.md +283 -0
- package/dist/dashboard/prompts/work-agent.md +249 -0
- package/dist/dashboard/public/assets/index-BxpjweAL.css +32 -0
- package/dist/dashboard/public/assets/index-DQHkwvvJ.js +743 -0
- package/dist/dashboard/public/index.html +2 -2
- package/dist/dashboard/server.js +17619 -4044
- package/dist/{dns-L3L2BB27.js → dns-7BDJSD3E.js} +4 -2
- package/dist/{feedback-writer-AAKF5BTK.js → feedback-writer-LVZ5TFYZ.js} +8 -4
- package/dist/feedback-writer-LVZ5TFYZ.js.map +1 -0
- package/dist/hume-WMAUBBV2.js +13 -0
- package/dist/index.d.ts +162 -40
- package/dist/index.js +67 -23
- package/dist/index.js.map +1 -1
- package/dist/{projects-VXRUCMLM.js → projects-JEIVIYC6.js} +3 -3
- package/dist/rally-RKFSWC7E.js +10 -0
- package/dist/{remote-agents-Z3R2A5BN.js → remote-agents-TFSMW7GN.js} +2 -2
- package/dist/{remote-workspace-2G6V2KNP.js → remote-workspace-AHVHQEES.js} +8 -8
- package/dist/review-status-EPFG4XM7.js +19 -0
- package/dist/shadow-state-5MDP6YXH.js +30 -0
- package/dist/shadow-state-5MDP6YXH.js.map +1 -0
- package/dist/{specialist-context-N32QBNNQ.js → specialist-context-ZC6A4M3I.js} +8 -7
- package/dist/{specialist-context-N32QBNNQ.js.map → specialist-context-ZC6A4M3I.js.map} +1 -1
- package/dist/{specialist-logs-GF3YV4KL.js → specialist-logs-KLGJCEUL.js} +7 -6
- package/dist/specialist-logs-KLGJCEUL.js.map +1 -0
- package/dist/{specialists-JBIW6MP4.js → specialists-O4HWDJL5.js} +7 -6
- package/dist/specialists-O4HWDJL5.js.map +1 -0
- package/dist/tldr-daemon-T3THOUGT.js +21 -0
- package/dist/tldr-daemon-T3THOUGT.js.map +1 -0
- package/dist/traefik-QN7R5I6V.js +19 -0
- package/dist/traefik-QN7R5I6V.js.map +1 -0
- package/dist/tunnel-W2GZBLEV.js +13 -0
- package/dist/tunnel-W2GZBLEV.js.map +1 -0
- package/dist/workspace-manager-IE4JL2JP.js +22 -0
- package/dist/workspace-manager-IE4JL2JP.js.map +1 -0
- package/package.json +2 -2
- package/scripts/heartbeat-hook +37 -10
- package/scripts/patches/llm-tldr-tsx-support.py +109 -0
- package/scripts/pre-tool-hook +26 -15
- package/scripts/record-cost-event.js +177 -43
- package/scripts/record-cost-event.ts +87 -3
- package/scripts/statusline.sh +169 -0
- package/scripts/stop-hook +21 -11
- package/scripts/tldr-post-edit +72 -0
- package/scripts/tldr-read-enforcer +275 -0
- package/scripts/work-agent-stop-hook +137 -0
- package/skills/check-merged/SKILL.md +143 -0
- package/skills/crash-investigation/SKILL.md +301 -0
- package/skills/github-cli/SKILL.md +185 -0
- package/skills/myn-standards/SKILL.md +351 -0
- package/skills/pan-reopen/SKILL.md +65 -0
- package/skills/pan-sync-main/SKILL.md +87 -0
- package/skills/pan-tldr/SKILL.md +149 -0
- package/skills/react-best-practices/SKILL.md +125 -0
- package/skills/spec-readiness/REPORT-TEMPLATE.md +158 -0
- package/skills/spec-readiness/SCORING-REFERENCE.md +369 -0
- package/skills/spec-readiness/SKILL.md +400 -0
- package/skills/spec-readiness-setup/SKILL.md +361 -0
- package/skills/workspace-status/SKILL.md +56 -0
- package/skills/write-spec/SKILL.md +138 -0
- package/templates/traefik/dynamic/panopticon.yml.template +0 -5
- package/templates/traefik/traefik.yml +0 -8
- package/dist/chunk-2NIAOCIC.js.map +0 -1
- package/dist/chunk-3XAB4IXF.js +0 -51
- package/dist/chunk-3XAB4IXF.js.map +0 -1
- package/dist/chunk-6HXKTOD7.js.map +0 -1
- package/dist/chunk-BBCUK6N2.js +0 -241
- package/dist/chunk-BBCUK6N2.js.map +0 -1
- package/dist/chunk-BWGFN44T.js.map +0 -1
- package/dist/chunk-ELK6Q7QI.js +0 -545
- package/dist/chunk-ELK6Q7QI.js.map +0 -1
- package/dist/chunk-JY7R7V4G.js.map +0 -1
- package/dist/chunk-LYSBSZYV.js +0 -1523
- package/dist/chunk-LYSBSZYV.js.map +0 -1
- package/dist/chunk-VIWUCJ4V.js.map +0 -1
- package/dist/chunk-VU4FLXV5.js.map +0 -1
- package/dist/chunk-XP2DXWYP.js.map +0 -1
- package/dist/dashboard/public/assets/index-C7X6LP5Z.css +0 -32
- package/dist/dashboard/public/assets/index-ClYqpcAJ.js +0 -645
- package/dist/feedback-writer-AAKF5BTK.js.map +0 -1
- package/dist/review-status-GWQYY77L.js.map +0 -1
- package/dist/traefik-CUJM6K5Z.js +0 -12
- /package/dist/{agents-BDFHF4T3.js.map → agents-E43Y3HNU.js.map} +0 -0
- /package/dist/{config-BOAMSKTF.js.map → config-4CJNUE3O.js.map} +0 -0
- /package/dist/{dns-L3L2BB27.js.map → dns-7BDJSD3E.js.map} +0 -0
- /package/dist/{projects-VXRUCMLM.js.map → hume-WMAUBBV2.js.map} +0 -0
- /package/dist/{remote-agents-Z3R2A5BN.js.map → projects-JEIVIYC6.js.map} +0 -0
- /package/dist/{specialist-logs-GF3YV4KL.js.map → rally-RKFSWC7E.js.map} +0 -0
- /package/dist/{specialists-JBIW6MP4.js.map → remote-agents-TFSMW7GN.js.map} +0 -0
- /package/dist/{remote-workspace-2G6V2KNP.js.map → remote-workspace-AHVHQEES.js.map} +0 -0
- /package/dist/{traefik-CUJM6K5Z.js.map → review-status-EPFG4XM7.js.map} +0 -0
|
@@ -0,0 +1,400 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: spec-readiness
|
|
3
|
+
description: >
|
|
4
|
+
Evaluate an issue or epic's requirements readiness before development begins.
|
|
5
|
+
Produces a scored report (0-100) across 5 dimensions with detailed findings,
|
|
6
|
+
actionable blockers, and a JSON sidecar for dashboards. Works with any issue
|
|
7
|
+
tracker (Linear, GitHub, GitLab, Rally, Jira). Use a wrapper skill to customize
|
|
8
|
+
branding and tracker-specific field mappings.
|
|
9
|
+
triggers:
|
|
10
|
+
- spec readiness
|
|
11
|
+
- requirements readiness
|
|
12
|
+
- spec score
|
|
13
|
+
- prd score
|
|
14
|
+
- requirements review
|
|
15
|
+
- spec review
|
|
16
|
+
- is this ready
|
|
17
|
+
- readiness report
|
|
18
|
+
- readiness score
|
|
19
|
+
- readiness check
|
|
20
|
+
- how ready is
|
|
21
|
+
- requirements assessment
|
|
22
|
+
- feature readiness
|
|
23
|
+
- spec quality
|
|
24
|
+
- prd readiness
|
|
25
|
+
- ready for build
|
|
26
|
+
- ready for dev
|
|
27
|
+
allowed-tools:
|
|
28
|
+
- Read
|
|
29
|
+
- Write
|
|
30
|
+
- Bash
|
|
31
|
+
- WebFetch
|
|
32
|
+
- Task
|
|
33
|
+
---
|
|
34
|
+
|
|
35
|
+
# Spec Readiness — Orchestrator
|
|
36
|
+
|
|
37
|
+
## Philosophy
|
|
38
|
+
|
|
39
|
+
The most important work on a feature is the PRD/spec, not the implementation. Every major overrun traces back to **requirements incomplete when development started.** This skill measures requirements maturity as a **leading indicator**.
|
|
40
|
+
|
|
41
|
+
## Wrapper Architecture
|
|
42
|
+
|
|
43
|
+
This is the **core scoring engine**. It is designed to be wrapped by a thin customization layer.
|
|
44
|
+
|
|
45
|
+
### How Wrapping Works
|
|
46
|
+
|
|
47
|
+
A wrapper skill overrides branding, tracker bindings, and field mappings by providing a `config.yaml`:
|
|
48
|
+
|
|
49
|
+
```
|
|
50
|
+
1. Check: Does ~/.panopticon/skills/spec-readiness-*/config.yaml exist?
|
|
51
|
+
2. If yes: Load tracker bindings, field mappings, branding, conventions
|
|
52
|
+
3. If no: Use defaults (generic branding, auto-detect tracker)
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
### Wrapper Config Schema
|
|
56
|
+
|
|
57
|
+
```yaml
|
|
58
|
+
# ~/.panopticon/skills/spec-readiness-mycompany/config.yaml
|
|
59
|
+
tracker:
|
|
60
|
+
type: linear | github | gitlab | rally | jira
|
|
61
|
+
tools:
|
|
62
|
+
get_issue: "mcp__linear__get_issue"
|
|
63
|
+
list_child_issues: "mcp__linear__list_issues"
|
|
64
|
+
get_comments: "mcp__linear__list_comments"
|
|
65
|
+
search_issues: "mcp__linear__list_issues"
|
|
66
|
+
get_relations: "mcp__linear__get_issue" # with includeRelations=true
|
|
67
|
+
get_activity_log: null # not available for Linear
|
|
68
|
+
fields:
|
|
69
|
+
identifier: "identifier"
|
|
70
|
+
estimate: "estimate"
|
|
71
|
+
status: "status"
|
|
72
|
+
parent_field: "parentId"
|
|
73
|
+
customer_directed_label: null
|
|
74
|
+
overflow_markers: []
|
|
75
|
+
|
|
76
|
+
branding:
|
|
77
|
+
company_name: "My Company"
|
|
78
|
+
primary_color: "#2563eb"
|
|
79
|
+
stripe_color: "#2563eb"
|
|
80
|
+
footer_text: null
|
|
81
|
+
logo_url: null
|
|
82
|
+
eml_from: null # From address for EML reports (default: noreply@example.com)
|
|
83
|
+
eml_to: null # To address for EML reports (default: noreply@example.com)
|
|
84
|
+
|
|
85
|
+
conventions:
|
|
86
|
+
spike_patterns: ["spike", "investigation", "discovery", "POC", "prototype", "analysis"]
|
|
87
|
+
overflow_markers: ["[Unfinished]", "[Continued]"]
|
|
88
|
+
estimate_field_custom: null
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
---
|
|
92
|
+
|
|
93
|
+
## When to Use
|
|
94
|
+
|
|
95
|
+
- Before sprint planning: "Is MIN-704 ready for development?"
|
|
96
|
+
- During quarterly planning: Score all issues to identify which need more spec work
|
|
97
|
+
- In status reports: Include readiness scores alongside implementation progress
|
|
98
|
+
- After an issue is described but before sub-tasks are created
|
|
99
|
+
- As a health check during development: Is the spec still evolving (bad sign)?
|
|
100
|
+
|
|
101
|
+
## Arguments
|
|
102
|
+
|
|
103
|
+
**Required:** An issue identifier (e.g., `MIN-704`, `#123`, `PROJ-456`, `PAN-47`)
|
|
104
|
+
|
|
105
|
+
**Optional:**
|
|
106
|
+
- `--output-dir <path>` — Override default output directory (default: current directory)
|
|
107
|
+
- `--eml` — Generate `.eml` file (email-ready, opens in mail client) instead of `.html`
|
|
108
|
+
- `--json-only` — Skip HTML/EML report, produce only JSON sidecar
|
|
109
|
+
- `--verbose` — Include full issue description text in findings
|
|
110
|
+
- `--wrapper <name>` — Explicitly select a wrapper (default: auto-detect)
|
|
111
|
+
|
|
112
|
+
## Scoring Model: 5 Dimensions, 100 Points Total
|
|
113
|
+
|
|
114
|
+
| Score | Label | Color |
|
|
115
|
+
|-------|-------|-------|
|
|
116
|
+
| 86-100 | **Ready for Build** | Green |
|
|
117
|
+
| 70-85 | **Mostly Ready** | Green |
|
|
118
|
+
| 40-69 | **Partial / Risky** | Yellow |
|
|
119
|
+
| 0-39 | **Not Ready** | Red |
|
|
120
|
+
|
|
121
|
+
| Dimension | What It Measures |
|
|
122
|
+
|-----------|-----------------|
|
|
123
|
+
| 1. Requirements Clarity (0-20) | Is the spec complete and unambiguous? |
|
|
124
|
+
| 2. Technical Discovery (0-20) | Have technical unknowns been investigated? |
|
|
125
|
+
| 3. Scope & Decomposition (0-20) | Is the issue right-sized with clear boundaries? |
|
|
126
|
+
| 4. Dependencies & Prerequisites (0-20) | Is the critical path mapped? |
|
|
127
|
+
| 5. Edge Cases & Test Strategy (0-20) | Are failure modes documented? |
|
|
128
|
+
|
|
129
|
+
Detailed scoring criteria, deduction tables, and calibration data are in `SCORING-REFERENCE.md` (same directory as this file).
|
|
130
|
+
HTML report structure is in `REPORT-TEMPLATE.md` (same directory as this file).
|
|
131
|
+
|
|
132
|
+
---
|
|
133
|
+
|
|
134
|
+
## Tracker Abstraction Layer
|
|
135
|
+
|
|
136
|
+
This skill works with any issue tracker. The data-fetching layer adapts based on tracker type.
|
|
137
|
+
|
|
138
|
+
### Generic Operations
|
|
139
|
+
|
|
140
|
+
| Operation | What It Does |
|
|
141
|
+
|-----------|-------------|
|
|
142
|
+
| `get_issue(id)` | Fetch the parent issue with description, status, metadata |
|
|
143
|
+
| `get_child_issues(parentId)` | Fetch all child/sub-issues |
|
|
144
|
+
| `get_comments(issueId)` | Fetch discussion threads |
|
|
145
|
+
| `get_activity_log(issueId)` | Fetch edit/revision history |
|
|
146
|
+
| `search_issues(filters)` | Search for related bugs/issues |
|
|
147
|
+
| `get_relations(issueId)` | Fetch blocking/blocked-by links |
|
|
148
|
+
|
|
149
|
+
### Tracker-Specific Mappings
|
|
150
|
+
|
|
151
|
+
**Linear:**
|
|
152
|
+
```
|
|
153
|
+
get_issue → mcp__linear__get_issue(id, includeRelations=true)
|
|
154
|
+
get_child_issues → mcp__linear__list_issues(parentId=<id>)
|
|
155
|
+
get_comments → mcp__linear__list_comments(issueId=<id>)
|
|
156
|
+
get_activity_log → Not available — skip edit churn, note in findings
|
|
157
|
+
search_issues → mcp__linear__list_issues(query=..., label="Bug")
|
|
158
|
+
get_relations → Included in get_issue with includeRelations=true
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
**GitHub:**
|
|
162
|
+
```
|
|
163
|
+
get_issue → gh issue view <number> --repo {repo} --json title,body,state,labels,milestone,assignees
|
|
164
|
+
get_child_issues → gh issue list --repo {repo} --search "parent:<number>" --json number,title,body,state,createdAt
|
|
165
|
+
get_comments → gh issue view <number> --repo {repo} --json comments
|
|
166
|
+
get_activity_log → gh api repos/{owner}/{repo}/issues/<number>/events
|
|
167
|
+
search_issues → gh issue list --repo {repo} --label bug --search "<query>"
|
|
168
|
+
get_relations → Parse "blocked by" / "depends on" from issue body
|
|
169
|
+
```
|
|
170
|
+
|
|
171
|
+
**GitLab:**
|
|
172
|
+
```
|
|
173
|
+
get_issue → glab issue view <number>
|
|
174
|
+
get_child_issues → glab api /projects/:id/issues?parent_id=<id>
|
|
175
|
+
get_comments → glab issue note list <number>
|
|
176
|
+
get_activity_log → glab api /projects/:id/issues/<number>/resource_state_events
|
|
177
|
+
search_issues → glab issue list --label bug --search "<query>"
|
|
178
|
+
get_relations → glab api /projects/:id/issues/<number>/links
|
|
179
|
+
```
|
|
180
|
+
|
|
181
|
+
**Rally:**
|
|
182
|
+
```
|
|
183
|
+
get_issue → mcp__rally__get_feature(FormattedID) or mcp__rally__get_story
|
|
184
|
+
get_child_issues → From _collections.UserStories in feature response
|
|
185
|
+
get_comments → From Discussion collection in issue response
|
|
186
|
+
get_activity_log → mcp__rally__get_revision_history(FormattedID)
|
|
187
|
+
search_issues → mcp__rally__search_work_items(work_item_type=Defect)
|
|
188
|
+
get_relations → From Predecessors/Successors collections
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
**Jira:**
|
|
192
|
+
```
|
|
193
|
+
get_issue → curl $JIRA_URL/rest/api/3/issue/<key>
|
|
194
|
+
get_child_issues → JQL: "parent = <key>" or "Epic Link = <key>"
|
|
195
|
+
get_comments → /rest/api/3/issue/<key>/comment
|
|
196
|
+
get_activity_log → /rest/api/3/issue/<key>/changelog
|
|
197
|
+
search_issues → JQL search
|
|
198
|
+
get_relations → /rest/api/3/issue/<key>?fields=issuelinks
|
|
199
|
+
```
|
|
200
|
+
|
|
201
|
+
### Auto-Detection (when no wrapper config)
|
|
202
|
+
|
|
203
|
+
1. Check if `mcp__linear__*` tools are available → use Linear
|
|
204
|
+
2. Check if `mcp__rally__*` tools are available → use Rally
|
|
205
|
+
3. Check if `gh` CLI is authenticated → use GitHub
|
|
206
|
+
4. Check if `glab` CLI is authenticated → use GitLab
|
|
207
|
+
5. If none detected, ask the user
|
|
208
|
+
|
|
209
|
+
---
|
|
210
|
+
|
|
211
|
+
## Workflow: Orchestrator + Subagents
|
|
212
|
+
|
|
213
|
+
**IMPORTANT:** This skill uses Task subagents to avoid running out of context. The main agent NEVER fetches individual child issues or large tracker payloads directly. All heavy data fetching happens inside subagents with isolated context windows.
|
|
214
|
+
|
|
215
|
+
### Step 1: Parse Arguments & Load Configuration
|
|
216
|
+
|
|
217
|
+
1. Extract the issue identifier from the user's request
|
|
218
|
+
2. Set output directory (default: current directory)
|
|
219
|
+
3. Look for wrapper config at `~/.panopticon/skills/spec-readiness-*/config.yaml`
|
|
220
|
+
4. If no wrapper, auto-detect tracker (see Auto-Detection above)
|
|
221
|
+
5. Build the tool mapping for the detected tracker
|
|
222
|
+
|
|
223
|
+
### Step 2: Fetch Issue Metadata (main agent — small payload)
|
|
224
|
+
|
|
225
|
+
Call the tracker's `get_issue` operation to get: Title, Description, Status, Owner/Assignee, Project, Milestone/Release, Estimate, Child Issue Count.
|
|
226
|
+
|
|
227
|
+
This single call is small enough for the main context. Note the Project name and Description — subagents need them.
|
|
228
|
+
|
|
229
|
+
### Step 3: Launch 3 Analysis Subagents IN PARALLEL
|
|
230
|
+
|
|
231
|
+
Use the `Task` tool with `subagent_type: "general-purpose"` for all three. **Launch all three in a single message** so they run concurrently.
|
|
232
|
+
|
|
233
|
+
Each subagent prompt MUST include:
|
|
234
|
+
- The tracker type and specific tool instructions (from Step 1)
|
|
235
|
+
- The issue identifier, title, project, and description (from Step 2)
|
|
236
|
+
- Instruction to read `SCORING-REFERENCE.md` from the skill directory for scoring criteria
|
|
237
|
+
|
|
238
|
+
---
|
|
239
|
+
|
|
240
|
+
#### Subagent A — "Issue & Edit History Analysis"
|
|
241
|
+
|
|
242
|
+
Scores **Dimension 1** (Requirements Clarity) and **Dimension 3** (Scope & Decomposition).
|
|
243
|
+
|
|
244
|
+
Prompt must include: identifier, title, project, description, notes (from Step 2), and tracker tool instructions.
|
|
245
|
+
|
|
246
|
+
Tell the subagent to:
|
|
247
|
+
1. Read `~/.claude/skills/spec-readiness/SCORING-REFERENCE.md` (or `~/.panopticon/skills/spec-readiness/SCORING-REFERENCE.md`) for criteria
|
|
248
|
+
2. Fetch edit/activity history for the issue (using the tracker's `get_activity_log` tool — or note if unavailable)
|
|
249
|
+
3. Fetch child issue list (using the tracker's `get_child_issues` tool)
|
|
250
|
+
4. **Scan description for external document links** (BRD, PRD, spec docs — Google Docs, Confluence, SharePoint, Notion, attached files). If a URL is found and appears accessible, use WebFetch to analyze coverage and cross-reference with the description. If no external document found and issue is customer-directed: note for deduction.
|
|
251
|
+
5. Analyze description + edit history for: open questions, churn, late edits, external doc links, scope markers, child count, carryover rate, creation date spread
|
|
252
|
+
6. Return in this format (max 120 lines, no raw tracker JSON):
|
|
253
|
+
|
|
254
|
+
```
|
|
255
|
+
## Issue Metadata
|
|
256
|
+
- Title / Identifier / Project / Milestone / Owner / ChildCount / Estimate / EditCount
|
|
257
|
+
|
|
258
|
+
## External Documents
|
|
259
|
+
- Found: yes/no | Type: PRD/BRD/spec | Accessible: yes/no | Attached before dev: yes/no
|
|
260
|
+
- Coverage summary (if fetched)
|
|
261
|
+
- Gaps identified (if fetched)
|
|
262
|
+
|
|
263
|
+
## Dimension 1: Requirements Clarity (Score: X/20)
|
|
264
|
+
### Summary
|
|
265
|
+
### Findings
|
|
266
|
+
1. [DEDUCTION -N] Finding | Source: ... | Recommendation: ...
|
|
267
|
+
|
|
268
|
+
## Dimension 3: Scope & Decomposition (Score: X/20)
|
|
269
|
+
### Summary
|
|
270
|
+
### Findings
|
|
271
|
+
|
|
272
|
+
## Child Issue List
|
|
273
|
+
| ID | Title | Status | CreationDate |
|
|
274
|
+
```
|
|
275
|
+
|
|
276
|
+
---
|
|
277
|
+
|
|
278
|
+
#### Subagent B — "Child Issue & Dependency Analysis"
|
|
279
|
+
|
|
280
|
+
Scores **Dimension 2** (Technical Discovery), **Dimension 4** (Dependencies), **Dimension 5** (Edge Cases & Test Strategy).
|
|
281
|
+
|
|
282
|
+
Prompt must include: identifier, project, description (for technical detail analysis), and tracker tool instructions.
|
|
283
|
+
|
|
284
|
+
Tell the subagent to:
|
|
285
|
+
1. Read `~/.claude/skills/spec-readiness/SCORING-REFERENCE.md` for criteria
|
|
286
|
+
2. Fetch child issues with dependency/relation fields (using the tracker's `get_child_issues` and `get_relations` tools)
|
|
287
|
+
3. Spot-check 3-4 child issues in detail: any spike/investigation, first 2 implementation issues, any QA/test issue
|
|
288
|
+
4. Fetch comments/discussion on the parent issue (using the tracker's `get_comments` tool) — look for developer questions indicating requirements gaps
|
|
289
|
+
5. Analyze for: spikes (timing, gating), technical detail in description, infrastructure sequencing, dependency links, acceptance criteria quality, edge case language
|
|
290
|
+
6. Return in this format (max 120 lines, no raw tracker JSON):
|
|
291
|
+
|
|
292
|
+
```
|
|
293
|
+
## Dimension 2: Technical Discovery (Score: X/20)
|
|
294
|
+
### Summary
|
|
295
|
+
### Findings
|
|
296
|
+
|
|
297
|
+
## Dimension 4: Dependencies & Prerequisites (Score: X/20)
|
|
298
|
+
### Summary
|
|
299
|
+
### Findings
|
|
300
|
+
|
|
301
|
+
## Dimension 5: Edge Cases & Test Strategy (Score: X/20)
|
|
302
|
+
### Summary
|
|
303
|
+
### Findings
|
|
304
|
+
|
|
305
|
+
## Child Issue Assessments
|
|
306
|
+
| ID | Title | Status | Has AC | AC Quality | Notes |
|
|
307
|
+
```
|
|
308
|
+
|
|
309
|
+
---
|
|
310
|
+
|
|
311
|
+
#### Subagent C — "Bug & Risk Analysis"
|
|
312
|
+
|
|
313
|
+
Finds bugs and risks that feed into Dimension 5 scoring.
|
|
314
|
+
|
|
315
|
+
Prompt must include: identifier, project, and tracker tool instructions.
|
|
316
|
+
|
|
317
|
+
Tell the subagent to:
|
|
318
|
+
1. Search for bugs/defects related to this issue or its children (using the tracker's `search_issues` tool with bug/defect filter)
|
|
319
|
+
2. Analyze: bugs filed during development, "missing config" bugs, bugs indicating edge cases discovered in execution
|
|
320
|
+
3. Return in this format (max 50 lines):
|
|
321
|
+
|
|
322
|
+
```
|
|
323
|
+
## Bug Analysis
|
|
324
|
+
- Total bugs found / related to this issue / missed edge cases / bugs during active dev
|
|
325
|
+
|
|
326
|
+
## Impact on Dimension 5 Scoring
|
|
327
|
+
- [DEDUCTION -N] or [BONUS +N] with source
|
|
328
|
+
```
|
|
329
|
+
|
|
330
|
+
---
|
|
331
|
+
|
|
332
|
+
### Step 4: Assemble Scores
|
|
333
|
+
|
|
334
|
+
The main agent receives ~160-290 lines of structured findings from the three subagents (instead of thousands of lines of raw tracker data).
|
|
335
|
+
|
|
336
|
+
1. Extract dimension scores from Subagents A and B
|
|
337
|
+
2. Apply any additional deductions/bonuses from Subagent C to Dimension 5
|
|
338
|
+
3. Clamp all scores to 0-20
|
|
339
|
+
4. Calculate overall score = sum of 5 dimensions
|
|
340
|
+
5. Determine status label and color from the scoring table
|
|
341
|
+
|
|
342
|
+
### Step 5: Generate Top Blockers
|
|
343
|
+
|
|
344
|
+
From all findings with negative impact, select the 3-5 highest-impact items. Phrase as actionable:
|
|
345
|
+
- "Resolve 3 open questions in description to improve Requirements Clarity by up to 6 points"
|
|
346
|
+
- "Add a gating spike issue before the next sprint to improve Technical Discovery by up to 8 points"
|
|
347
|
+
|
|
348
|
+
### Step 6: Launch Report Generation Subagent
|
|
349
|
+
|
|
350
|
+
Use `Task` tool with `subagent_type: "general-purpose"`. Prompt must include all assembled scores, findings, child assessments, external document analysis, issue metadata, and top blockers. Also include the wrapper branding config (if any) and the output format: **HTML** (default) or **EML** (if `--eml` flag was used). Tell the subagent to:
|
|
351
|
+
1. Read `REPORT-TEMPLATE.md` from the skill directory for report structure (includes both HTML and EML format specs)
|
|
352
|
+
2. Read the "JSON Sidecar Schema" section from `SCORING-REFERENCE.md` in the skill directory
|
|
353
|
+
3. If HTML format: Write to `{output-dir}/spec-readiness-{identifier}.html`
|
|
354
|
+
If EML format: Write to `{output-dir}/spec-readiness-{identifier}.eml` (with MIME headers, email-safe inline CSS)
|
|
355
|
+
4. Always write JSON to `{output-dir}/spec-readiness-{identifier}.json`
|
|
356
|
+
5. Open the report file (HTML opens in browser, EML opens in mail client)
|
|
357
|
+
6. Return the file paths
|
|
358
|
+
|
|
359
|
+
### Step 7: Report to User
|
|
360
|
+
|
|
361
|
+
Tell the user:
|
|
362
|
+
- Where both files were saved
|
|
363
|
+
- The overall score and status
|
|
364
|
+
- The top 3 blockers
|
|
365
|
+
- Suggest next action (e.g., "To improve this score, start by resolving the 3 open questions in the description")
|
|
366
|
+
|
|
367
|
+
---
|
|
368
|
+
|
|
369
|
+
## Integration with Other Skills
|
|
370
|
+
|
|
371
|
+
Other skills can read the JSON sidecar to include readiness scores:
|
|
372
|
+
|
|
373
|
+
```
|
|
374
|
+
Read spec-readiness-{identifier}.json
|
|
375
|
+
Extract: .score, .status, .statusColor, .topBlockers[0..2]
|
|
376
|
+
```
|
|
377
|
+
|
|
378
|
+
Display in roll-up tables:
|
|
379
|
+
|
|
380
|
+
| Issue | Readiness | Score | Top Blocker |
|
|
381
|
+
|-------|-----------|-------|-------------|
|
|
382
|
+
| MIN-704 — MCP Code Mode | Mostly Ready | 74/100 | No dependency links mapped |
|
|
383
|
+
| PAN-47 — PRD Enforcement | Ready for Build | 88/100 | — |
|
|
384
|
+
|
|
385
|
+
---
|
|
386
|
+
|
|
387
|
+
## Example Usage
|
|
388
|
+
|
|
389
|
+
```
|
|
390
|
+
spec readiness MIN-704
|
|
391
|
+
how ready is #123
|
|
392
|
+
requirements review PAN-47
|
|
393
|
+
readiness check for all features in Q1
|
|
394
|
+
```
|
|
395
|
+
|
|
396
|
+
For batch scoring (e.g., "score all issues in current cycle"):
|
|
397
|
+
1. Search tracker for issues in the target milestone/cycle
|
|
398
|
+
2. Run readiness assessment on each
|
|
399
|
+
3. Produce a summary table with scores
|
|
400
|
+
4. Save individual JSON sidecars for each
|