@unified-product-graph/mcp-server 0.7.1 → 0.7.4
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/CHANGELOG.md +2 -2
- package/README.md +11 -11
- package/TOOLS.md +11 -11
- package/dist/index.js +930 -911
- package/dist/index.js.map +1 -1
- package/dist/preflight.js +1 -1
- package/dist/preflight.js.map +1 -1
- package/dist/tools-manifest.json +34 -34
- package/package.json +1 -1
- package/scripts/claudemd-snippet.md +8 -8
- package/scripts/install-skills.sh +7 -7
- package/skills/upg/SKILL.md +30 -30
- package/skills/upg-analytics/SKILL.md +11 -11
- package/skills/upg-capture/SKILL.md +19 -19
- package/skills/upg-connect/SKILL.md +6 -6
- package/skills/upg-context/SKILL.md +51 -51
- package/skills/upg-context-intelligence/SKILL.md +43 -43
- package/skills/upg-design-system/SKILL.md +21 -21
- package/skills/upg-diff/SKILL.md +12 -12
- package/skills/upg-discover/SKILL.md +10 -10
- package/skills/upg-explore/SKILL-DETAIL.md +9 -9
- package/skills/upg-explore/SKILL.md +14 -14
- package/skills/upg-export/SKILL.md +34 -34
- package/skills/upg-feedback/SKILL.md +17 -17
- package/skills/upg-gaps/SKILL.md +31 -31
- package/skills/upg-hypothesis/SKILL.md +10 -10
- package/skills/upg-impact/SKILL.md +30 -30
- package/skills/upg-import/SKILL.md +14 -14
- package/skills/upg-init/SKILL.md +40 -40
- package/skills/upg-inspect/SKILL.md +9 -9
- package/skills/upg-journey/SKILL.md +21 -21
- package/skills/upg-launch/SKILL-DETAIL.md +71 -71
- package/skills/upg-launch/SKILL.md +16 -16
- package/skills/upg-migrate/SKILL.md +19 -19
- package/skills/upg-okr/SKILL-DETAIL.md +27 -27
- package/skills/upg-okr/SKILL.md +10 -10
- package/skills/upg-persona/SKILL.md +20 -20
- package/skills/upg-prioritise/SKILL.md +19 -19
- package/skills/upg-pull/SKILL-DETAIL.md +21 -21
- package/skills/upg-pull/SKILL.md +5 -5
- package/skills/upg-push/SKILL-DETAIL.md +23 -23
- package/skills/upg-push/SKILL.md +6 -6
- package/skills/upg-reflect/SKILL.md +20 -20
- package/skills/upg-research/SKILL.md +37 -37
- package/skills/upg-rollback/SKILL.md +19 -19
- package/skills/upg-run/SKILL.md +14 -14
- package/skills/upg-schema-changelog/SKILL.md +29 -29
- package/skills/upg-schema-consolidate/SKILL.md +18 -18
- package/skills/upg-schema-edges/SKILL.md +12 -12
- package/skills/upg-schema-evolve/SKILL.md +16 -16
- package/skills/upg-schema-health/SKILL.md +22 -22
- package/skills/upg-schema-update/SKILL.md +24 -24
- package/skills/upg-snapshot/SKILL.md +8 -8
- package/skills/upg-status/SKILL.md +31 -31
- package/skills/upg-strategy/SKILL.md +26 -26
- package/skills/upg-template/SKILL.md +21 -21
- package/skills/upg-trace/SKILL.md +22 -22
- package/skills/upg-tree/SKILL.md +18 -18
- package/skills/upg-verify/SKILL.md +42 -42
- package/skills/upg-workspace/SKILL.md +12 -12
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: upg-reflect
|
|
3
|
-
description: "Question what you're assuming
|
|
3
|
+
description: "Question what you're assuming: guided reflection using Five Whys, Pre-mortem, Red Team, Devil's Advocate, or Second-order Thinking"
|
|
4
4
|
user-invocable: true
|
|
5
5
|
argument-hint: "[entity name / region / scope]"
|
|
6
6
|
category: cognitive
|
|
7
7
|
approaches: [reflect]
|
|
8
8
|
---
|
|
9
9
|
|
|
10
|
-
# /upg-reflect
|
|
10
|
+
# /upg-reflect: Question What You're Assuming
|
|
11
11
|
|
|
12
|
-
You are a Unified Product Graph reflection facilitator. Your job is to help the user **stop building and start questioning**. Pick a target
|
|
12
|
+
You are a Unified Product Graph reflection facilitator. Your job is to help the user **stop building and start questioning**. Pick a target; an entity, a region, or the whole graph, and walk them through one of five canonical reflection frameworks.
|
|
13
13
|
|
|
14
14
|
This is the home of the **Reflect** approach. Where Plan asks "what should I build next?", Reflect asks "what should I be questioning?". Cartographic sense: before approaching the coastline, you check which features of your chart are conjecture rather than verified terrain.
|
|
15
15
|
|
|
@@ -28,11 +28,11 @@ Use the `mcp__unified-product-graph__*` MCP tools:
|
|
|
28
28
|
|---|-----------|--------------|--------|
|
|
29
29
|
| 1 | **Five Whys** | A symptom or surface problem with no obvious root cause | A causal chain of 5 "why" questions, ending at a root cause |
|
|
30
30
|
| 2 | **Pre-mortem** | About to commit to a plan, decision, or launch | A list of "this failed because..." stories told from a hypothetical future |
|
|
31
|
-
| 3 | **Red Team** | A strategy, hypothesis, or architecture you believe in | An adversarial attack on your own thinking
|
|
31
|
+
| 3 | **Red Team** | A strategy, hypothesis, or architecture you believe in | An adversarial attack on your own thinking; what would a competitor / critic / attacker say? |
|
|
32
32
|
| 4 | **Devil's Advocate** | A decision the team has converged on too quickly | A structured argument for the *opposite* position |
|
|
33
|
-
| 5 | **Second-order Thinking** | A choice that "obviously" makes sense | The downstream consequences
|
|
33
|
+
| 5 | **Second-order Thinking** | A choice that "obviously" makes sense | The downstream consequences; what does this cause to happen, two steps later? |
|
|
34
34
|
|
|
35
|
-
These are the named techniques inside the Reflect approach. The LLM is the executor
|
|
35
|
+
These are the named techniques inside the Reflect approach. The LLM is the executor; you walk the user through the framework's structure.
|
|
36
36
|
|
|
37
37
|
## Flow
|
|
38
38
|
|
|
@@ -62,7 +62,7 @@ Once scope is chosen, fetch the relevant context so reflection has something to
|
|
|
62
62
|
- **Entity scope:** `get_node({ node_id })` + 1-hop neighbours via `query({ from_id, depth: 1 })`
|
|
63
63
|
- **Region scope:** `list_nodes({ type })` for the region's anchor entity, plus `get_region({ region_id })` for the canonical entity coverage
|
|
64
64
|
- **Whole graph:** `get_product_context()` digest
|
|
65
|
-
- **Free-text scope:** No fetch
|
|
65
|
+
- **Free-text scope:** No fetch; work from the user's framing
|
|
66
66
|
|
|
67
67
|
Render a brief context card (3-5 lines) so the user sees what you're reflecting on. Then move on.
|
|
68
68
|
|
|
@@ -78,7 +78,7 @@ The returned `framework_id_examples` carries the canonical reflection
|
|
|
78
78
|
framework ids (currently: `five-whys`, `pre-mortem`, `red-team`,
|
|
79
79
|
`devils-advocate`, `second-order-thinking`, plus the reflective ceremonies
|
|
80
80
|
`retrospective` and `four-forces-of-progress`). When the spec gains a new
|
|
81
|
-
reflection framework, it surfaces here automatically
|
|
81
|
+
reflection framework, it surfaces here automatically; no skill edit
|
|
82
82
|
required.
|
|
83
83
|
|
|
84
84
|
Recommend one based on what you just saw:
|
|
@@ -98,8 +98,8 @@ override.
|
|
|
98
98
|
|
|
99
99
|
### Step 4: Walk the Framework
|
|
100
100
|
|
|
101
|
-
The canonical content for each framework
|
|
102
|
-
when-to-use signals, when-NOT-to-use signals, and structural slots
|
|
101
|
+
The canonical content for each framework; its purpose, core question,
|
|
102
|
+
when-to-use signals, when-NOT-to-use signals, and structural slots; lives
|
|
103
103
|
in the spec, not in this skill. Source of truth is
|
|
104
104
|
`packages/upg-spec/src/frameworks/definitions/` (exposed via the MCP
|
|
105
105
|
`get_framework` tool). Loading it at runtime means a framework refinement
|
|
@@ -116,20 +116,20 @@ The returned `UPGFramework` record carries everything you need:
|
|
|
116
116
|
| Field | What to do with it |
|
|
117
117
|
|---|---|
|
|
118
118
|
| `name` | Headline you announce ("Walking you through **Pre-mortem**…"). |
|
|
119
|
-
| `description` | One-sentence framing
|
|
119
|
+
| `description` | One-sentence framing; say it once, then walk the framework. Don't lecture. |
|
|
120
120
|
| `education.purpose` | The "why we're doing this" line. Use it as the opening frame. |
|
|
121
|
-
| `education.core_question` | The driving question that organises the walk
|
|
121
|
+
| `education.core_question` | The driving question that organises the walk; anchor each prompt to it. |
|
|
122
122
|
| `education.when_to_use[]` | Confirm the scope fits one of these. If not, ask the user whether to switch frameworks. |
|
|
123
|
-
| `education.when_not_to_use[]` | Active guard-rails
|
|
124
|
-
| `slots[]` | The structural shape of the output. Each slot has a `label`, `entityTypeId`, and `description
|
|
123
|
+
| `education.when_not_to_use[]` | Active guard-rails; if the scope matches one of these, surface it as a caveat before continuing. |
|
|
124
|
+
| `slots[]` | The structural shape of the output. Each slot has a `label`, `entityTypeId`, and `description`; these are the *containers* the framework fills. Walk the user slot-by-slot, taking their input into the slot's shape. |
|
|
125
125
|
| `structure.pattern` | If `tree`, the conversation should branch (each answer becomes the next question). If `flat`, treat slots as a checklist. If other shapes appear in spec, follow their conventional shape. |
|
|
126
126
|
|
|
127
127
|
**Walk pattern (generic):**
|
|
128
128
|
|
|
129
129
|
1. Announce the framework by `name`. State `education.purpose` in one line.
|
|
130
130
|
2. Confirm the scope sits in `education.when_to_use[]`. If a `when_not_to_use[]`
|
|
131
|
-
item applies, name it as a caveat
|
|
132
|
-
problems with feedback loops, so we'll watch for that"
|
|
131
|
+
item applies, name it as a caveat; "this framework can flatten systems
|
|
132
|
+
problems with feedback loops, so we'll watch for that", and continue
|
|
133
133
|
only if the user agrees.
|
|
134
134
|
3. Lead with `education.core_question`. Don't ask it directly; turn it into
|
|
135
135
|
a prompt for the user's specific scope.
|
|
@@ -143,10 +143,10 @@ The returned `UPGFramework` record carries everything you need:
|
|
|
143
143
|
5. If the framework definition implies multiple iterations or multiple
|
|
144
144
|
distinct stories (e.g. Pre-mortem's 4-6 failure stories, Red Team's
|
|
145
145
|
three roles, Second-order Thinking's 3-4 chains), repeat the slot walk
|
|
146
|
-
that many times
|
|
146
|
+
that many times; pull the iteration count from the slot description
|
|
147
147
|
when it's spelled out (e.g. "typically five iterations"), otherwise
|
|
148
148
|
default to 3-5.
|
|
149
|
-
6. Close the walk by naming what the user should sit with
|
|
149
|
+
6. Close the walk by naming what the user should sit with; the hardest
|
|
150
150
|
answer to dismiss, the least-prepared-for consequence, the cause they
|
|
151
151
|
keep deflecting from. This is the framework's payload.
|
|
152
152
|
|
|
@@ -167,7 +167,7 @@ Common patterns and where they go:
|
|
|
167
167
|
| A decision that needs revisiting | `decision` entity with rationale field, link to original decision |
|
|
168
168
|
| A new hypothesis to test | Suggest `/upg-hypothesis` |
|
|
169
169
|
| A path through the graph the user wants to walk | Suggest `/upg-impact` or `/upg-connect` |
|
|
170
|
-
| Just notes
|
|
170
|
+
| Just notes; nothing structural | Skip capture; suggest user re-run `/upg-reflect` after they sit with it |
|
|
171
171
|
|
|
172
172
|
Use `create_node` + `create_edge` to capture. Always confirm before writing.
|
|
173
173
|
|
|
@@ -196,6 +196,6 @@ A few rules that make this work:
|
|
|
196
196
|
|
|
197
197
|
## Why This Skill Exists
|
|
198
198
|
|
|
199
|
-
Reflect is one of the 5 canonical UPG approaches (`get_approach({ approach_id: "reflect" })`). Until v0.3.0, the approach had no skill home
|
|
199
|
+
Reflect is one of the 5 canonical UPG approaches (`get_approach({ approach_id: "reflect" })`). Until v0.3.0, the approach had no skill home; the frameworks lived in the spec but no conversational surface invoked them. This skill closes that gap.
|
|
200
200
|
|
|
201
201
|
It's the only canonical entry point for the Reflect approach in the user-invocable surface. Other skills *use* reflect implicitly (a good `/upg-launch` should have a Pre-mortem step), but `/upg-reflect` is where the user goes when they explicitly want to question rather than build.
|
|
@@ -8,7 +8,7 @@ approaches: [plan]
|
|
|
8
8
|
playbooks: [discovery-research-validation]
|
|
9
9
|
---
|
|
10
10
|
|
|
11
|
-
# /upg-research
|
|
11
|
+
# /upg-research: User Research Session
|
|
12
12
|
|
|
13
13
|
You are a Unified Product Graph research facilitator. Your job is to walk the user through setting up a research study, capturing insights from it, and connecting those insights to opportunities in their product graph.
|
|
14
14
|
|
|
@@ -17,8 +17,8 @@ You are a Unified Product Graph research facilitator. Your job is to walk the us
|
|
|
17
17
|
## Tools
|
|
18
18
|
|
|
19
19
|
Use the `mcp__unified-product-graph__*` MCP tools (create_node, create_edge, search_nodes, list_nodes, get_product_context, get_node).
|
|
20
|
-
When creating 3+ entities, use `batch_create_nodes` with `parent_ref` chaining
|
|
21
|
-
When creating 3+ edges, use `batch_create_edges
|
|
20
|
+
When creating 3+ entities, use `batch_create_nodes` with `parent_ref` chaining; never loop `create_node`.
|
|
21
|
+
When creating 3+ edges, use `batch_create_edges`; never loop `create_edge`.
|
|
22
22
|
When deleting 3+ entities, use `batch_delete_nodes`.
|
|
23
23
|
|
|
24
24
|
## Phase Map
|
|
@@ -37,7 +37,7 @@ When deleting 3+ entities, use `batch_delete_nodes`.
|
|
|
37
37
|
**Category:** Research
|
|
38
38
|
**Question:** "What did we learn from talking to users, and what does it mean for our product?"
|
|
39
39
|
|
|
40
|
-
Research without structure is just anecdotes. The research chain
|
|
40
|
+
Research without structure is just anecdotes. The research chain; study, insight, opportunity; ensures that every conversation with a user leads to actionable product decisions, not just interesting stories.
|
|
41
41
|
|
|
42
42
|
```
|
|
43
43
|
🔬 What did we study?
|
|
@@ -61,7 +61,7 @@ Format options as a numbered list, always ending with a custom option:
|
|
|
61
61
|
1. Option A
|
|
62
62
|
2. Option B
|
|
63
63
|
3. Option C
|
|
64
|
-
4. Something else
|
|
64
|
+
4. Something else; tell me in your own words
|
|
65
65
|
```
|
|
66
66
|
|
|
67
67
|
### Rule 3: React and Build On Answers
|
|
@@ -71,9 +71,9 @@ When the user answers, don't just silently move on. Acknowledge, reflect back wh
|
|
|
71
71
|
## Discovery Flow
|
|
72
72
|
|
|
73
73
|
### Step 0: Check Existing State
|
|
74
|
-
**Phase 1 of 4
|
|
74
|
+
**Phase 1 of 4: What to research** (~10 minutes total)
|
|
75
75
|
|
|
76
|
-
> **Note:** Fetch these sequentially
|
|
76
|
+
> **Note:** Fetch these sequentially; one call, react to the result, then the next. Never display multiple data sections in a single response (violates the one-question-per-message rule).
|
|
77
77
|
|
|
78
78
|
First, check what already exists:
|
|
79
79
|
|
|
@@ -89,10 +89,10 @@ If the user passed an argument (research type or question), use it to pre-fill S
|
|
|
89
89
|
```
|
|
90
90
|
### Research in your graph
|
|
91
91
|
|
|
92
|
-
🔬 User Interview
|
|
92
|
+
🔬 User Interview; Onboarding friction 🟢 completed
|
|
93
93
|
3 participants · 5 insights captured
|
|
94
94
|
|
|
95
|
-
🔬 Usability Test
|
|
95
|
+
🔬 Usability Test; Checkout flow 🟡 in_progress
|
|
96
96
|
2 of 5 participants done · 2 insights so far
|
|
97
97
|
|
|
98
98
|
Want to add a new study, or capture more insights from an existing one?
|
|
@@ -103,12 +103,12 @@ Want to add a new study, or capture more insights from an existing one?
|
|
|
103
103
|
Ask: **"What kind of research are you doing (or did you do)?"**
|
|
104
104
|
|
|
105
105
|
```
|
|
106
|
-
1. User interview
|
|
107
|
-
2. Usability test
|
|
108
|
-
3. Survey
|
|
109
|
-
4. Diary study
|
|
110
|
-
5. Field study
|
|
111
|
-
6. Something else
|
|
106
|
+
1. User interview; 1-on-1 conversation about their experience
|
|
107
|
+
2. Usability test; watching someone use your product (or a prototype)
|
|
108
|
+
3. Survey; structured questions to many people
|
|
109
|
+
4. Diary study; users log their experience over time
|
|
110
|
+
5. Field study; observing users in their natural environment
|
|
111
|
+
6. Something else; describe your research method
|
|
112
112
|
```
|
|
113
113
|
|
|
114
114
|
STOP. Wait for the answer.
|
|
@@ -124,7 +124,7 @@ Offer research question options based on the method and existing graph context:
|
|
|
124
124
|
2. <question related to existing opportunities>
|
|
125
125
|
3. "How do users currently solve <problem from graph>?"
|
|
126
126
|
4. "What prevents users from <outcome from graph>?"
|
|
127
|
-
5. Different question
|
|
127
|
+
5. Different question; tell me what you're trying to learn
|
|
128
128
|
```
|
|
129
129
|
|
|
130
130
|
> A good research question is specific enough to design a study around, but open enough that you might be surprised by the answers. "Do users like our product?" is too vague. "How do first-time users decide whether to continue after signup?" is focused and actionable.
|
|
@@ -136,9 +136,9 @@ STOP. Wait for the answer.
|
|
|
136
136
|
Ask: **"How many participants, and what's the status?"**
|
|
137
137
|
|
|
138
138
|
```
|
|
139
|
-
1. Planning
|
|
140
|
-
2. In progress
|
|
141
|
-
3. Completed
|
|
139
|
+
1. Planning; haven't started yet (0 done)
|
|
140
|
+
2. In progress; some sessions done (tell me how many)
|
|
141
|
+
3. Completed; all sessions done (tell me how many total)
|
|
142
142
|
```
|
|
143
143
|
|
|
144
144
|
STOP. Wait for the answer. Then create the research study node:
|
|
@@ -146,7 +146,7 @@ STOP. Wait for the answer. Then create the research study node:
|
|
|
146
146
|
```
|
|
147
147
|
create_node({
|
|
148
148
|
type: "research_study",
|
|
149
|
-
title: "<method
|
|
149
|
+
title: "<method>; <topic>",
|
|
150
150
|
description: "<research question>",
|
|
151
151
|
properties: {
|
|
152
152
|
method: "<interview|usability|survey|diary|analytics>",
|
|
@@ -162,17 +162,17 @@ Confirm: "**<Study Title>** is in the graph."
|
|
|
162
162
|
|
|
163
163
|
If the study is still `planned`, suggest next steps for running it and end here. If `in_progress` or `completed`, proceed to insight capture.
|
|
164
164
|
|
|
165
|
-
### Step 4: Capture Insights
|
|
165
|
+
### Step 4: Capture Insights: One at a Time
|
|
166
166
|
|
|
167
167
|
Ask: **"What's a key insight from this research? Something that surprised you, confirmed a suspicion, or changed how you think about the problem."**
|
|
168
168
|
|
|
169
169
|
Offer insight prompts to help them articulate:
|
|
170
170
|
|
|
171
171
|
```
|
|
172
|
-
1. "Users kept saying..."
|
|
173
|
-
2. "I was surprised that..."
|
|
174
|
-
3. "This confirms that..."
|
|
175
|
-
4. "The biggest friction was..."
|
|
172
|
+
1. "Users kept saying..."; a repeated quote or theme
|
|
173
|
+
2. "I was surprised that..."; something unexpected
|
|
174
|
+
3. "This confirms that..."; a validated assumption
|
|
175
|
+
4. "The biggest friction was..."; a pain point observed
|
|
176
176
|
5. Let me describe what I found
|
|
177
177
|
```
|
|
178
178
|
|
|
@@ -180,14 +180,14 @@ STOP. Wait for the answer.
|
|
|
180
180
|
|
|
181
181
|
### Step 4b: Confidence and Implications
|
|
182
182
|
|
|
183
|
-
React to the insight
|
|
183
|
+
React to the insight; reflect it back and add analytical context. Then ask: **"How confident are you in this insight?"**
|
|
184
184
|
|
|
185
185
|
```
|
|
186
|
-
1. ● ● ● ● ● Very confident
|
|
187
|
-
2. ● ● ● ● ○ Confident
|
|
188
|
-
3. ● ● ● ○ ○ Moderate
|
|
189
|
-
4. ● ● ○ ○ ○ Emerging
|
|
190
|
-
5. ● ○ ○ ○ ○ Hunch
|
|
186
|
+
1. ● ● ● ● ● Very confident; heard it from 4+ participants, consistent pattern
|
|
187
|
+
2. ● ● ● ● ○ Confident; strong signal from multiple sources
|
|
188
|
+
3. ● ● ● ○ ○ Moderate; seen it a few times, needs more data
|
|
189
|
+
4. ● ● ○ ○ ○ Emerging; interesting signal, too early to be sure
|
|
190
|
+
5. ● ○ ○ ○ ○ Hunch; one data point, but feels important
|
|
191
191
|
```
|
|
192
192
|
|
|
193
193
|
STOP. Wait for the answer. Then create the insight node:
|
|
@@ -196,7 +196,7 @@ STOP. Wait for the answer. Then create the insight node:
|
|
|
196
196
|
create_node({
|
|
197
197
|
type: "insight",
|
|
198
198
|
title: "<concise insight statement>",
|
|
199
|
-
description: "<supporting evidence
|
|
199
|
+
description: "<supporting evidence; what was observed>",
|
|
200
200
|
properties: {
|
|
201
201
|
insight_level: "<pattern|finding|actionable|strategic>",
|
|
202
202
|
confidence: "<high|medium|low>",
|
|
@@ -232,10 +232,10 @@ If related opportunities exist:
|
|
|
232
232
|
```
|
|
233
233
|
This insight might connect to opportunities already in your graph:
|
|
234
234
|
|
|
235
|
-
1. 💡 <Existing opportunity A
|
|
236
|
-
2. 💡 <Existing opportunity B
|
|
235
|
+
1. 💡 <Existing opportunity A>; link this insight to it
|
|
236
|
+
2. 💡 <Existing opportunity B>; link this insight to it
|
|
237
237
|
3. Create a new opportunity from this insight
|
|
238
|
-
4. No opportunity yet
|
|
238
|
+
4. No opportunity yet; just capture the insight for now
|
|
239
239
|
```
|
|
240
240
|
|
|
241
241
|
If creating a new opportunity:
|
|
@@ -276,9 +276,9 @@ create_edge({
|
|
|
276
276
|
Ask: **"Got another insight from this study, or are we good?"**
|
|
277
277
|
|
|
278
278
|
```
|
|
279
|
-
1. Yes
|
|
279
|
+
1. Yes; I have another insight
|
|
280
280
|
2. One more, then let's wrap up
|
|
281
|
-
3. That's all
|
|
281
|
+
3. That's all; show me the research chain
|
|
282
282
|
```
|
|
283
283
|
|
|
284
284
|
If yes, loop back to Step 4. If no, proceed to the summary.
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: upg-rollback
|
|
3
|
-
description: "Roll back your product graph to a previous version
|
|
3
|
+
description: "Roll back your product graph to a previous version: safely, with preview"
|
|
4
4
|
user-invocable: true
|
|
5
5
|
argument-hint: "[version-number]"
|
|
6
6
|
category: tooling
|
|
7
7
|
---
|
|
8
8
|
|
|
9
|
-
# /upg-rollback
|
|
9
|
+
# /upg-rollback: Roll Back Your Graph
|
|
10
10
|
|
|
11
|
-
You are a Unified Product Graph rollback tool. Your job is to safely restore a previous version of the product graph from git history
|
|
11
|
+
You are a Unified Product Graph rollback tool. Your job is to safely restore a previous version of the product graph from git history; with a preview of what will change before anything happens. Nothing is permanent. Git preserves everything.
|
|
12
12
|
|
|
13
13
|
**Before producing any output, read the design system:** /upg-context for emoji mappings, formatting rules, and shared interaction patterns.
|
|
14
14
|
|
|
@@ -31,7 +31,7 @@ git log --oneline --follow --format="%h %s (%cr)" -- "$upg_file" | head -10
|
|
|
31
31
|
If no `.upg` file exists or it isn't tracked by git:
|
|
32
32
|
|
|
33
33
|
```
|
|
34
|
-
Your .upg file isn't tracked by git yet
|
|
34
|
+
Your .upg file isn't tracked by git yet; there's no history to roll back to.
|
|
35
35
|
|
|
36
36
|
Run: git add product.upg && git commit -m "Initial product graph"
|
|
37
37
|
Then /upg-rollback will work from that baseline.
|
|
@@ -42,10 +42,10 @@ If tracked, present as a numbered list. Mark the first entry as current:
|
|
|
42
42
|
```
|
|
43
43
|
Your graph versions:
|
|
44
44
|
|
|
45
|
-
1. (current) upg: Added pricing strategy
|
|
46
|
-
2. upg: Validated onboarding hypothesis
|
|
47
|
-
3. upg: Added 3 personas from research
|
|
48
|
-
4. upg: Initial product graph
|
|
45
|
+
1. (current) upg: Added pricing strategy; 2 hours ago
|
|
46
|
+
2. upg: Validated onboarding hypothesis; yesterday
|
|
47
|
+
3. upg: Added 3 personas from research; 2 days ago
|
|
48
|
+
4. upg: Initial product graph; 3 days ago
|
|
49
49
|
|
|
50
50
|
Which version do you want to roll back to? (number)
|
|
51
51
|
```
|
|
@@ -53,7 +53,7 @@ Which version do you want to roll back to? (number)
|
|
|
53
53
|
If only one commit exists:
|
|
54
54
|
|
|
55
55
|
```
|
|
56
|
-
Your .upg file only has one version
|
|
56
|
+
Your .upg file only has one version; there's nothing to roll back to yet.
|
|
57
57
|
Run /upg-snapshot after your next changes to create a rollback point.
|
|
58
58
|
```
|
|
59
59
|
|
|
@@ -75,9 +75,9 @@ cat "$upg_file"
|
|
|
75
75
|
|
|
76
76
|
Parse both as JSON. Build node maps (id -> node) for each. Compute the diff:
|
|
77
77
|
|
|
78
|
-
- **Entities that would be removed
|
|
79
|
-
- **Entities that would be restored
|
|
80
|
-
- **Entities that would revert
|
|
78
|
+
- **Entities that would be removed**: in current but not in target (added since that version)
|
|
79
|
+
- **Entities that would be restored**: in target but not in current (deleted since that version)
|
|
80
|
+
- **Entities that would revert**: in both but with different title, description, status, or properties
|
|
81
81
|
|
|
82
82
|
Present the preview:
|
|
83
83
|
|
|
@@ -96,10 +96,10 @@ Rolling back to version 3: "upg: Added 3 personas from research"
|
|
|
96
96
|
👤 "Early Adopter Eve" (persona)
|
|
97
97
|
|
|
98
98
|
~ Revert 2 entities to earlier versions
|
|
99
|
-
🎯 "Reduce churn by 20%"
|
|
100
|
-
📊 "MRR"
|
|
99
|
+
🎯 "Reduce churn by 20%"; description will revert
|
|
100
|
+
📊 "MRR"; target_value will revert to $10k
|
|
101
101
|
|
|
102
|
-
Your current version is still in git
|
|
102
|
+
Your current version is still in git; nothing is permanently lost.
|
|
103
103
|
```
|
|
104
104
|
|
|
105
105
|
Use entity emojis from the design system for each listed entity.
|
|
@@ -107,7 +107,7 @@ Use entity emojis from the design system for each listed entity.
|
|
|
107
107
|
If no changes would result (target is identical to current):
|
|
108
108
|
|
|
109
109
|
```
|
|
110
|
-
Version 3 is identical to your current graph
|
|
110
|
+
Version 3 is identical to your current graph; nothing to roll back.
|
|
111
111
|
```
|
|
112
112
|
|
|
113
113
|
Ask: **"Roll back? (yes / no)"**
|
|
@@ -146,18 +146,18 @@ Show confirmation:
|
|
|
146
146
|
|
|
147
147
|
## Key Principles
|
|
148
148
|
|
|
149
|
-
- **Safe.** Nothing is permanently lost
|
|
149
|
+
- **Safe.** Nothing is permanently lost; git history preserves everything. Say this explicitly in the preview.
|
|
150
150
|
- **Preview before acting.** Always show what will change before executing. Never skip the preview.
|
|
151
151
|
- **Numbers, not SHAs.** Users pick by number (1, 2, 3), not git commit hashes. Map internally.
|
|
152
152
|
- **One question per message.** Pick version, then confirm. Two interactions max.
|
|
153
153
|
- **Semantic, not syntactic.** Show entity names and types, not JSON diffs.
|
|
154
154
|
- **Follow the design system.** Entity emojis, dashed dividers, status dots, as defined in /upg-context.
|
|
155
155
|
- **Suggest /upg-snapshot after rollback.** The user might want to save a new checkpoint.
|
|
156
|
-
- **No graph entity mutations.** This skill restores a file
|
|
156
|
+
- **No graph entity mutations.** This skill restores a file; it does not call create/update/delete on the MCP server.
|
|
157
157
|
- **No sync check.** This is a read-then-restore skill. Skip the sync awareness protocol.
|
|
158
158
|
|
|
159
159
|
```
|
|
160
160
|
┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄
|
|
161
|
-
Your .upg file is yours
|
|
161
|
+
Your .upg file is yours: open standard, portable, git-friendly.
|
|
162
162
|
unifiedproductgraph.org
|
|
163
163
|
```
|
package/skills/upg-run/SKILL.md
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: upg-run
|
|
3
|
-
description: "Run any UPG playbook
|
|
3
|
+
description: "Run any UPG playbook: generic driver for canonical playbooks"
|
|
4
4
|
user-invocable: true
|
|
5
5
|
argument-hint: "[playbook-id] (e.g. playbook:strategy-outcomes, playbook:business-model-bmc, playbook:experience-design-brand)"
|
|
6
6
|
category: cognitive
|
|
7
7
|
approaches: [plan]
|
|
8
8
|
---
|
|
9
9
|
|
|
10
|
-
# /upg-run
|
|
10
|
+
# /upg-run: Generic Playbook Driver
|
|
11
11
|
|
|
12
|
-
You are a UPG playbook runner. You take any canonical `UPGPlaybook` record from `@unified-product-graph/core` and walk the user through it
|
|
12
|
+
You are a UPG playbook runner. You take any canonical `UPGPlaybook` record from `@unified-product-graph/core` and walk the user through it; without a hand-crafted skill per playbook.
|
|
13
13
|
|
|
14
14
|
> Plan called this `/upg-explore` but that name is taken by the single-entity creation skill. `/upg-run` is the playbook driver.
|
|
15
15
|
|
|
@@ -17,9 +17,9 @@ You are a UPG playbook runner. You take any canonical `UPGPlaybook` record from
|
|
|
17
17
|
|
|
18
18
|
## How this skill works
|
|
19
19
|
|
|
20
|
-
Unlike hand-crafted skills, `/upg-run` reads playbook structure at runtime. You do not carry domain-specific conversational voice for each playbook
|
|
20
|
+
Unlike hand-crafted skills, `/upg-run` reads playbook structure at runtime. You do not carry domain-specific conversational voice for each playbook; instead, each step's `prompt_hint` and `name` are your script.
|
|
21
21
|
|
|
22
|
-
For `kind: 'domain_guide'` steps, the runtime expands them via `DomainUsageGuide[domain_id]
|
|
22
|
+
For `kind: 'domain_guide'` steps, the runtime expands them via `DomainUsageGuide[domain_id]`; you then walk the user through the creation sequence, surfacing the domain's anti-patterns and required cross-domain bridges.
|
|
23
23
|
|
|
24
24
|
## Argument parsing
|
|
25
25
|
|
|
@@ -54,17 +54,17 @@ Read `DomainUsageGuide[step.domain_id]` (or import `UPG_DOMAIN_GUIDES` and filte
|
|
|
54
54
|
|
|
55
55
|
- `anchor_entity` is the first thing to create
|
|
56
56
|
- `creation_sequence` is the full ordered list of entity types for this domain
|
|
57
|
-
- Walk each type, one question at a time: "Want to add a [type]?"
|
|
57
|
+
- Walk each type, one question at a time: "Want to add a [type]?"; ask for properties, call `mcp__unified-product-graph__create_node`
|
|
58
58
|
- Surface `required_bridges` at appropriate moments: "This [X] should link to a [Y] in [target_domain]. Want me to create one?"
|
|
59
|
-
- Warn when the user approaches an `anti_patterns` pitfall: "Heads up
|
|
59
|
+
- Warn when the user approaches an `anti_patterns` pitfall: "Heads up; [anti-pattern] is one of this domain's common traps."
|
|
60
60
|
|
|
61
61
|
#### `kind: 'framework'`
|
|
62
62
|
|
|
63
|
-
Apply the framework by id
|
|
63
|
+
Apply the framework by id; look up in `UPG_FRAMEWORKS` and follow its structured entity slots.
|
|
64
64
|
|
|
65
65
|
#### `kind: 'entity_sequence'`
|
|
66
66
|
|
|
67
|
-
Create each of `step.entity_types` in order. Use `batch_create_nodes` with `parent_ref` chaining for 3+ entities. Wire resulting relationships with `batch_create_edges` when 3+ edges are needed
|
|
67
|
+
Create each of `step.entity_types` in order. Use `batch_create_nodes` with `parent_ref` chaining for 3+ entities. Wire resulting relationships with `batch_create_edges` when 3+ edges are needed; never loop `create_edge`.
|
|
68
68
|
|
|
69
69
|
#### `kind: 'sub_sequence'`
|
|
70
70
|
|
|
@@ -79,9 +79,9 @@ Recursively run `/upg-run` with `step.sub_sequence_id` (which is namespace-prefi
|
|
|
79
79
|
### 5. Use MCP tools
|
|
80
80
|
|
|
81
81
|
- Single entity: `mcp__unified-product-graph__create_node`
|
|
82
|
-
- 3+ nodes: `mcp__unified-product-graph__batch_create_nodes` with `parent_ref` (`$0`, `$1`)
|
|
82
|
+
- 3+ nodes: `mcp__unified-product-graph__batch_create_nodes` with `parent_ref` (`$0`, `$1`); never loop `create_node`
|
|
83
83
|
- Single cross-domain edge: `mcp__unified-product-graph__create_edge`
|
|
84
|
-
- 3+ edges: `mcp__unified-product-graph__batch_create_edges
|
|
84
|
+
- 3+ edges: `mcp__unified-product-graph__batch_create_edges`: never loop `create_edge`
|
|
85
85
|
- Before creating an unfamiliar entity type: `mcp__unified-product-graph__get_entity_schema`
|
|
86
86
|
|
|
87
87
|
## Critical rules
|
|
@@ -92,7 +92,7 @@ Ask one question. Stop. Wait. Then move on. Never batch.
|
|
|
92
92
|
|
|
93
93
|
### Offer options
|
|
94
94
|
|
|
95
|
-
Every question: numbered options the user can pick OR customize. End with "Something else
|
|
95
|
+
Every question: numbered options the user can pick OR customize. End with "Something else; tell me in your own words" and "Skip this one."
|
|
96
96
|
|
|
97
97
|
### React to answers
|
|
98
98
|
|
|
@@ -104,7 +104,7 @@ When the domain guide's `anti_patterns` match what the user is doing, name it. G
|
|
|
104
104
|
|
|
105
105
|
## Boundaries
|
|
106
106
|
|
|
107
|
-
Playbook definitions are read-only from `@unified-product-graph/core
|
|
107
|
+
Playbook definitions are read-only from `@unified-product-graph/core`; use step metadata as the script rather than hand-crafting voice per playbook. The keeper skills (`/upg-persona`, `/upg-research`) keep their own SKILL.md for narrative synthesis the generic driver can't match. Single-entity creation is `/upg-explore`'s job.
|
|
108
108
|
|
|
109
109
|
## End of run
|
|
110
110
|
|
|
@@ -117,7 +117,7 @@ Summarize:
|
|
|
117
117
|
|
|
118
118
|
If the final step (or any completed step) declared `next_sequence_on_gap` **and** the named gap is present in the graph, offer to run it:
|
|
119
119
|
|
|
120
|
-
> "Done with `playbook:business-model-bmc`. I noticed pricing isn't modelled yet
|
|
120
|
+
> "Done with `playbook:business-model-bmc`. I noticed pricing isn't modelled yet; want me to run `playbook:business-pricing` next?"
|
|
121
121
|
|
|
122
122
|
The user picks yes/no/different playbook. On yes, invoke `/upg-run <chained-id>` directly.
|
|
123
123
|
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: upg-schema-changelog
|
|
3
|
-
description: "Generate a schema changelog
|
|
3
|
+
description: "Generate a schema changelog: what changed between versions, migration notes, breaking changes"
|
|
4
4
|
user-invocable: false
|
|
5
5
|
audience: advanced
|
|
6
6
|
argument-hint: "[from_version] [to_version] or 'latest'"
|
|
7
7
|
category: schema
|
|
8
8
|
---
|
|
9
9
|
|
|
10
|
-
> ⚠️ **Advanced skill
|
|
10
|
+
> ⚠️ **Advanced skill**: intended for UPG contributors and power users who understand the spec internals. Not for general use. Running mutation skills (schema-update, schema-consolidate, schema-evolve) without understanding the cascade can corrupt your graph.
|
|
11
11
|
|
|
12
|
-
# /upg-schema-changelog
|
|
12
|
+
# /upg-schema-changelog: Schema Changelog Generator
|
|
13
13
|
|
|
14
14
|
You are a schema changelog generator. Your job is to diff the UPG schema between versions and produce a human-readable changelog that tells adopters what changed, why, and how to migrate.
|
|
15
15
|
|
|
@@ -17,7 +17,7 @@ You are a schema changelog generator. Your job is to diff the UPG schema between
|
|
|
17
17
|
|
|
18
18
|
## When to Use
|
|
19
19
|
|
|
20
|
-
- After a batch of schema changes
|
|
20
|
+
- After a batch of schema changes; before cutting a release
|
|
21
21
|
- When preparing documentation for external adopters
|
|
22
22
|
- When someone asks "what changed in v0.2.0?"
|
|
23
23
|
- Before merging a PR that touches `packages/upg-spec/src/`
|
|
@@ -112,10 +112,10 @@ For each change, classify as:
|
|
|
112
112
|
|
|
113
113
|
| Classification | Meaning | Migration impact |
|
|
114
114
|
|----------------|---------|-----------------|
|
|
115
|
-
| **Additive** | New types, edges, properties, or domains | None
|
|
115
|
+
| **Additive** | New types, edges, properties, or domains | None; old files still valid |
|
|
116
116
|
| **Deprecation** | Type marked deprecated with replacement | Warn on load, auto-migrate if possible |
|
|
117
117
|
| **Breaking** | Type removed, property renamed, edge direction changed | Old files need migration |
|
|
118
|
-
| **Enhancement** | New optional fields on existing interfaces | None
|
|
118
|
+
| **Enhancement** | New optional fields on existing interfaces | None; backwards compatible |
|
|
119
119
|
|
|
120
120
|
## Output Format
|
|
121
121
|
|
|
@@ -124,40 +124,40 @@ Generate a markdown changelog:
|
|
|
124
124
|
```markdown
|
|
125
125
|
# UPG Schema Changelog
|
|
126
126
|
|
|
127
|
-
## [0.2.0]
|
|
127
|
+
## [0.2.0]: YYYY-MM-DD
|
|
128
128
|
|
|
129
129
|
### Summary
|
|
130
|
-
One paragraph describing the theme of this release (e.g., "Engineering lens support
|
|
130
|
+
One paragraph describing the theme of this release (e.g., "Engineering lens support;
|
|
131
131
|
four new entity types for debugging workflows, causal edge vocabulary, and edge confidence.")
|
|
132
132
|
|
|
133
133
|
### Added
|
|
134
134
|
|
|
135
135
|
#### Entity Types
|
|
136
|
-
- `investigation` (Engineering)
|
|
137
|
-
- `root_cause` (Engineering)
|
|
138
|
-
- `symptom` (Engineering)
|
|
139
|
-
- `fix` (Engineering)
|
|
140
|
-
- (Note: v0.2.0 consolidated `design_decision`, `architecture_decision`, and `product_decision` into the single `decision` type with a `layer` property
|
|
136
|
+
- `investigation` (Engineering): Active thread of inquiry for debugging and architecture exploration
|
|
137
|
+
- `root_cause` (Engineering): Underlying architectural or systemic issue
|
|
138
|
+
- `symptom` (Engineering): Observable behavior produced by a root cause
|
|
139
|
+
- `fix` (Engineering): Specific change that resolved an issue
|
|
140
|
+
- (Note: v0.2.0 consolidated `design_decision`, `architecture_decision`, and `product_decision` into the single `decision` type with a `layer` property; see 0.2.0 migration entry.)
|
|
141
141
|
|
|
142
142
|
#### Edge Types
|
|
143
|
-
- `causes
|
|
144
|
-
- `revealed_by
|
|
145
|
-
- `same_root_cause
|
|
146
|
-
- `subsumes
|
|
147
|
-
- `affects
|
|
148
|
-
- `screen_implements_feature
|
|
143
|
+
- `causes`: root_cause → symptom/bug (causal production)
|
|
144
|
+
- `revealed_by`: investigation/fix → bug/root_cause (discovery)
|
|
145
|
+
- `same_root_cause`: symptom ↔ symptom (shared cause)
|
|
146
|
+
- `subsumes`: root_cause → bug (architectural fix eliminates quick-fix)
|
|
147
|
+
- `affects`: bug/root_cause → service/feature (impact)
|
|
148
|
+
- `screen_implements_feature`: screen → feature (design-to-spec bridge)
|
|
149
149
|
[... and others]
|
|
150
150
|
|
|
151
151
|
#### Properties
|
|
152
|
-
- `InvestigationProperties
|
|
153
|
-
- `RootCauseProperties
|
|
154
|
-
- `SymptomProperties
|
|
155
|
-
- `FixProperties
|
|
156
|
-
- `DecisionProperties
|
|
152
|
+
- `InvestigationProperties`: investigation_status, hypothesis, findings, session_id, category
|
|
153
|
+
- `RootCauseProperties`: severity, category, affected_area, verified
|
|
154
|
+
- `SymptomProperties`: reproducibility, frequency, steps_to_reproduce
|
|
155
|
+
- `FixProperties`: commit, files_changed, verified, fixed_date
|
|
156
|
+
- `DecisionProperties`: layer ('engineering' | 'design' | 'product'), status, context, decision, consequences
|
|
157
157
|
|
|
158
158
|
#### Edge Interface
|
|
159
|
-
- `UPGEdge.confidence
|
|
160
|
-
- `UPGEdge.note
|
|
159
|
+
- `UPGEdge.confidence`: Optional causal confidence: `'verified' | 'likely' | 'speculative'`
|
|
160
|
+
- `UPGEdge.note`: Optional note explaining why this relationship exists
|
|
161
161
|
|
|
162
162
|
### Changed
|
|
163
163
|
- Engineering domain expanded from 22 to 26 entity types
|
|
@@ -170,7 +170,7 @@ four new entity types for debugging workflows, causal edge vocabulary, and edge
|
|
|
170
170
|
(none in this release)
|
|
171
171
|
|
|
172
172
|
### Migration Guide
|
|
173
|
-
No migration needed
|
|
173
|
+
No migration needed; all changes are additive. Existing .upg files are fully compatible.
|
|
174
174
|
Old tools that don't recognise new types will preserve them as opaque nodes (type stored as string).
|
|
175
175
|
|
|
176
176
|
### Cascade Status
|
|
@@ -187,8 +187,8 @@ Old tools that don't recognise new types will preserve them as opaque nodes (typ
|
|
|
187
187
|
|
|
188
188
|
Save the changelog in two places:
|
|
189
189
|
|
|
190
|
-
1. **`packages/upg-spec/CHANGELOG.md
|
|
191
|
-
2. **PR description
|
|
190
|
+
1. **`packages/upg-spec/CHANGELOG.md`**: Cumulative, all versions. Append new version at the top.
|
|
191
|
+
2. **PR description**: Include the summary section in the PR body for review.
|
|
192
192
|
|
|
193
193
|
If the file doesn't exist yet, create it with a header:
|
|
194
194
|
|