@jabworks/condux 0.11.0 → 0.12.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jabworks/condux",
3
- "version": "0.11.0",
3
+ "version": "0.12.0",
4
4
  "description": "OpenCode plugin for the condux workflow toolkit — bundles the condux skills and injects the specialist agents (coder, explorer, planner, researcher) plus an opt-in plan-review listener.",
5
5
  "type": "module",
6
6
  "publishConfig": {
@@ -0,0 +1,103 @@
1
+ ---
2
+ name: blueprint
3
+ description: "Produce dependency-free visual clarity artifacts at design time — grayscale HTML wireframes for UI screens and flows, and inline-SVG system diagrams (data models, flows, architecture, state machines) for backend work. During /discovery when the feature has a UI surface or a data model, from /draft-plan task cards, or standalone on \"mock this up\", \"wireframe this screen\", \"visualize the data model\", \"sketch the architecture\", \"diagram the flow\". Not for aesthetic or brand direction, editable design canvases or Figma, charts from real data, or generating code from a mockup."
4
+ argument-hint: "[surface or model to visualize — optional; defaults to the current design context]"
5
+ ---
6
+
7
+ # /blueprint
8
+
9
+ Make the design visible before it's built. Wireframes tell a frontend dev what
10
+ goes where and why; system diagrams tell a backend dev what talks to what.
11
+ Structure, never style.
12
+
13
+ ## Usage
14
+
15
+ ```
16
+ /blueprint checkout flow
17
+ /blueprint orders data model
18
+ /blueprint # infers surfaces from the design being discussed
19
+ ```
20
+
21
+ ## How It Works
22
+
23
+ ```
24
+ ┌──────────────────────────────────────────────────────────────────┐
25
+ │ BLUEPRINT │
26
+ ├──────────────────────────────────────────────────────────────────┤
27
+ │ Step 1: ASSESS SURFACES │
28
+ │ What does the feature touch? │
29
+ │ - UI screens or flows → wireframe family │
30
+ │ - Data models, services, → diagram family │
31
+ │ flows, state machines │
32
+ │ - Both → both families │
33
+ │ │
34
+ │ Step 2: PRODUCE │
35
+ │ One self-contained HTML file per screen / flow state / diagram. │
36
+ │ Wireframes follow references/wireframe-kit.md. │
37
+ │ Diagrams follow references/diagram-kit.md. │
38
+ │ No external assets, no CDN, no fonts beyond the system stack. │
39
+ │ │
40
+ │ Step 3: DELIVER │
41
+ │ Open in the browser (xdg-open / open). If neither works │
42
+ │ (headless, SSH), print the absolute paths and continue — │
43
+ │ never fail on delivery. │
44
+ │ │
45
+ │ Step 4: LINK │
46
+ │ Reference the files from the design doc or task card that │
47
+ │ motivated them, so the visual target travels with the design. │
48
+ └──────────────────────────────────────────────────────────────────┘
49
+ ```
50
+
51
+ ## The Two Families
52
+
53
+ **Wireframes (UI clarity).** Grayscale boxes with real content hierarchy and
54
+ annotation callouts. A wireframe answers: what elements exist, how they group,
55
+ what order they read in, what happens on each state (empty, loading, error,
56
+ populated). Multiple states of one flow are separate files, named for the
57
+ state. The full discipline — hard rules plus a copyable base-CSS block — is in
58
+ `references/wireframe-kit.md`.
59
+
60
+ **System diagrams (BE clarity).** Hand-authored inline SVG for four shapes:
61
+ entity/data-model, request/data flow, architecture boxes-and-arrows, and state
62
+ machines. A diagram answers: what entities or services exist, what relates to
63
+ what, what direction data moves, what states are legal. Skeletons and
64
+ label conventions are in `references/diagram-kit.md`.
65
+
66
+ Pick per surface, not per request — a feature with a settings page and a new
67
+ `preferences` table gets a wireframe *and* an entity diagram.
68
+
69
+ ## Where Files Go
70
+
71
+ Write to `<git-root>/.condux/designs/<YYYY-MM-DD>-<feature>/mockups/<name>.html`,
72
+ beside the feature's design doc. `.condux/` is gitignored working state,
73
+ created on demand at the git root — before the first write, check it's
74
+ ignored (`git check-ignore -q .condux/ || echo "not ignored"`) and offer to
75
+ add it to `.gitignore` if it isn't. Not a git repo → fall back to CWD and say
76
+ so once. Standalone invocations with no design doc use the same path with the
77
+ request's kebab-case subject as `<feature>`.
78
+
79
+ **Citation direction:** these files are ephemeral. A committed file — a spec,
80
+ a changelog, a backlog item — may never cite a `.condux/` path; promote the
81
+ mockup into the spec directory first and cite the committed copy.
82
+
83
+ ## Inside the Workflow
84
+
85
+ - **/discovery** loads this skill at the propose step when the feature has a
86
+ UI surface or a data model — the mockups render the proposal, and the
87
+ signed-off design doc links the chosen ones. Side-by-side option *picking*
88
+ stays with discovery's own mockup-picker.
89
+ - **/draft-plan** task cards may cite mockup paths so an implementer sees the
90
+ visual target for their task.
91
+ - Standalone asks ("mock this up", "visualize the data model") run the same
92
+ three steps without the discovery context.
93
+
94
+ ## What Does NOT Happen
95
+
96
+ ```
97
+ ✗ Brand styling, palettes, typography choices, premium polish — structure only
98
+ ✗ Colors beyond grayscale (one muted annotation accent is the ceiling)
99
+ ✗ External dependencies — no Mermaid CDN, no image generation, no Figma
100
+ ✗ Code generation from the mockup (that's implementation's job, later)
101
+ ✗ Charts of real data (that's a dataviz concern, not a design mockup)
102
+ ✗ Editing the mockups after design sign-off without saying so
103
+ ```
@@ -0,0 +1,96 @@
1
+ [
2
+ {
3
+ "query": "mock this up before we build it",
4
+ "should_trigger": true,
5
+ "expected_skill": "blueprint"
6
+ },
7
+ {
8
+ "query": "wireframe the settings page so the frontend dev knows what to expect",
9
+ "should_trigger": true,
10
+ "expected_skill": "blueprint"
11
+ },
12
+ {
13
+ "query": "can you mock up the checkout flow including the empty and error states",
14
+ "should_trigger": true,
15
+ "expected_skill": "blueprint"
16
+ },
17
+ {
18
+ "query": "visualize the data model for orders and customers",
19
+ "should_trigger": true,
20
+ "expected_skill": "blueprint"
21
+ },
22
+ {
23
+ "query": "sketch the architecture for the notification service",
24
+ "should_trigger": true,
25
+ "expected_skill": "blueprint"
26
+ },
27
+ {
28
+ "query": "diagram the auth flow between the gateway and the identity service",
29
+ "should_trigger": true,
30
+ "expected_skill": "blueprint"
31
+ },
32
+ {
33
+ "query": "draw the state machine for the subscription lifecycle",
34
+ "should_trigger": true,
35
+ "expected_skill": "blueprint"
36
+ },
37
+ {
38
+ "query": "I want a visual of how the entities relate before we touch the schema",
39
+ "should_trigger": true,
40
+ "expected_skill": "blueprint"
41
+ },
42
+ {
43
+ "query": "give me a quick layout mockup of the dashboard so we agree on structure",
44
+ "should_trigger": true,
45
+ "expected_skill": "blueprint"
46
+ },
47
+ {
48
+ "query": "show me a wireframe of both options for the onboarding screen",
49
+ "should_trigger": true,
50
+ "expected_skill": "blueprint",
51
+ "accept": ["discovery"]
52
+ },
53
+ {
54
+ "query": "before planning, can we visualize what this feature will look like",
55
+ "should_trigger": true,
56
+ "expected_skill": "blueprint",
57
+ "accept": ["discovery", "workflow"]
58
+ },
59
+ {
60
+ "query": "mock up the ER diagram for the new billing tables",
61
+ "should_trigger": true,
62
+ "expected_skill": "blueprint",
63
+ "kind": "in-context"
64
+ },
65
+ {
66
+ "query": "add a wireframe for the loading state too",
67
+ "should_trigger": true,
68
+ "expected_skill": "blueprint",
69
+ "kind": "in-context"
70
+ },
71
+ {
72
+ "query": "make this landing page look premium",
73
+ "should_trigger": false,
74
+ "expected_skill": null
75
+ },
76
+ {
77
+ "query": "plot signups per week as a bar chart",
78
+ "should_trigger": false,
79
+ "expected_skill": null
80
+ },
81
+ {
82
+ "query": "build the settings page from the approved design",
83
+ "should_trigger": false,
84
+ "expected_skill": null
85
+ },
86
+ {
87
+ "query": "implement this Figma design as a React component",
88
+ "should_trigger": false,
89
+ "expected_skill": null
90
+ },
91
+ {
92
+ "query": "pick a color palette and typography for the marketing site",
93
+ "should_trigger": false,
94
+ "expected_skill": null
95
+ }
96
+ ]
@@ -0,0 +1,81 @@
1
+ # Diagram Kit
2
+
3
+ Reference for `/blueprint`. Hand-authored inline SVG — no Mermaid, no CDN, no
4
+ renderer dependency. Every diagram is a self-contained HTML file that renders
5
+ from `file://`.
6
+
7
+ ## Shared Conventions
8
+
9
+ - Canvas: `<svg viewBox="0 0 W H" style="max-width:100%">` sized to content;
10
+ the page wraps it in the same `.frame` shell as the wireframe kit.
11
+ - Palette mirrors the wireframe discipline: fills `#fff`/`#f0f0f0`, strokes
12
+ `#777`, text `#222`, the `#5b7c99` accent for the one thing the diagram is
13
+ about (the new entity, the changed edge) — never more than one accent use.
14
+ - Text: `font-family: -apple-system, "Segoe UI", Roboto, sans-serif`, 13–14px
15
+ labels, 11px annotations. If a label doesn't fit its box, the box grows —
16
+ never shrink the font below 11px.
17
+ - Arrowheads via one shared `<marker>`:
18
+
19
+ ```html
20
+ <defs>
21
+ <marker id="arrow" viewBox="0 0 10 10" refX="9" refY="5"
22
+ markerWidth="7" markerHeight="7" orient="auto-start-reverse">
23
+ <path d="M0,0 L10,5 L0,10 z" fill="#777"/>
24
+ </marker>
25
+ </defs>
26
+ <!-- usage: <line ... stroke="#777" marker-end="url(#arrow)"/> -->
27
+ ```
28
+
29
+ - Every relationship line gets a label. An unlabeled arrow is a guess the
30
+ reader has to make.
31
+
32
+ ## 1. Entity / Data-Model
33
+
34
+ One `<g>` per entity: title bar + field rows. Keys marked `PK` / `FK`; edge
35
+ labels carry cardinality (`1..*`, `0..1`).
36
+
37
+ ```html
38
+ <g transform="translate(40,40)">
39
+ <rect width="200" height="24" fill="#f0f0f0" stroke="#777"/>
40
+ <text x="100" y="17" text-anchor="middle" font-weight="600">orders</text>
41
+ <rect y="24" width="200" height="72" fill="#fff" stroke="#777"/>
42
+ <text x="8" y="41">id PK</text>
43
+ <text x="8" y="61">user_id FK</text>
44
+ <text x="8" y="81">status</text>
45
+ </g>
46
+ <!-- edge: users 1..* orders -->
47
+ <line x1="240" y1="80" x2="340" y2="80" stroke="#777" marker-end="url(#arrow)"/>
48
+ <text x="290" y="72" text-anchor="middle" font-size="11">1..*</text>
49
+ ```
50
+
51
+ ## 2. Request / Data Flow
52
+
53
+ Actors and stores as boxes on one horizontal band; numbered edges show
54
+ sequence. Number every hop (`1. POST /orders`, `2. validate`, `3. INSERT`) —
55
+ the numbers are what make it a flow rather than a topology.
56
+
57
+ ## 3. Architecture (boxes-and-arrows)
58
+
59
+ Services as rounded rects (`rx="6"`), external systems as rects with a dashed
60
+ stroke (`stroke-dasharray="4 3"`), boundaries (network, process, trust) as a
61
+ large dashed `<rect>` behind its members with the boundary name in the top-left
62
+ corner. Edges labeled with protocol or payload (`HTTP`, `queue: order.created`).
63
+
64
+ ## 4. State Machine
65
+
66
+ States as rounded rects, transitions as labeled arrows, initial state marked
67
+ with a filled dot and an arrow, terminal states with a double border (nested
68
+ `<rect>` inset by 3px). Every transition label is the *event* that causes it,
69
+ not a description of the target state.
70
+
71
+ ## Choosing the Shape
72
+
73
+ | The question being asked | Shape |
74
+ |---|---|
75
+ | What entities exist and how do they relate? | Entity / data-model |
76
+ | What happens, in what order, when X occurs? | Request / data flow |
77
+ | What services exist and what talks to what? | Architecture |
78
+ | What states are legal and what moves between them? | State machine |
79
+
80
+ When a design raises two of these questions, draw two diagrams — a diagram
81
+ answering two questions at once answers neither legibly.
@@ -0,0 +1,88 @@
1
+ # Wireframe Kit
2
+
3
+ Reference for `/blueprint`. The discipline is what keeps a wireframe
4
+ unambiguous: the moment brand styling creeps in, reviewers debate taste
5
+ instead of structure.
6
+
7
+ ## Hard Rules
8
+
9
+ 1. **Grayscale only.** Backgrounds `#fff`–`#f5f5f5`, borders `#ccc`,
10
+ text `#222`/`#777`. One muted accent (`#5b7c99`) is allowed for
11
+ annotation callouts only — never for UI elements.
12
+ 2. **System font stack.** `-apple-system, "Segoe UI", Roboto, sans-serif`.
13
+ No webfonts, no font files.
14
+ 3. **No imagery.** Photos and illustrations render as a crossed box with a
15
+ label (`.img-box`). Icons render as their name in brackets, e.g. `[gear]`.
16
+ 4. **Real hierarchy, placeholder content.** Headings, labels, and CTAs carry
17
+ their actual intended text; body copy may be greeked with `▓▓▓` bars.
18
+ 5. **Annotate decisions, not furniture.** A callout explains *why this is
19
+ here* or *what happens on interaction* — not "this is a button".
20
+ 6. **One file per screen or flow state.** Empty, loading, error, and populated
21
+ are different files named for the state:
22
+ `settings-page.html`, `settings-page-empty.html`, `settings-page-error.html`.
23
+ 7. **Self-contained.** All CSS inline in a `<style>` block. No external
24
+ requests of any kind. The file must render identically from `file://`.
25
+
26
+ ## Base CSS
27
+
28
+ Copy this block into every wireframe's `<style>` and build on it.
29
+
30
+ ```css
31
+ * { margin: 0; box-sizing: border-box; }
32
+ body {
33
+ font-family: -apple-system, "Segoe UI", Roboto, sans-serif;
34
+ background: #f5f5f5; color: #222; padding: 24px;
35
+ }
36
+ .frame { /* the device/viewport boundary */
37
+ background: #fff; border: 2px solid #ccc; border-radius: 6px;
38
+ max-width: 1100px; margin: 0 auto; padding: 24px;
39
+ }
40
+ .box { /* generic grouping region */
41
+ border: 1px dashed #bbb; border-radius: 4px;
42
+ padding: 16px; margin-bottom: 16px;
43
+ }
44
+ .row { display: flex; gap: 16px; }
45
+ .row > * { flex: 1; }
46
+ .img-box { /* rule 3: imagery placeholder */
47
+ border: 1px solid #ccc; background:
48
+ linear-gradient(45deg, transparent 49.5%, #ccc 49.5%, #ccc 50.5%, transparent 50.5%),
49
+ linear-gradient(-45deg, transparent 49.5%, #ccc 49.5%, #ccc 50.5%, transparent 50.5%);
50
+ display: flex; align-items: center; justify-content: center;
51
+ color: #777; min-height: 120px;
52
+ }
53
+ .btn { /* any actionable element */
54
+ display: inline-block; border: 1px solid #777; border-radius: 4px;
55
+ padding: 8px 20px; background: #eee; color: #222;
56
+ }
57
+ .greek { /* rule 4: body-copy placeholder */
58
+ color: #ccc; letter-spacing: 2px; overflow: hidden; white-space: nowrap;
59
+ }
60
+ .note { /* rule 5: annotation callout — the only accent use */
61
+ border-left: 3px solid #5b7c99; background: #eef2f6; color: #33475b;
62
+ padding: 8px 12px; font-size: 13px; margin: 8px 0;
63
+ }
64
+ ```
65
+
66
+ Greeked copy: `<div class="greek">▓▓▓▓▓▓▓▓ ▓▓▓▓ ▓▓▓▓▓▓</div>` at whatever
67
+ width the real copy would occupy.
68
+
69
+ ## Page Skeleton
70
+
71
+ ```html
72
+ <title>settings-page — wireframe</title>
73
+ <style>/* base CSS above */</style>
74
+ <div class="frame">
75
+ <div class="box"><strong>Header</strong> · [logo] · nav: Account / Billing / Team</div>
76
+ <div class="row">
77
+ <div class="box"><!-- sidebar --></div>
78
+ <div class="box" style="flex:3"><!-- main content --></div>
79
+ </div>
80
+ <div class="note">Sidebar collapses below 768px — Billing moves into the header nav.</div>
81
+ </div>
82
+ ```
83
+
84
+ ## Review Posture
85
+
86
+ Present a wireframe as a question, not an answer: "this is the structure I
87
+ understood — what's wrong with it?" When two structures genuinely compete,
88
+ produce both files and let discovery's mockup-picker run the choice.
@@ -49,6 +49,9 @@ as any other soft gate in this skill.
49
49
  │ Present 2-3 approaches with tradeoffs. │
50
50
  │ Show design in sections — get acknowledgment per section │
51
51
  │ before moving on. │
52
+ │ UI surface or data model involved? Load `blueprint` to │
53
+ │ render the proposal visually — wireframes and diagrams │
54
+ │ become part of what gets signed off. │
52
55
  │ │
53
56
  │ Step 4: DETAIL ROUND — feed the spec │
54
57
  │ With the approach chosen, ask ONE more batch, grouped by │
@@ -168,7 +171,10 @@ design that lives only in conversation doesn't count as signed off.
168
171
  ignored — see the bootstrap step there. Honour an `AGENTS.md` path override
169
172
  if the project defines one.
170
173
 
171
- For side-by-side layout comparisons or architecture diagrams during the design phase, see `references/mockup-picker.md`.
174
+ For full design mockups — grayscale UI wireframes, data-model / flow /
175
+ architecture diagrams — load the `blueprint` skill; the design doc links the
176
+ files it produces. For *picking between* side-by-side options in the browser,
177
+ see `references/mockup-picker.md` (it can point at blueprint's files).
172
178
 
173
179
  ## Design Review Loop
174
180
 
@@ -110,6 +110,10 @@ implementer (especially a subagent) sees only their own card, so `Consumes`
110
110
  is what prevents drift like `clearLayers()` in Task 3 vs `clearFullLayers()`
111
111
  in Task 7.
112
112
 
113
+ When `blueprint` mockups exist for the feature, a card may cite the relevant
114
+ file under `.condux/designs/<feature>/mockups/` so the implementer sees the
115
+ visual target for their task (ephemeral→ephemeral citation — allowed).
116
+
113
117
  ## Code Sketches
114
118
 
115
119
  Plans are reviewed by annotation before any code is written, so the cheapest
@@ -150,6 +150,7 @@ Load each only when its step is reached.
150
150
  | Skill | When | Gate discipline |
151
151
  |---|---|---|
152
152
  | `discovery` | LARGE, before planning, or scope unclear | soft gate — ask before skipping |
153
+ | `blueprint` | discovery's propose step, or a standalone mockup/visualization ask | load only when a UI surface or data model is in play; structure, never styling |
153
154
  | `draft-plan` | LARGE, after discovery sign-off | needs a signed-off design; no design → apply the discovery soft gate first |
154
155
  | `test-first-development` | user asks, or picks it at CP-1 | one upfront consent; always ask before editing an existing test spec |
155
156
  | `subagent-execution` | LARGE plan where specialization/parallelism pays off | default is implement yourself |
@@ -8,7 +8,7 @@ it with the user, then executes the matching flow, loading downstream skills onl
8
8
  when a step needs them.
9
9
 
10
10
  **These skills execute _within_ workflow, never instead of it:** `discovery`,
11
- `draft-plan`, `test-first-development`, `subagent-execution`,
11
+ `draft-plan`, `blueprint`, `test-first-development`, `subagent-execution`,
12
12
  `subagent-deployment`, `preflight`, `finalize`, `code-review`,
13
13
  `root-cause-analysis`, `live-verification`, `plan-review`, `technical-spec`.
14
14