@jterrats/open-orchestra 1.0.2 → 1.0.3

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.
Files changed (145) hide show
  1. package/AGENTS.md +7 -2
  2. package/CLAUDE.md +2 -2
  3. package/README.md +3 -0
  4. package/dist/args.js +12 -2
  5. package/dist/args.js.map +1 -1
  6. package/dist/assets/web-console.js +44 -0
  7. package/dist/autonomous-phase-lifecycle.js +23 -3
  8. package/dist/autonomous-phase-lifecycle.js.map +1 -1
  9. package/dist/autonomous-run-state.js +2 -0
  10. package/dist/autonomous-run-state.js.map +1 -1
  11. package/dist/benchmark.js +6 -0
  12. package/dist/benchmark.js.map +1 -1
  13. package/dist/cli.js +4 -1
  14. package/dist/cli.js.map +1 -1
  15. package/dist/command-manifest.js +4 -3
  16. package/dist/command-manifest.js.map +1 -1
  17. package/dist/command-utils.js +4 -5
  18. package/dist/command-utils.js.map +1 -1
  19. package/dist/commands.d.ts +1 -1
  20. package/dist/commands.js +1 -1
  21. package/dist/commands.js.map +1 -1
  22. package/dist/metrics-commands.js +8 -0
  23. package/dist/metrics-commands.js.map +1 -1
  24. package/dist/roles/core-roles.js +10 -5
  25. package/dist/roles/core-roles.js.map +1 -1
  26. package/dist/skills-catalog.js +67 -0
  27. package/dist/skills-catalog.js.map +1 -1
  28. package/dist/skills-commands.d.ts +1 -0
  29. package/dist/skills-commands.js +37 -1
  30. package/dist/skills-commands.js.map +1 -1
  31. package/dist/skills-planning.d.ts +2 -1
  32. package/dist/skills-planning.js +79 -11
  33. package/dist/skills-planning.js.map +1 -1
  34. package/dist/skills.d.ts +1 -1
  35. package/dist/skills.js +1 -1
  36. package/dist/skills.js.map +1 -1
  37. package/dist/task-graph-commands.js +36 -8
  38. package/dist/task-graph-commands.js.map +1 -1
  39. package/dist/types/metrics.d.ts +2 -0
  40. package/dist/types/skills.d.ts +9 -0
  41. package/dist/types/tasks.d.ts +8 -1
  42. package/dist/types.d.ts +2 -2
  43. package/dist/types.js.map +1 -1
  44. package/dist/web-api.js +80 -7
  45. package/dist/web-api.js.map +1 -1
  46. package/dist/workflow-approval-service.js +13 -0
  47. package/dist/workflow-approval-service.js.map +1 -1
  48. package/dist/workflow-evidence-service.js +37 -2
  49. package/dist/workflow-evidence-service.js.map +1 -1
  50. package/dist/workflow-gates.js +56 -1
  51. package/dist/workflow-gates.js.map +1 -1
  52. package/dist/workflow-phase-planner.js +51 -9
  53. package/dist/workflow-phase-planner.js.map +1 -1
  54. package/dist/workflow-run-commands.d.ts +1 -0
  55. package/dist/workflow-run-commands.js +11 -6
  56. package/dist/workflow-run-commands.js.map +1 -1
  57. package/dist/workflow-services.js +24 -0
  58. package/dist/workflow-services.js.map +1 -1
  59. package/dist/workflow-task-service.js +27 -2
  60. package/dist/workflow-task-service.js.map +1 -1
  61. package/docs/adoption-guide.md +22 -1
  62. package/docs/advisory-supervisor-architecture.md +206 -0
  63. package/docs/architecture.md +47 -41
  64. package/docs/autonomous-workflow.md +2 -2
  65. package/docs/backlog/ac-evidence-bugfix-stories-20260517.md +76 -0
  66. package/docs/backlog/dev-best-practices-hardening-story.md +69 -0
  67. package/docs/backlog/docs-public-internal-package-hygiene-story.md +62 -0
  68. package/docs/backlog/prompt-bank-registry-epic.md +159 -0
  69. package/docs/backlog/site-docs-manifest-story.md +56 -0
  70. package/docs/dev-team-specialist-role-profiles.md +1 -1
  71. package/docs/diagrams/diagram-master-prompt.md +207 -0
  72. package/docs/diagrams/enterprise-set/README.md +22 -0
  73. package/docs/diagrams/enterprise-set/lead-to-account-swimlanes.svg +38 -0
  74. package/docs/diagrams/enterprise-set/product-implementation-timeline.svg +45 -0
  75. package/docs/diagrams/enterprise-set/salesforce-enterprise-architecture.svg +54 -0
  76. package/docs/diagrams/experiments/pixel-v2-review.md +124 -0
  77. package/docs/diagrams/experiments/roadmap/diagram.mmd +14 -0
  78. package/docs/diagrams/experiments/roadmap/diagram.svg +48 -0
  79. package/docs/diagrams/experiments/roadmap/experiment.md +44 -0
  80. package/docs/diagrams/experiments/sfdc-implementation/diagram.mmd +54 -0
  81. package/docs/diagrams/experiments/sfdc-implementation/diagram.svg +72 -0
  82. package/docs/diagrams/experiments/sfdc-implementation/experiment.md +41 -0
  83. package/docs/diagrams/experiments/swimlane/diagram.mmd +40 -0
  84. package/docs/diagrams/experiments/swimlane/diagram.svg +70 -0
  85. package/docs/diagrams/experiments/swimlane/experiment.md +50 -0
  86. package/docs/diagrams/experiments/timeline/diagram.mmd +9 -0
  87. package/docs/diagrams/experiments/timeline/diagram.svg +29 -0
  88. package/docs/diagrams/experiments/timeline/experiment.md +34 -0
  89. package/docs/diagrams/final-artifact-hygiene.md +40 -0
  90. package/docs/diagrams/mermaid-target-strategy.md +106 -0
  91. package/docs/diagrams/payment-gateway/architecture.md +57 -0
  92. package/docs/diagrams/payment-gateway/architecture.mmd +39 -0
  93. package/docs/diagrams/payment-gateway/architecture.svg +171 -0
  94. package/docs/diagrams/prompt-bank.md +48 -0
  95. package/docs/diagrams/salesforce-integration/architecture.md +56 -0
  96. package/docs/diagrams/salesforce-integration/architecture.mmd +26 -0
  97. package/docs/diagrams/salesforce-integration/architecture.svg +123 -0
  98. package/docs/diagrams/source-fidelity-review.md +116 -0
  99. package/docs/diagrams/state-uml-recreated.drawio +336 -0
  100. package/docs/diagrams/state-uml-recreated.prompt.md +114 -0
  101. package/docs/diagrams/state-uml-recreated.prompt.v10.md +52 -0
  102. package/docs/diagrams/state-uml-recreated.prompt.v11.md +52 -0
  103. package/docs/diagrams/state-uml-recreated.prompt.v12.md +50 -0
  104. package/docs/diagrams/state-uml-recreated.prompt.v14.md +91 -0
  105. package/docs/diagrams/state-uml-recreated.prompt.v2.md +31 -0
  106. package/docs/diagrams/state-uml-recreated.prompt.v3.md +36 -0
  107. package/docs/diagrams/state-uml-recreated.prompt.v4.md +35 -0
  108. package/docs/diagrams/state-uml-recreated.prompt.v5.md +35 -0
  109. package/docs/diagrams/state-uml-recreated.prompt.v6.md +39 -0
  110. package/docs/diagrams/state-uml-recreated.prompt.v7.md +37 -0
  111. package/docs/diagrams/state-uml-recreated.prompt.v8.md +41 -0
  112. package/docs/diagrams/state-uml-recreated.prompt.v9.md +32 -0
  113. package/docs/diagrams/state-uml-recreated.svg +159 -0
  114. package/docs/diagrams/v14-stress-test/README.md +33 -0
  115. package/docs/diagrams/v14-stress-test/stress-test.svg +114 -0
  116. package/docs/external-artifact-import-bridge.md +56 -0
  117. package/docs/{setup-agents-applicability-review.md → external-baseline-applicability-review.md} +37 -40
  118. package/docs/{setup-agents-dogfooding-findings.md → external-baseline-dogfooding-findings.md} +10 -9
  119. package/docs/multi-agent-orchestrator-backlog.md +1 -1
  120. package/docs/orchestra-mvp.md +19 -0
  121. package/docs/persona-workflows.md +42 -0
  122. package/docs/release-test-matrix.md +21 -9
  123. package/docs/reports/ac-evidence-backfill-20260517.md +256 -0
  124. package/docs/reports/ac-evolution-reconciliation-20260517.md +366 -0
  125. package/docs/reports/ac-failure-evidence-20260517.md +115 -0
  126. package/docs/reports/ac-history-dry-run-20260517.md +434 -0
  127. package/docs/runtime-llm-flow.md +8 -0
  128. package/docs/site-content-workflow.md +96 -0
  129. package/docs/site-manifest.json +143 -0
  130. package/docs/skill-loading-strategy.md +18 -7
  131. package/docs/story-mapping-adoption-review.md +99 -0
  132. package/docs/workspace-repo-strategy.md +63 -0
  133. package/package.json +3 -1
  134. package/rules/agent-collaboration.mdc +2 -0
  135. package/rules/code-review-engineering.mdc +2 -0
  136. package/rules/delivery-quality-gates.mdc +12 -0
  137. package/rules/development-engineering.mdc +3 -0
  138. package/rules/diagram-quality.mdc +35 -0
  139. package/rules/module-boundaries.mdc +71 -0
  140. package/rules/testing-discipline.mdc +13 -0
  141. package/skills/collection-standards/SKILL.md +2 -0
  142. package/skills/diagram-export/SKILL.md +30 -0
  143. package/skills/qa-evidence-pack/SKILL.md +110 -0
  144. package/skills/qa-evidence-pack/manifest.json +60 -0
  145. package/docs/setup-agents-bridge.md +0 -61
@@ -0,0 +1,91 @@
1
+ # Prompt Version 14: Universal Diagram Acceptance Delta
2
+
3
+ Use this as a delta over the master diagram-generation prompt and later prompt
4
+ versions. This version defines generic acceptance rules that apply to every
5
+ generated diagram: architecture, workflow, state, sequence, infrastructure,
6
+ story maps, and recreated diagrams.
7
+
8
+ ## Append Lines
9
+
10
+ - Before accepting any rendered diagram, run a whole-canvas acceptance matrix:
11
+ labels, connectors, containers, long text, z-order, whitespace, and page
12
+ bounds must all pass together.
13
+ - Treat label-to-label collisions as failures. Labels need visible separation
14
+ from adjacent labels, connector strokes, arrowheads, symbols, cards, and
15
+ container borders.
16
+ - Do not use label backgrounds as a visual patch. A label background must not
17
+ cover, interrupt, hide, or visually erase the connector it describes. If a
18
+ background hides a stroke, move the label to a clear lane or reroute the
19
+ connector.
20
+ - Reserve connector label lanes before final routing. When labels compete for a
21
+ lane, assign separate lanes or move connected elements before adding
22
+ unnecessary bends.
23
+ - Long text must be layout-managed. Re-evaluate wrapping, line count, width, and
24
+ placement for every note, annotation, card title, legend item, and connector
25
+ label. Split text or reposition it when it crosses a connector, touches a
26
+ border, crowds another element, or invades a neighboring container.
27
+ - Text inside bounded elements must fit inside its own shape. This applies to
28
+ cards, chips, badges, pills, labels, legends, swimlane headers, callouts, and
29
+ connector-label boxes. If text grows beyond the available width, wraps poorly,
30
+ overlaps another element, or visually escapes its shape, split it into
31
+ multiple lines, grow the containing shape, or move the element before
32
+ accepting the render.
33
+ - Re-evaluate every bounded text element after wrapping. A wrapped label is only
34
+ valid if the resulting height still fits with padding and does not collide
35
+ with connectors, nearby labels, child nodes, or parent boundaries.
36
+ - Treat text wrapping as a geometry change, not as a text-only fix. After any
37
+ label, pill, badge, note, callout, or card text wraps to more lines,
38
+ recalculate the rendered bounding box and move the element before accepting
39
+ the render. The expanded box must not cover the connector, border, or element
40
+ it previously cleared.
41
+ - A connector label must clear the whole connector stroke after final wrapping,
42
+ including the label background and padding. If a two-line label overlaps the
43
+ stroke, arrowhead, or crossing point, move the label to a new lane or reroute
44
+ the connector.
45
+ - Prefer the simplest readable connector route. Use a straight line when the
46
+ source and target have clear line-of-sight; use one orthogonal bend when it
47
+ improves readability; use curves, multi-bend routes, or jumps only when they
48
+ avoid a real obstacle or crossing.
49
+ - Before keeping a curved connector, verify that a straight or orthogonal route
50
+ would collide with an element, label, boundary, or reserved lane. If no
51
+ collision exists, replace the curve with the simpler route.
52
+ - Connector intent must determine the endpoint. A connector targeting a group or
53
+ boundary stops at that boundary edge; a connector targeting a child element
54
+ must visibly attach to that child. Do not let connectors drift inside a
55
+ container unless the interior target is intentional and unambiguous.
56
+ - Validate parent containment using actual rendered bounds, not intended bounds.
57
+ Containers, swimlanes, groups, frames, and regions must contain all visible
58
+ children with padding after real labels, badges, notes, icons, internal
59
+ connectors, and arrowheads are placed.
60
+ - If any child element touches, crosses, or visually crowds its parent boundary,
61
+ grow the parent, move the child, or reflow neighboring regions. Do not accept
62
+ clipping or overflow as a styling choice.
63
+ - Re-render after every containment, wrapping, lane, or endpoint correction, then
64
+ inspect the whole canvas again. A local fix is incomplete until no new
65
+ collisions, hidden endpoints, or containment failures appear elsewhere.
66
+ - A regenerated version must change geometry when it is meant to fix a visual
67
+ finding. If the same collision, overflow, endpoint gap, or connector route
68
+ persists across versions, stop re-rendering and change the layout strategy:
69
+ move elements, grow containers, reserve a different lane, or reroute the
70
+ connector.
71
+
72
+ ## Validation Additions
73
+
74
+ - Record whether labels collide with other labels, connectors, arrowheads,
75
+ borders, cards, or notes.
76
+ - Record whether long text was wrapped, resized by container growth, moved, or
77
+ accepted as-is.
78
+ - Record whether bounded text elements fit inside their own shapes after final
79
+ wrapping and sizing.
80
+ - Record whether every wrapped bounded text element was repositioned or
81
+ revalidated against the connector lanes it may now occupy.
82
+ - Record whether each curved or multi-bend connector has a concrete obstacle
83
+ reason. If not, simplify the route before handoff.
84
+ - Record whether every connector endpoint matches its semantic target:
85
+ boundary, child node, symbol, lane, or external element.
86
+ - Record whether every parent container contains all visible children after
87
+ final sizing and reflow.
88
+ - Record which geometry changed between render passes for every accepted visual
89
+ correction. A version number without geometry change is not a valid fix.
90
+ - Record the final render pass number and the remaining known visual risks, if
91
+ any.
@@ -0,0 +1,31 @@
1
+ # Prompt Version 2: UML State Diagram Visual Correction Delta
2
+
3
+ Use this as a delta over `state-uml-recreated.prompt.md` after the first rendered
4
+ SVG/draw.io pass.
5
+
6
+ ## Append Lines
7
+
8
+ - Re-evaluate every container after rendering, because labels may make boxes too
9
+ short or visually unbalanced once the diagram is assembled.
10
+ - Prefer connector bend points that keep arrows outside containers and labels.
11
+ - Avoid vertical connector stubs when a small horizontal or orthogonal route reads
12
+ closer to the source diagram.
13
+ - Reposition arrowheads so they land on the intended shape boundary instead of
14
+ appearing deep inside the target container.
15
+ - Re-check spacing after resizing containers; container growth must not create
16
+ new overlaps or unclear routes.
17
+
18
+ ## Modify Lines
19
+
20
+ - Change `connector routing and bend points` to `connector routing, bend points,
21
+ and post-render adjustment against the source reference`.
22
+ - Change `final resizing after the diagram is assembled` to `final resizing and
23
+ visual balance pass after the diagram is assembled and rendered`.
24
+
25
+ ## Validation Additions
26
+
27
+ - Inspect the browser-rendered SVG screenshot before handoff.
28
+ - Compare each connector against the source PDF page and identify whether it
29
+ connects to the expected source and target element.
30
+ - Record any remaining approximation if the recreated diagram is not
31
+ pixel-perfect.
@@ -0,0 +1,36 @@
1
+ # Prompt Version 3: UML State Diagram Endpoint and Rotation Delta
2
+
3
+ Use this as a delta over `state-uml-recreated.prompt.md` after the second
4
+ rendered SVG/draw.io pass.
5
+
6
+ ## Append Lines
7
+
8
+ - Validate endpoint distance from source to target, so every connector visibly
9
+ touches both the origin and destination edges.
10
+ - For each connector, confirm the line starts at the visual boundary of the
11
+ source element and ends at the visual boundary of the intended target element.
12
+ - If a label such as `Radio`, `CD`, `on`, or `off` implies a specific target
13
+ state, the arrow must reach that state instead of stopping at the parent
14
+ container.
15
+ - Route arrows so they do not cover state labels or transition labels unless the
16
+ source diagram explicitly does so.
17
+ - Preserve rotated labels from the source diagram. When the source uses Lucid
18
+ style rotation values such as `270` or `-90`, map the same intent into draw.io
19
+ with `rotation=<degrees>` for rotated cells or `textRotation=<degrees>` when
20
+ only the label axis should rotate.
21
+
22
+ ## Modify Lines
23
+
24
+ - Change `arrows terminating at the intended connection edge, not deep inside
25
+ shapes` to `arrows visibly starting at the source edge and terminating at the
26
+ intended target edge, not floating near shapes or ending deep inside them`.
27
+ - Change `typography, label placement, and text wrapping` to `typography, label
28
+ placement, text wrapping, and source-matched text rotation`.
29
+
30
+ ## Validation Additions
31
+
32
+ - Perform a connector-by-connector source-to-target audit on the rendered
33
+ screenshot.
34
+ - Verify each transition label maps to the element it semantically references.
35
+ - Verify vertical or diagonal labels use explicit rotation values instead of
36
+ simulated line breaks or spacing.
@@ -0,0 +1,35 @@
1
+ # Prompt Version 4: UML State Diagram Label Clearance Delta
2
+
3
+ Use this as a delta over `state-uml-recreated.prompt.md` after the third
4
+ rendered SVG/draw.io pass.
5
+
6
+ ## Append Lines
7
+
8
+ - Validate label boundary clearance after rendering: every label needs a visible
9
+ margin from container borders, connector lines, and arrowheads.
10
+ - Labels must not sit directly on a shape boundary unless the source diagram
11
+ explicitly requires that overlap.
12
+ - Reposition transition labels that land on a container border after rendering.
13
+ - When edge labels cannot be positioned cleanly by the diagram tool, model them
14
+ as independent text elements so their placement can be controlled precisely.
15
+ - After every visual correction, re-render the SVG and inspect the screenshot
16
+ again before handoff.
17
+
18
+ ## Modify Lines
19
+
20
+ - Change `connector label avoidance: route arrows so they do not cover state
21
+ labels or transition labels unless the source diagram explicitly does so` to
22
+ `connector and label clearance: route arrows and labels so neither labels nor
23
+ connector lines sit on shape borders, arrowheads, or important text unless the
24
+ source diagram explicitly does so`.
25
+ - Change `final resizing and visual balance pass after the diagram is assembled
26
+ and rendered` to `final resizing, label clearance, and visual balance pass
27
+ after each render-correction cycle`.
28
+
29
+ ## Validation Additions
30
+
31
+ - Inspect each label against its nearest container border after rendering.
32
+ - Re-render after moving labels and compare the screenshot before treating the
33
+ diagram as ready.
34
+ - Record the correction if a label had to become an independent text element to
35
+ avoid edge-label placement issues.
@@ -0,0 +1,35 @@
1
+ # Prompt Version 5: UML State Diagram Element Ordering Delta
2
+
3
+ Use this as a delta over `state-uml-recreated.prompt.md` after the fourth
4
+ rendered SVG/draw.io pass.
5
+
6
+ ## Append Lines
7
+
8
+ - Validate element ordering and z-index after rendering.
9
+ - Draw large containers and state shapes first, then draw the connector lines
10
+ that connect them, then draw labels and annotations that must stay readable.
11
+ - A connector must not be hidden behind the element it connects. If the
12
+ arrowhead or endpoint disappears under the target element, reorder the element
13
+ layers or move the endpoint to the visible boundary.
14
+ - Preserve diagrams that already passed visual QA. When regenerating all
15
+ diagrams, do not regress previously accepted sections such as the v4
16
+ concurrent state diagram.
17
+ - Re-render the full SVG after z-order corrections and inspect every diagram,
18
+ not just the section that changed.
19
+
20
+ ## Modify Lines
21
+
22
+ - Change `final resizing, label clearance, and visual balance pass after each
23
+ render-correction cycle` to `final resizing, label clearance, z-order, and
24
+ visual balance pass after each render-correction cycle`.
25
+ - Change `Visual endpoint QA for every connector in the rendered screenshot` to
26
+ `Visual endpoint and z-order QA for every connector in the rendered
27
+ screenshot`.
28
+
29
+ ## Validation Additions
30
+
31
+ - Check every arrowhead against the target element boundary.
32
+ - Check every line segment that enters a connected element; it must remain
33
+ visible until the intended boundary point.
34
+ - If a shape overlaps a connector, decide whether the overlap is intentional. If
35
+ not intentional, fix the layer order, bend points, or endpoint.
@@ -0,0 +1,39 @@
1
+ # Prompt Version 6: UML State Diagram Connector Anchor Aesthetics Delta
2
+
3
+ Use this as a delta over `state-uml-recreated.prompt.md` after the fifth
4
+ rendered SVG/draw.io pass.
5
+
6
+ ## Append Lines
7
+
8
+ - Validate connector anchor-point aesthetics after rendering.
9
+ - Choose the source edge and target edge that create the shortest readable
10
+ orthogonal path with the fewest bend points.
11
+ - Prefer side midpoints when a side connection avoids extra turns that would be
12
+ required by a top or bottom connection.
13
+ - Do not force a connector to start from a top or bottom edge when the left or
14
+ right side of the source element produces a cleaner route.
15
+ - When two connector options both preserve semantic correctness, choose the one
16
+ with fewer 90-degree bends and less line travel.
17
+ - Arrowheads should land on a clean boundary point, commonly the midpoint of the
18
+ relevant side, without entering the target element interior.
19
+ - Re-render after anchor changes and verify the result against all previous
20
+ quality gates: endpoint, label clearance, z-order, text rotation, and
21
+ container overlap.
22
+
23
+ ## Modify Lines
24
+
25
+ - Change `connector routing, bend points, and post-render adjustment against the
26
+ source reference` to `connector routing, source/target anchor choice, bend
27
+ points, and post-render adjustment against the source reference`.
28
+ - Change `Visual endpoint and z-order QA for every connector in the rendered
29
+ screenshot` to `Visual endpoint, anchor-point, and z-order QA for every
30
+ connector in the rendered screenshot`.
31
+
32
+ ## Validation Additions
33
+
34
+ - Count bend points for each connector and compare against a cleaner route from
35
+ another edge.
36
+ - Check whether moving the source point to the nearest side midpoint reduces
37
+ bends without changing the semantic target.
38
+ - Check whether the target arrowhead lands at a side midpoint or other clean
39
+ boundary point instead of a corner or shape interior.
@@ -0,0 +1,37 @@
1
+ # Prompt Version 7: UML State Diagram Orthogonal Lines and Crossing Jumps Delta
2
+
3
+ Use this as a delta over `state-uml-recreated.prompt.md` after the sixth
4
+ rendered SVG/draw.io pass.
5
+
6
+ ## Append Lines
7
+
8
+ - Avoid diagonal connectors whenever an orthogonal route can preserve the same
9
+ semantic relationship.
10
+ - Prefer horizontal and vertical connector segments with explicit bend points
11
+ over diagonal connector segments.
12
+ - If two lines must cross, add a visible bridge or jump on the line that passes
13
+ over the other line.
14
+ - In SVG, represent line jumps with a small curve or arc at the crossing point.
15
+ - In draw.io, prefer editable line jump styles such as `jumpStyle=arc` and a
16
+ small jump size.
17
+ - Preserve accepted diagram sections unless the new orthogonal/crossing rule
18
+ identifies an actual visual defect.
19
+
20
+ ## Modify Lines
21
+
22
+ - Change `connector routing, source/target anchor choice, bend points, and
23
+ post-render adjustment against the source reference` to `orthogonal connector
24
+ routing, source/target anchor choice, bend points, crossing jumps, and
25
+ post-render adjustment against the source reference`.
26
+ - Change `Visual endpoint, anchor-point, and z-order QA for every connector` to
27
+ `Visual endpoint, anchor-point, z-order, diagonal, and crossing QA for every
28
+ connector`.
29
+
30
+ ## Validation Additions
31
+
32
+ - Inspect Shallow History and Entry/Exit Actions for diagonal connectors and
33
+ convert them to orthogonal routes where practical.
34
+ - Inspect every line intersection; if the crossing is unavoidable, add a
35
+ jump/bridge rather than allowing the two lines to visually merge.
36
+ - Re-render after orthogonal and crossing corrections, then verify no previous
37
+ accepted diagram section regressed.
@@ -0,0 +1,41 @@
1
+ # Prompt Version 8: UML State Diagram Layout Simplification Delta
2
+
3
+ Use this as a delta over `state-uml-recreated.prompt.md` after the seventh
4
+ rendered SVG/draw.io pass.
5
+
6
+ ## Append Lines
7
+
8
+ - Before accepting a connector bend, re-evaluate the positions of both connected
9
+ elements.
10
+ - If moving the source or target element slightly can remove a bend without
11
+ changing the meaning of the diagram, prefer the repositioned layout.
12
+ - Do not optimize a single connector at the cost of making surrounding
13
+ connectors worse; re-render and inspect the local neighborhood after moving an
14
+ element.
15
+ - Prefer aligned centers when a state and decision/gateway are conceptually
16
+ connected vertically.
17
+ - Keep editable draw.io XML and rendered SVG geometrically equivalent. If an
18
+ element, connector, label, or annotation moves in the SVG, the draw.io source
19
+ must carry the corresponding editable cell or edge.
20
+ - Preserve accepted sections unless the layout simplification reveals a concrete
21
+ visual defect.
22
+
23
+ ## Modify Lines
24
+
25
+ - Change `connector routing, source/target anchor choice, bend points, and
26
+ post-render adjustment against the source reference` to `connector routing,
27
+ element positioning, source/target anchor choice, bend points, and post-render
28
+ adjustment against the source reference`.
29
+ - Change `Visual anchor-point QA for every connector` to `Visual anchor-point and
30
+ element-position QA for every connector`.
31
+
32
+ ## Validation Additions
33
+
34
+ - For every connector with a bend, ask whether moving either connected element
35
+ could reduce the bend count.
36
+ - Verify the move does not introduce new overlaps, label collisions, hidden
37
+ endpoints, or additional bends elsewhere.
38
+ - Verify the draw.io XML contains the same moved elements, connectors, labels,
39
+ and annotations as the rendered SVG.
40
+ - Re-render after the repositioning and compare the local section against the
41
+ previous accepted render.
@@ -0,0 +1,32 @@
1
+ # Prompt Version 9: UML Annotation Target Clarity Delta
2
+
3
+ Use this as a delta over `state-uml-recreated.prompt.md` after the eighth
4
+ rendered SVG/draw.io pass.
5
+
6
+ ## Append Lines
7
+
8
+ - Every annotation arrow must have an explicit visual target. The arrowhead
9
+ should land on the annotated element boundary or on the specific line segment
10
+ being described.
11
+ - Annotation arrows must not disappear behind the element they annotate.
12
+ - Annotation labels must not cover state names, action text, connector labels,
13
+ or connector lines.
14
+ - If an annotation points to a state-internal action, prefer a direct vertical or
15
+ horizontal pointer and move the label to create enough room.
16
+ - If an annotation points to a transition line, place the arrowhead near the
17
+ line without hiding the line's semantic direction.
18
+ - Keep annotation labels and annotation arrows editable in draw.io when they are
19
+ present in the rendered SVG.
20
+
21
+ ## Modify Lines
22
+
23
+ - Change `label boundary clearance` to include annotation labels and annotation
24
+ arrows, not only state and transition labels.
25
+ - Change `editable/rendered equivalence` to require red annotation text and red
26
+ annotation arrows as editable draw.io cells when present in SVG.
27
+
28
+ ## Validation Additions
29
+
30
+ - For every red annotation, answer: what exact element or line does it annotate?
31
+ - Verify the arrowhead visibly reaches that exact target.
32
+ - Verify annotation labels do not obscure the target text or connector label.
@@ -0,0 +1,159 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="1180" height="1680" viewBox="0 0 1180 1680" role="img" aria-labelledby="title desc">
2
+ <title id="title">Recreated UML state diagram examples from downloaded PDF</title>
3
+ <desc id="desc">Three UML state diagram examples recreated as vector SVG: concurrent state, shallow history state, and entry exit action notation.</desc>
4
+ <defs>
5
+ <marker id="arrow" markerWidth="10" markerHeight="10" refX="8" refY="3" orient="auto" markerUnits="strokeWidth">
6
+ <path d="M0,0 L0,6 L9,3 z" fill="#222222" />
7
+ </marker>
8
+ <marker id="red-arrow" markerWidth="10" markerHeight="10" refX="8" refY="3" orient="auto" markerUnits="strokeWidth">
9
+ <path d="M0,0 L0,6 L9,3 z" fill="#e35c5c" />
10
+ </marker>
11
+ <style>
12
+ .panel { fill: #74c7ed; stroke: #222222; stroke-width: 2; }
13
+ .state { fill: #74c7ed; stroke: #222222; stroke-width: 2; }
14
+ .line { fill: none; stroke: #222222; stroke-width: 2; marker-end: url(#arrow); }
15
+ .plain-line { fill: none; stroke: #222222; stroke-width: 2; }
16
+ .region-line { stroke: #222222; stroke-width: 2; stroke-dasharray: 8 5; }
17
+ .label { font-family: Arial, Helvetica, sans-serif; font-size: 18px; fill: #1f2933; }
18
+ .small { font-family: Arial, Helvetica, sans-serif; font-size: 15px; fill: #1f2933; }
19
+ .tiny { font-family: Arial, Helvetica, sans-serif; font-size: 13px; fill: #1f2933; }
20
+ .red { font-family: Arial, Helvetica, sans-serif; font-weight: 700; font-size: 20px; fill: #e35c5c; }
21
+ .redline { fill: none; stroke: #e35c5c; stroke-width: 3; stroke-dasharray: 10 8; marker-end: url(#red-arrow); }
22
+ .section-title { font-family: Arial, Helvetica, sans-serif; font-weight: 700; font-size: 24px; fill: #1f2933; }
23
+ </style>
24
+ </defs>
25
+
26
+ <rect x="0" y="0" width="1180" height="1680" fill="#ffffff" />
27
+
28
+ <text x="40" y="44" class="section-title">Estado concurrente</text>
29
+ <g transform="translate(70 76)">
30
+ <rect x="110" y="0" width="500" height="360" rx="12" class="panel" />
31
+ <text x="360" y="18" text-anchor="middle" class="small">On</text>
32
+ <line x1="110" y1="120" x2="610" y2="120" class="plain-line" />
33
+ <line x1="110" y1="190" x2="610" y2="190" class="region-line" />
34
+
35
+ <rect x="190" y="88" width="150" height="62" rx="12" class="state" />
36
+ <text x="265" y="113" text-anchor="middle" class="small">Display Current</text>
37
+ <text x="265" y="136" text-anchor="middle" class="small">Time</text>
38
+
39
+ <rect x="370" y="88" width="150" height="62" rx="12" class="state" />
40
+ <text x="445" y="113" text-anchor="middle" class="small">Display Alarm</text>
41
+ <text x="445" y="136" text-anchor="middle" class="small">Time</text>
42
+
43
+ <path d="M110 120 H190" class="line" />
44
+ <text x="132" y="112" class="small">time</text>
45
+ <path d="M610 120 H520" class="line" />
46
+ <text x="548" y="112" class="small">alarm</text>
47
+
48
+ <circle cx="148" cy="270" r="14" fill="#74c7ed" stroke="#222222" stroke-width="2" />
49
+ <text x="148" y="276" text-anchor="middle" class="small">H</text>
50
+ <path d="M162 270 H220" class="line" />
51
+
52
+ <rect x="220" y="240" width="120" height="62" rx="12" class="state" />
53
+ <text x="280" y="265" text-anchor="middle" class="small">Playing Radio</text>
54
+
55
+ <rect x="370" y="240" width="120" height="62" rx="12" class="state" />
56
+ <text x="430" y="265" text-anchor="middle" class="small">Playing CD</text>
57
+
58
+ <path d="M292 469 H280 V302" class="line" />
59
+ <text x="286" y="338" class="label">Radio</text>
60
+ <path d="M392 438 V404 H430 V302" class="line" />
61
+ <text x="448" y="338" class="label">CD</text>
62
+
63
+ <rect x="292" y="438" width="170" height="62" rx="12" class="state" />
64
+ <text x="377" y="474" text-anchor="middle" class="label">Off</text>
65
+ <path d="M356 438 V360" class="line" />
66
+ <text x="368" y="414" class="small">on</text>
67
+ <path d="M462 360 V438" class="line" />
68
+ <text x="472" y="414" class="small">off</text>
69
+ </g>
70
+
71
+ <text x="40" y="650" class="section-title">Shallow history state</text>
72
+ <g transform="translate(60 685)">
73
+ <text x="98" y="34" class="red">State</text>
74
+ <path d="M130 48 V92" class="redline" />
75
+ <text x="245" y="-12" class="red">Shallow History State</text>
76
+ <path d="M365 0 V107" class="redline" />
77
+
78
+ <rect x="75" y="95" width="120" height="60" rx="10" class="state" />
79
+ <text x="135" y="130" text-anchor="middle" class="small">Command</text>
80
+ <rect x="330" y="48" width="290" height="350" rx="12" class="panel" />
81
+ <text x="475" y="66" text-anchor="middle" class="small">BackingUp</text>
82
+
83
+ <circle cx="370" cy="122" r="15" fill="#74c7ed" stroke="#222222" stroke-width="2" />
84
+ <text x="370" y="128" text-anchor="middle" class="small">H</text>
85
+ <rect x="455" y="95" width="120" height="60" rx="10" class="state" />
86
+ <text x="515" y="130" text-anchor="middle" class="small">Collecting</text>
87
+
88
+ <rect x="455" y="205" width="120" height="60" rx="10" class="state" />
89
+ <text x="515" y="240" text-anchor="middle" class="small">Copying</text>
90
+
91
+ <rect x="455" y="325" width="120" height="60" rx="10" class="state" />
92
+ <text x="515" y="360" text-anchor="middle" class="small">Cleaning Up</text>
93
+
94
+ <path d="M195 125 H355" class="line" />
95
+ <path d="M385 122 H455" class="line" />
96
+ <path d="M515 155 V205" class="line" />
97
+ <path d="M515 265 V325" class="line" />
98
+ <path d="M330 205 H150 V155" class="line" />
99
+ <text x="210" y="196" class="small">query</text>
100
+ <path d="M455 355 H120 V155" class="line" />
101
+
102
+ <text x="180" y="415" class="red">Transition</text>
103
+ <path d="M232 395 V366 C232 359 244 359 244 355 C244 351 232 351 232 344 V322" class="redline" />
104
+ </g>
105
+
106
+ <text x="40" y="1130" class="section-title">Acciones de entrada y salida</text>
107
+ <g transform="translate(55 1160)">
108
+ <text x="190" y="28" class="red">Initial Pseudo State</text>
109
+ <circle cx="430" cy="42" r="12" fill="#000000" />
110
+
111
+ <rect x="350" y="125" width="190" height="92" rx="10" class="state" />
112
+ <text x="445" y="144" text-anchor="middle" class="tiny">State</text>
113
+ <line x1="350" y1="150" x2="540" y2="150" class="plain-line" />
114
+ <text x="363" y="170" class="tiny">entry / Action 1_1</text>
115
+ <text x="363" y="190" class="tiny">do / Action 1_2</text>
116
+
117
+ <rect x="815" y="125" width="190" height="98" rx="10" class="state" />
118
+ <text x="910" y="144" text-anchor="middle" class="tiny">State2</text>
119
+ <line x1="815" y1="150" x2="1005" y2="150" class="plain-line" />
120
+ <text x="828" y="170" class="tiny">entry / Action 2_1</text>
121
+ <text x="828" y="190" class="tiny">Action 2_3 / defer</text>
122
+ <text x="828" y="210" class="tiny">exit / Action 2_2</text>
123
+ <polygon points="445,322 473,338 445,354 417,338" fill="#74c7ed" stroke="#222222" stroke-width="2" />
124
+ <circle cx="445" cy="438" r="14" fill="#ffffff" stroke="#000000" stroke-width="2" />
125
+ <circle cx="445" cy="438" r="9" fill="#000000" />
126
+
127
+ <rect x="575" y="295" width="190" height="88" rx="10" class="state" />
128
+ <text x="670" y="338" text-anchor="middle" class="tiny">State2</text>
129
+ <text x="588" y="354" class="tiny">entry / Action 3_1</text>
130
+
131
+ <path d="M430 54 V125" class="line" />
132
+ <path d="M540 166 H815" class="line" />
133
+ <text x="575" y="156" class="tiny">event [Guard1] / ActionA</text>
134
+ <path d="M445 322 V217" class="line" />
135
+ <text x="470" y="276" class="tiny">[Guard4]</text>
136
+ <path d="M445 354 V420" class="line" />
137
+ <text x="458" y="388" class="tiny">[Else]</text>
138
+ <path d="M815 175 H670 V295" class="line" />
139
+ <text x="690" y="270" class="tiny">[Guard3] / ActionB</text>
140
+ <path d="M1005 206 V338 H765" class="line" />
141
+ <text x="890" y="364" class="tiny">[Guard2]</text>
142
+ <path d="M575 338 H473" class="line" />
143
+
144
+ <text x="18" y="162" class="red">Entry action</text>
145
+ <path d="M188 158 H350" class="redline" />
146
+ <text x="268" y="248" class="red">Action in state</text>
147
+ <path d="M392 236 V198" class="redline" />
148
+ <text x="240" y="350" class="red">Decision</text>
149
+ <path d="M330 343 H417" class="redline" />
150
+ <text x="610" y="58" class="red">Transition</text>
151
+ <path d="M660 68 V148" class="redline" />
152
+ <text x="780" y="44" class="red">Triggered Action</text>
153
+ <path d="M905 54 V158" class="redline" />
154
+ <text x="1018" y="230" class="red">Exit action</text>
155
+ <path d="M1014 206 H946" class="redline" />
156
+ <text x="230" y="444" class="red">Final State</text>
157
+ <path d="M350 438 H431" class="redline" />
158
+ </g>
159
+ </svg>
@@ -0,0 +1,33 @@
1
+ # V14 Diagram Acceptance Stress Test
2
+
3
+ Task: DIAGRAM-V14-STRESS-TEST
4
+
5
+ ## Purpose
6
+
7
+ Validate generic v14 diagram rules against a source-free stress diagram with:
8
+
9
+ - bounded text inside chips, cards, labels, and notes;
10
+ - connector labels placed in clear lanes;
11
+ - parent containers sized around all visible children;
12
+ - boundary-target connectors that stop at container edges;
13
+ - long text split into multiple lines instead of crossing connectors or
14
+ neighboring containers.
15
+
16
+ ## Expected Visual Result
17
+
18
+ - No text escapes its own shape.
19
+ - No connector label hides a connector stroke or arrowhead.
20
+ - No two labels overlap each other.
21
+ - The parent containers contain all child cards and labels.
22
+ - The long note is wrapped and placed in whitespace.
23
+ - Boundary connectors terminate at the target boundary edge.
24
+ - Wrapped connector labels remain clear of the connector stroke after their
25
+ final two-line bounding box is known.
26
+ - Curved or multi-bend connectors are simplified when source and target have
27
+ clear line-of-sight.
28
+
29
+ ## Current Candidate
30
+
31
+ Render preview:
32
+
33
+ `output/diagram-experiments/v14-stress-test/preview-v3.png`