semiotic 3.8.6 → 3.8.7

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 (213) hide show
  1. package/CLAUDE.md +33 -7
  2. package/README.md +82 -55
  3. package/ai/behaviorContracts.cjs +86 -1
  4. package/ai/componentMetadata.cjs +4 -9
  5. package/ai/dist/mcp-server.js +97 -10
  6. package/ai/examples.md +154 -7
  7. package/ai/schema.json +1611 -145
  8. package/ai/surface-manifest.json +12 -10
  9. package/ai/system-prompt.md +9 -3
  10. package/dist/{chunk-chartContainerDataAudit-FEOD5GTQ.module.min.js → chunk-chartContainerDataAudit-JDSVSKGM.module.min.js} +1 -1
  11. package/dist/chunk-chunk-2YAZHXL4.module.min.js +2 -0
  12. package/dist/{chunk-chunk-G7WFWHAD.module.min.js → chunk-chunk-4ITOQRXM.module.min.js} +1 -1
  13. package/dist/chunk-chunk-5SD6BHVW.module.min.js +2 -0
  14. package/dist/chunk-chunk-6V5VQVCT.module.min.js +2 -0
  15. package/dist/chunk-chunk-7TTBHSAG.module.min.js +2 -0
  16. package/dist/chunk-chunk-7ZDJSYKI.module.min.js +2 -0
  17. package/dist/chunk-chunk-BGHPD3RA.module.min.js +1 -0
  18. package/dist/chunk-chunk-BMRZ2SPU.module.min.js +2 -0
  19. package/dist/chunk-chunk-BNGBEY7N.module.min.js +2 -0
  20. package/dist/chunk-chunk-C7APLVQD.module.min.js +2 -0
  21. package/dist/chunk-chunk-DGWFBOGB.module.min.js +1 -0
  22. package/dist/{chunk-chunk-Q2BS46W2.module.min.js → chunk-chunk-DIVE2DRA.module.min.js} +1 -1
  23. package/dist/chunk-chunk-FBUNUIPV.module.min.js +2 -0
  24. package/dist/chunk-chunk-FQPKOAIH.module.min.js +2 -0
  25. package/dist/chunk-chunk-FRO4TRXK.module.min.js +2 -0
  26. package/dist/chunk-chunk-G7QVPZUD.module.min.js +2 -0
  27. package/dist/chunk-chunk-GBPYV4FP.module.min.js +2 -0
  28. package/dist/chunk-chunk-GU2EJIDJ.module.min.js +2 -0
  29. package/dist/chunk-chunk-J5QD4RAM.module.min.js +2 -0
  30. package/dist/{chunk-chunk-RA7JCG7D.module.min.js → chunk-chunk-JWXLNZSM.module.min.js} +1 -1
  31. package/dist/chunk-chunk-KXAFCCDB.module.min.js +2 -0
  32. package/dist/chunk-chunk-LG7YKJAK.module.min.js +2 -0
  33. package/dist/{chunk-chunk-XP3OHHFX.module.min.js → chunk-chunk-LVHDZAT3.module.min.js} +1 -1
  34. package/dist/chunk-chunk-LWITSR2O.module.min.js +2 -0
  35. package/dist/{chunk-chunk-SMVD3EQJ.module.min.js → chunk-chunk-MX35T6RX.module.min.js} +1 -1
  36. package/dist/chunk-chunk-NH4MEAKP.module.min.js +2 -0
  37. package/dist/chunk-chunk-NJETWX42.module.min.js +2 -0
  38. package/dist/chunk-chunk-NW25WGLS.module.min.js +2 -0
  39. package/dist/{chunk-chunk-GFTVACTO.module.min.js → chunk-chunk-OI7R7EJB.module.min.js} +1 -1
  40. package/dist/{chunk-chunk-OM6NWS4H.module.min.js → chunk-chunk-ONMLEXHR.module.min.js} +1 -1
  41. package/dist/chunk-chunk-OY66GCE6.module.min.js +1 -0
  42. package/dist/chunk-chunk-PZFT457G.module.min.js +1 -0
  43. package/dist/chunk-chunk-Q3WW6JGR.module.min.js +1 -0
  44. package/dist/chunk-chunk-Q6XKQTOQ.module.min.js +1 -0
  45. package/dist/chunk-chunk-RJRM2E6P.module.min.js +1 -0
  46. package/dist/chunk-chunk-RPL7WYXI.module.min.js +1 -0
  47. package/dist/chunk-chunk-SV4XAZ3Q.module.min.js +1 -0
  48. package/dist/chunk-chunk-TSCFL235.module.min.js +1 -0
  49. package/dist/chunk-chunk-UOQRPGPK.module.min.js +2 -0
  50. package/dist/chunk-chunk-V3OAKG32.module.min.js +1 -0
  51. package/dist/chunk-chunk-WLOIUMWG.module.min.js +2 -0
  52. package/dist/chunk-chunk-XEGXX4F7.module.min.js +1 -0
  53. package/dist/chunk-chunk-XFRBLXYM.module.min.js +1 -0
  54. package/dist/chunk-chunk-Z2AJERX5.module.min.js +2 -0
  55. package/dist/chunk-chunk-ZXYDYAB7.module.min.js +2 -0
  56. package/dist/components/ai/SemioticVACPBridge.d.ts +22 -0
  57. package/dist/components/ai/chartCapabilities.d.ts +4 -3
  58. package/dist/components/ai/conversationArc.d.ts +2 -176
  59. package/dist/components/ai/conversationArcTypes.d.ts +202 -0
  60. package/dist/components/ai/readerGrounding.d.ts +12 -0
  61. package/dist/components/ai/vacpAdapter.d.ts +13 -0
  62. package/dist/components/ai/vacpAdapterActions.d.ts +2 -0
  63. package/dist/components/ai/vacpAdapterModel.d.ts +7 -0
  64. package/dist/components/ai/vacpAdapterRuntime.d.ts +26 -0
  65. package/dist/components/ai/vacpAdapterState.d.ts +3 -0
  66. package/dist/components/ai/vacpAdapterTypes.d.ts +169 -0
  67. package/dist/components/ai/vacpTypes.d.ts +160 -0
  68. package/dist/components/charts/index.d.ts +4 -4
  69. package/dist/components/charts/physics/ChainReactionChart.capability.d.ts +9 -0
  70. package/dist/components/charts/physics/ChainReactionChart.d.ts +29 -0
  71. package/dist/components/charts/physics/CollisionSwarmChart.d.ts +1 -1
  72. package/dist/components/charts/physics/EventDropChart.d.ts +7 -2
  73. package/dist/components/charts/physics/GaltonBoardChart.d.ts +1 -1
  74. package/dist/components/charts/physics/{PhysicsPileChart.capability.d.ts → PacketFlowChart.capability.d.ts} +1 -1
  75. package/dist/components/charts/physics/{PhysicalFlowChart.d.ts → PacketFlowChart.d.ts} +22 -6
  76. package/dist/components/charts/physics/PhysicsCustomChart.d.ts +1 -1
  77. package/dist/components/charts/physics/ProcessFlowChart.d.ts +7 -4
  78. package/dist/components/charts/physics/{PhysicalFlowChart.capability.d.ts → UnitPileChart.capability.d.ts} +1 -1
  79. package/dist/components/charts/physics/{PhysicsPileChart.d.ts → UnitPileChart.d.ts} +19 -6
  80. package/dist/components/charts/physics/crucibleChartProps.d.ts +1 -1
  81. package/dist/components/charts/physics/crucibleChartUtils.d.ts +9 -0
  82. package/dist/components/charts/physics/gauntletChartProps.d.ts +6 -1
  83. package/dist/components/charts/physics/gauntletTerminal.d.ts +61 -0
  84. package/dist/components/charts/physics/packetFlowSemantics.d.ts +6 -0
  85. package/dist/components/charts/physics/physicsHocUtils.d.ts +45 -2
  86. package/dist/components/charts/shared/auditAccessibilityStyles.d.ts +9 -0
  87. package/dist/components/charts/shared/knownChartComponents.d.ts +1 -1
  88. package/dist/components/charts/shared/useChartLegend.d.ts +8 -1
  89. package/dist/components/charts/shared/useChartSetup.d.ts +7 -0
  90. package/dist/components/data/portability/capabilityBinding.d.ts +41 -0
  91. package/dist/components/data/portability/index.d.ts +2 -0
  92. package/dist/components/legendLayout.d.ts +56 -0
  93. package/dist/components/recipes/geographicDotGrid.d.ts +82 -0
  94. package/dist/components/recipes/geographicGrid.d.ts +100 -0
  95. package/dist/components/recipes/physics.d.ts +2 -0
  96. package/dist/components/recipes/physicsStageGeography.d.ts +137 -0
  97. package/dist/components/semiotic-ai.d.ts +4 -3
  98. package/dist/components/semiotic-experimental-vacp.d.ts +11 -0
  99. package/dist/components/semiotic-experimental.d.ts +6 -3
  100. package/dist/components/semiotic-geo.d.ts +4 -0
  101. package/dist/components/semiotic-physics.d.ts +9 -6
  102. package/dist/components/semiotic-recipes-core.d.ts +6 -1
  103. package/dist/components/server/renderEvidence.d.ts +1 -1
  104. package/dist/components/server/renderToStaticSVG.d.ts +2 -1
  105. package/dist/components/server/serverChartConfigHeatmap.d.ts +6 -0
  106. package/dist/components/server/serverChartConfigNetworkStyles.d.ts +12 -0
  107. package/dist/components/server/serverChartConfigShared.d.ts +16 -0
  108. package/dist/components/server/serverChartConfigs.d.ts +2 -2
  109. package/dist/components/server/serverChartConfigsPhysics.d.ts +2 -2
  110. package/dist/components/server/serverChartConfigsXY.d.ts +0 -1
  111. package/dist/components/server/staticLegend.d.ts +6 -0
  112. package/dist/components/server/staticSVGChrome.d.ts +10 -2
  113. package/dist/components/server/staticValue.d.ts +8 -0
  114. package/dist/components/stream/geoPipelineConfig.d.ts +10 -0
  115. package/dist/components/stream/legendRenderer.d.ts +8 -0
  116. package/dist/components/stream/physics/PhysicsEvidence.d.ts +37 -0
  117. package/dist/components/stream/physics/PhysicsPipelineStore.d.ts +9 -0
  118. package/dist/components/stream/physics/PhysicsSettledScene.d.ts +5 -0
  119. package/dist/components/stream/physics/physicsFramePipelineConfig.d.ts +19 -0
  120. package/dist/components/stream/physics/physicsPipelineSettle.d.ts +52 -0
  121. package/dist/components/stream/physics/physicsRegionRuntime.d.ts +23 -0
  122. package/dist/components/stream/types.d.ts +2 -0
  123. package/dist/components/types/legendTypes.d.ts +17 -1
  124. package/dist/controls.min.js +1 -1
  125. package/dist/controls.module.min.js +1 -1
  126. package/dist/geo.min.js +1 -1
  127. package/dist/geo.module.min.js +1 -1
  128. package/dist/network.min.js +1 -1
  129. package/dist/network.module.min.js +1 -1
  130. package/dist/ordinal.min.js +1 -1
  131. package/dist/ordinal.module.min.js +1 -1
  132. package/dist/physics.min.js +1 -1
  133. package/dist/physics.module.min.js +1 -1
  134. package/dist/physicsWorker.js +1 -1
  135. package/dist/realtime.min.js +1 -1
  136. package/dist/realtime.module.min.js +1 -1
  137. package/dist/semiotic-ai-core.min.js +1 -1
  138. package/dist/semiotic-ai-core.module.min.js +1 -1
  139. package/dist/semiotic-ai.d.ts +4 -3
  140. package/dist/semiotic-ai.min.js +1 -1
  141. package/dist/semiotic-ai.module.min.js +1 -1
  142. package/dist/semiotic-data.module.min.js +1 -1
  143. package/dist/semiotic-experimental-vacp.d.ts +11 -0
  144. package/dist/semiotic-experimental-vacp.min.js +1 -0
  145. package/dist/semiotic-experimental-vacp.module.min.js +1 -0
  146. package/dist/semiotic-experimental.d.ts +6 -3
  147. package/dist/semiotic-experimental.min.js +2 -1
  148. package/dist/semiotic-experimental.module.min.js +2 -1
  149. package/dist/semiotic-geo.d.ts +4 -0
  150. package/dist/semiotic-physics.d.ts +9 -6
  151. package/dist/semiotic-realtime-core.min.js +1 -1
  152. package/dist/semiotic-realtime-core.module.min.js +1 -1
  153. package/dist/semiotic-recipes-core.d.ts +6 -1
  154. package/dist/semiotic-recipes-core.min.js +1 -1
  155. package/dist/semiotic-recipes-core.module.min.js +1 -1
  156. package/dist/semiotic-recipes.min.js +1 -1
  157. package/dist/semiotic-recipes.module.min.js +1 -1
  158. package/dist/semiotic-server-edge.min.js +1 -1
  159. package/dist/semiotic-server-edge.module.min.js +1 -1
  160. package/dist/semiotic-server-node.min.js +1 -1
  161. package/dist/semiotic-server-node.module.min.js +1 -1
  162. package/dist/semiotic-utils-core.min.js +1 -1
  163. package/dist/semiotic-utils-core.module.min.js +1 -1
  164. package/dist/semiotic-utils.min.js +1 -1
  165. package/dist/semiotic-utils.module.min.js +1 -1
  166. package/dist/semiotic.min.js +1 -1
  167. package/dist/semiotic.module.min.js +1 -1
  168. package/dist/server.min.js +1 -1
  169. package/dist/server.module.min.js +1 -1
  170. package/dist/xy.min.js +1 -1
  171. package/dist/xy.module.min.js +1 -1
  172. package/package.json +18 -2
  173. package/spec/README.md +94 -2
  174. package/spec/bindings/README.md +14 -3
  175. package/spec/v0.1/examples/annotation-provenance-reviewed-revision.json +27 -0
  176. package/spec/v0.1/examples/annotation-provenance-watcher-threshold.json +21 -0
  177. package/spec/v0.1/examples/audience-profile-executive-review.json +24 -0
  178. package/spec/v0.1/examples/audience-profile-incident-operators.json +42 -0
  179. package/spec/v0.1/examples/chart-capability-bar-comparison.json +48 -0
  180. package/spec/v0.1/examples/chart-capability-service-flow.json +54 -0
  181. package/dist/chunk-chunk-2CHN2TA3.module.min.js +0 -1
  182. package/dist/chunk-chunk-3SHB24AG.module.min.js +0 -1
  183. package/dist/chunk-chunk-4MMOOYTX.module.min.js +0 -2
  184. package/dist/chunk-chunk-5RKXZQ2P.module.min.js +0 -1
  185. package/dist/chunk-chunk-75OTQSXS.module.min.js +0 -1
  186. package/dist/chunk-chunk-7ALTGHK6.module.min.js +0 -1
  187. package/dist/chunk-chunk-A5GRQUOF.module.min.js +0 -1
  188. package/dist/chunk-chunk-AAF5LZAU.module.min.js +0 -2
  189. package/dist/chunk-chunk-ARZGA4LJ.module.min.js +0 -2
  190. package/dist/chunk-chunk-C4YA6TDR.module.min.js +0 -1
  191. package/dist/chunk-chunk-CAFLML4L.module.min.js +0 -2
  192. package/dist/chunk-chunk-CO5KQMGH.module.min.js +0 -1
  193. package/dist/chunk-chunk-FHBN7OEB.module.min.js +0 -2
  194. package/dist/chunk-chunk-GMQ5AYTD.module.min.js +0 -1
  195. package/dist/chunk-chunk-IP2UE74X.module.min.js +0 -1
  196. package/dist/chunk-chunk-ITDWLZXV.module.min.js +0 -2
  197. package/dist/chunk-chunk-JCG72SGW.module.min.js +0 -2
  198. package/dist/chunk-chunk-LPSPATPC.module.min.js +0 -1
  199. package/dist/chunk-chunk-PX5YQGDP.module.min.js +0 -2
  200. package/dist/chunk-chunk-QSQVBIJA.module.min.js +0 -1
  201. package/dist/chunk-chunk-RCF52Z42.module.min.js +0 -2
  202. package/dist/chunk-chunk-RNUHEXZA.module.min.js +0 -2
  203. package/dist/chunk-chunk-ROZWKEUG.module.min.js +0 -1
  204. package/dist/chunk-chunk-T2FKJD4O.module.min.js +0 -2
  205. package/dist/chunk-chunk-UDREYOLV.module.min.js +0 -1
  206. package/dist/chunk-chunk-VOWE3SAP.module.min.js +0 -2
  207. package/dist/chunk-chunk-VQPNBUSW.module.min.js +0 -2
  208. package/dist/chunk-chunk-WAWCIHFJ.module.min.js +0 -1
  209. package/dist/chunk-chunk-WYARAXHR.module.min.js +0 -2
  210. package/dist/chunk-chunk-XV3KGYTR.module.min.js +0 -2
  211. package/dist/chunk-chunk-YC2IVEPX.module.min.js +0 -1
  212. package/dist/chunk-chunk-ZOAQDIJO.module.min.js +0 -1
  213. package/dist/chunk-chunk-ZXIXAPRE.module.min.js +0 -2
@@ -6956,12 +6956,13 @@ var require_componentMetadata = __commonJS({
6956
6956
  physics: [
6957
6957
  "GaltonBoardChart",
6958
6958
  "EventDropChart",
6959
- "PhysicsPileChart",
6959
+ "UnitPileChart",
6960
6960
  "CollisionSwarmChart",
6961
- "PhysicalFlowChart",
6961
+ "PacketFlowChart",
6962
6962
  "ProcessFlowChart",
6963
6963
  "GauntletChart",
6964
- "CrucibleChart"
6964
+ "CrucibleChart",
6965
+ "ChainReactionChart"
6965
6966
  ],
6966
6967
  value: [
6967
6968
  "BigNumber"
@@ -6991,12 +6992,11 @@ var require_componentMetadata = __commonJS({
6991
6992
  const name = typeof entryOrName === "string" ? entryOrName : entryOrName.name;
6992
6993
  const category = categoryForComponent(name);
6993
6994
  const isPushOnly = category === "realtime" && name.startsWith("Realtime");
6994
- const isValueCategory = category === "value";
6995
6995
  return {
6996
6996
  name,
6997
6997
  category,
6998
6998
  importPath: importPathForCategory(category),
6999
- renderable: !isPushOnly && !isValueCategory,
6999
+ renderable: !isPushOnly,
7000
7000
  description: typeof entryOrName === "string" ? void 0 : entryOrName.description
7001
7001
  };
7002
7002
  }
@@ -7519,7 +7519,7 @@ var require_behaviorContracts = __commonJS({
7519
7519
  required: ["value"],
7520
7520
  staticRequired: ["value"],
7521
7521
  pushRequired: [],
7522
- summary: "GaugeChart is value-only. thresholds, min, max, sweep, and arcWidth are optional."
7522
+ summary: "GaugeChart is value-only. Its thresholds use { value, color, label? }; BigNumber thresholds use the distinct { at, level, color?, label? } vocabulary."
7523
7523
  },
7524
7524
  {
7525
7525
  component: "ForceDirectedGraph",
@@ -7557,7 +7557,16 @@ var require_behaviorContracts = __commonJS({
7557
7557
  "SankeyDiagram",
7558
7558
  "ChordDiagram",
7559
7559
  "ProportionalSymbolMap",
7560
- "DistanceCartogram"
7560
+ "DistanceCartogram",
7561
+ "GaltonBoardChart",
7562
+ "EventDropChart",
7563
+ "UnitPileChart",
7564
+ "CollisionSwarmChart",
7565
+ "PacketFlowChart",
7566
+ "ProcessFlowChart",
7567
+ "GauntletChart",
7568
+ "CrucibleChart",
7569
+ "ChainReactionChart"
7561
7570
  ];
7562
7571
  var STATIC_DATA_COMPONENTS = loadStaticDataComponentsFromSchema();
7563
7572
  var BEHAVIOR_CONTRACTS2 = [
@@ -7615,6 +7624,18 @@ var require_behaviorContracts = __commonJS({
7615
7624
  summary: "HOC push mode is selected by omitting the data prop entirely. Passing data={[]} is static empty data and can clear/reinitialize the frame on render.",
7616
7625
  agentAction: "For live charts, create a ref, omit data, then call ref.current.push() or pushMany(). For static renderChart/MCP snapshots, provide data because renderChart cannot push later."
7617
7626
  },
7627
+ {
7628
+ id: "streaming.serialized-proposal-snapshot",
7629
+ category: "streaming",
7630
+ title: "Serialized proposals keep the initial snapshot",
7631
+ severity: "warning",
7632
+ appliesTo: {
7633
+ components: PUSH_MODE_COMPONENTS
7634
+ },
7635
+ summary: "A JSON component/props proposal for MCP, SSR, or evaluation is a static snapshot even when the request mentions future pushes. Keep the supplied initial rows in the component's real data prop and do not invent pushRows, pushRequirement, ref, or method props.",
7636
+ agentAction: "Return renderable initial props in JSON. If the requested deliverable is React push code, separately omit the controlled data prop in JSX, attach a ref, and call the documented imperative method from an effect or event handler.",
7637
+ example: 'JSON snapshot: { "component": "LineChart", "props": { "data": [{"week":1,"users":120}], "xAccessor":"week", "yAccessor":"users" } }. React push code instead omits data and calls ref.current?.push(row).'
7638
+ },
7618
7639
  {
7619
7640
  id: "streaming.ref-mutations-require-id-accessors",
7620
7641
  category: "streaming",
@@ -7634,6 +7655,66 @@ var require_behaviorContracts = __commonJS({
7634
7655
  appliesTo: {},
7635
7656
  summary: "MCP renderChart and semiotic/server renderChart render a single static SVG/PNG snapshot. Browser-only realtime components and future ref pushes are not renderable through that path.",
7636
7657
  agentAction: "Use renderChart only with renderable HOC components and complete static data. For live behavior, return React code with a ref and do not promise MCP-rendered output."
7658
+ },
7659
+ {
7660
+ id: "serialization.formatters-are-react-callbacks",
7661
+ category: "serialization",
7662
+ title: "Axis formatters are React callbacks",
7663
+ severity: "error",
7664
+ appliesTo: {
7665
+ propsAny: ["xFormat", "yFormat", "categoryFormat", "valueFormat"]
7666
+ },
7667
+ summary: "xFormat, yFormat, categoryFormat, and valueFormat are callback props, not d3 format strings or axis-title strings. They are intentionally absent from JSON/MCP schemas and string values fail validation.",
7668
+ agentAction: "In serialized props, omit formatter callbacks and use xLabel, yLabel, categoryLabel, or valueLabel for axis titles. In React JSX, pass a function such as xFormat={value => formatAxis(value)}.",
7669
+ example: 'JSON: { "xLabel": "Payload (KB)", "yLabel": "Response time (ms)" }. React-only: xFormat={value => formatNumber(value, { maximumFractionDigits: 0 })}.'
7670
+ },
7671
+ {
7672
+ id: "value.bignumber-wire-contract",
7673
+ category: "value",
7674
+ title: "Value components do not inherit chart-HOC props",
7675
+ severity: "error",
7676
+ appliesTo: {
7677
+ components: ["BigNumber"]
7678
+ },
7679
+ summary: "BigNumber is a value component, not a chart HOC, so it does not inherit the common chart-HOC prop list. It uses label as its visible heading and supports description and summary; title and accessibleTable are invalid. Its percent format expects a ratio such as 0.97 and renders it as 97%.",
7680
+ agentAction: 'Validate BigNumber against its own prop schema and remove inherited chart-HOC props such as title and accessibleTable before returning a proposal. Use label, description, and summary for text. For a 97-of-100 KPI, either pass value={0.97} with format="percent" or pass value={97} with format="number" and suffix="%"; do not combine value={97} with format="percent".',
7681
+ example: '{ "component": "BigNumber", "props": { "value": 97, "label": "SLA attainment", "format": "number", "suffix": "%", "target": { "value": 99, "label": "target", "format": "number" } } }'
7682
+ },
7683
+ {
7684
+ id: "geo.proportional-symbol-wire-shape",
7685
+ category: "geo",
7686
+ title: "Proportional symbol maps use geographic props",
7687
+ severity: "error",
7688
+ appliesTo: {
7689
+ components: ["ProportionalSymbolMap"]
7690
+ },
7691
+ summary: "ProportionalSymbolMap reads point rows from points, longitude from xAccessor (default lon), latitude from yAccessor (default lat), and radius from sizeBy. sizeRange is the two-number pixel-radius range.",
7692
+ agentAction: "Use points, xAccessor, yAccessor, and sizeBy. Do not rename points to data or sizeBy to valueAccessor merely because the map renders circles.",
7693
+ example: '{ "points": [{"city":"A","longitude":-122.4,"latitude":37.8,"incidents":18}], "xAccessor":"longitude", "yAccessor":"latitude", "sizeBy":"incidents", "sizeRange":[5,40] }'
7694
+ },
7695
+ {
7696
+ id: "physics.sample-and-mechanical-inputs",
7697
+ category: "physics",
7698
+ title: "Physics charts separate chart mode from simulation input",
7699
+ severity: "warning",
7700
+ appliesTo: {
7701
+ components: ["GaltonBoardChart", "UnitPileChart", "CollisionSwarmChart"]
7702
+ },
7703
+ summary: `Sample simulations use data plus the chart's accessors. Seeded no-data demonstrations use simulationMode="mechanical" (legacy mode="mechanical" remains accepted); mode otherwise carries chart display modes such as primary or sparkline.`,
7704
+ agentAction: "For observed Galton values pass data + valueAccessor. For unit piles pass data + categoryAccessor + valueAccessor. Use seed for reproducibility, bins for Galton columns, and unitValue for the amount represented by one UnitPile body.",
7705
+ example: '{ "component": "GaltonBoardChart", "props": { "data": [{"id":"a","value":1}], "valueAccessor":"value", "bins":4, "seed":42 } }'
7706
+ },
7707
+ {
7708
+ id: "physics.push-uses-source-records",
7709
+ category: "physics",
7710
+ title: "Physics push methods ingest source records",
7711
+ severity: "error",
7712
+ appliesTo: {
7713
+ components: ["GaltonBoardChart", "EventDropChart", "UnitPileChart", "CollisionSwarmChart"]
7714
+ },
7715
+ summary: "Physics HOC refs push source records through the chart's accessors. pushRows and dataIdAccessor are not component props; stable source id fields are retained on spawned bodies without an invented accessor.",
7716
+ agentAction: "For React live code, call ref.current?.push(row) or pushMany(rows). For serialized snapshots, append the rows to data. Keep category/value/time accessors, but omit pushRows and dataIdAccessor.",
7717
+ example: 'ref.current?.push({ id: "c", team: "Blue", value: 2 }); <UnitPileChart ref={ref} categoryAccessor="team" valueAccessor="value" unitValue={1} />'
7637
7718
  }
7638
7719
  ];
7639
7720
  function hasOwn(value, key) {
@@ -7687,6 +7768,7 @@ var require_behaviorContracts = __commonJS({
7687
7768
  lines.push(` ${formatRequiredCombination(combo)}`);
7688
7769
  }
7689
7770
  }
7771
+ if (contract.example) lines.push(` Example: ${contract.example}`);
7690
7772
  lines.push(` Action: ${contract.agentAction}`);
7691
7773
  }
7692
7774
  return lines.join("\n");
@@ -7709,6 +7791,9 @@ var require_behaviorContracts = __commonJS({
7709
7791
  const combos = contract.combinations.map(formatRequiredCombination).join(" ");
7710
7792
  lines.push(` Required combinations: ${combos}`);
7711
7793
  }
7794
+ if (!compact && contract.example) {
7795
+ lines.push(` Example: \`${contract.example}\``);
7796
+ }
7712
7797
  }
7713
7798
  lines.push("", DOC_MARKER_END);
7714
7799
  return lines.join("\n");
@@ -33059,12 +33144,14 @@ var COMPONENT_REGISTRY = {
33059
33144
  DistanceCartogram: { component: import_geo.DistanceCartogram, category: "geo" },
33060
33145
  GaltonBoardChart: { component: import_ai.GaltonBoardChart, category: "physics" },
33061
33146
  EventDropChart: { component: import_ai.EventDropChart, category: "physics" },
33062
- PhysicsPileChart: { component: import_ai.PhysicsPileChart, category: "physics" },
33147
+ UnitPileChart: { component: import_ai.UnitPileChart, category: "physics" },
33063
33148
  CollisionSwarmChart: { component: import_ai.CollisionSwarmChart, category: "physics" },
33064
- PhysicalFlowChart: { component: import_ai.PhysicalFlowChart, category: "physics" },
33149
+ PacketFlowChart: { component: import_ai.PacketFlowChart, category: "physics" },
33065
33150
  ProcessFlowChart: { component: import_ai.ProcessFlowChart, category: "physics" },
33066
33151
  GauntletChart: { component: import_ai.GauntletChart, category: "physics" },
33067
- CrucibleChart: { component: import_ai.CrucibleChart, category: "physics" }
33152
+ CrucibleChart: { component: import_ai.CrucibleChart, category: "physics" },
33153
+ ChainReactionChart: { component: import_ai.ChainReactionChart, category: "physics" },
33154
+ BigNumber: { component: import_ai.BigNumber, category: "value" }
33068
33155
  };
33069
33156
 
33070
33157
  // ai/renderHOCToSVG.tsx
package/ai/examples.md CHANGED
@@ -57,6 +57,34 @@ const data = [
57
57
 
58
58
  Key props: `lineBy` groups flat array into separate lines, `colorBy` colors them
59
59
 
60
+ ### LineChart (dynamic value accessor)
61
+
62
+ When each row identifies which numeric field to plot, use an accessor function
63
+ instead of forcing the value through a single field name. This is especially
64
+ useful for multi-line data with a different metric per series.
65
+
66
+ ```jsx
67
+ import { LineChart } from "semiotic/ai"
68
+
69
+ const data = [
70
+ { timestamp: 1, metricLabel: "valueA", valueA: 12, valueB: 60 },
71
+ { timestamp: 2, metricLabel: "valueA", valueA: 18, valueB: 55 },
72
+ { timestamp: 1, metricLabel: "valueB", valueA: 12, valueB: 60 },
73
+ { timestamp: 2, metricLabel: "valueB", valueA: 18, valueB: 55 }
74
+ ]
75
+
76
+ <LineChart
77
+ data={data}
78
+ xAccessor="timestamp"
79
+ yAccessor={(d) => d[d.metricLabel]}
80
+ lineBy="metricLabel"
81
+ colorBy="metricLabel"
82
+ />
83
+ ```
84
+
85
+ Key props: accessors accept a field-name string or a function. Prefer a string
86
+ for a direct lookup; use a function for a computed or dynamic value.
87
+
60
88
  ### Scatterplot
61
89
 
62
90
  ```jsx
@@ -826,6 +854,33 @@ Key props: **`edges`** (required), shows bidirectional relationships in a circle
826
854
 
827
855
  ## Realtime — Push API via Ref
828
856
 
857
+ ### Serialized snapshot versus React push code
858
+
859
+ When an MCP, SSR, or evaluation request asks for component/props JSON and also
860
+ mentions future pushes, keep the supplied initial rows in the serialized
861
+ snapshot. `pushRows`, `pushRequirement`, `ref`, and `method` are orchestration
862
+ instructions, not chart props.
863
+
864
+ ```json
865
+ {
866
+ "component": "LineChart",
867
+ "props": {
868
+ "data": [
869
+ { "week": 1, "users": 120 },
870
+ { "week": 2, "users": 138 }
871
+ ],
872
+ "xAccessor": "week",
873
+ "yAccessor": "users",
874
+ "xLabel": "Week",
875
+ "yLabel": "Active users"
876
+ }
877
+ }
878
+ ```
879
+
880
+ React push code has a different lifecycle: omit `data`, attach a ref, and push
881
+ the initial or newly arrived rows from an effect. Formatter callbacks such as
882
+ `xFormat` are JSX-only; serialized axis titles belong in `xLabel` and `yLabel`.
883
+
829
884
  ### RealtimeLineChart
830
885
 
831
886
  ```jsx
@@ -1306,6 +1361,40 @@ Key APIs: `WordTrailsWordInfo` gives `word`, `column`, `weight`, and `segment` p
1306
1361
 
1307
1362
  ---
1308
1363
 
1364
+ ## Geographic Charts
1365
+
1366
+ ### ProportionalSymbolMap
1367
+
1368
+ ```jsx
1369
+ import { ProportionalSymbolMap } from "semiotic/geo"
1370
+
1371
+ const incidents = [
1372
+ { id: "a", city: "A", longitude: -122.4, latitude: 37.8, incidents: 18 },
1373
+ { id: "b", city: "B", longitude: -74.0, latitude: 40.7, incidents: 31 },
1374
+ { id: "c", city: "C", longitude: -87.6, latitude: 41.9, incidents: 12 },
1375
+ ]
1376
+
1377
+ <ProportionalSymbolMap
1378
+ points={incidents}
1379
+ xAccessor="longitude"
1380
+ yAccessor="latitude"
1381
+ sizeBy="incidents"
1382
+ sizeRange={[5, 40]}
1383
+ colorBy="city"
1384
+ showLegend
1385
+ />
1386
+ ```
1387
+
1388
+ The geographic wire vocabulary is deliberate: rows live in `points`,
1389
+ longitude and latitude use `xAccessor` and `yAccessor`, and symbol radius uses
1390
+ `sizeBy`. Do not substitute the generic `data` or `valueAccessor` names.
1391
+
1392
+ For live React code, omit `points` and push source records through the ref:
1393
+ `ref.current?.push({ id, longitude, latitude, incidents })`. For a static JSON
1394
+ snapshot, keep all observed records in `points`.
1395
+
1396
+ ---
1397
+
1309
1398
  ## Physics Charts — Motion With A Settled Projection
1310
1399
 
1311
1400
  ### GaltonBoardChart (distribution drop)
@@ -1352,12 +1441,12 @@ import { EventDropChart } from "semiotic/physics"
1352
1441
 
1353
1442
  Key props: `timeAccessor` assigns the event-time window, `arrivalAccessor` controls arrival replay, `windows.size` creates barriers, and `watermark.delay` sends late events to the late path.
1354
1443
 
1355
- ### PhysicsPileChart (unitized category piles)
1444
+ ### UnitPileChart (unitized category piles)
1356
1445
 
1357
1446
  ```jsx
1358
- import { PhysicsPileChart } from "semiotic/physics"
1447
+ import { UnitPileChart } from "semiotic/physics"
1359
1448
 
1360
- <PhysicsPileChart
1449
+ <UnitPileChart
1361
1450
  data={[
1362
1451
  { category: "Orders", value: 18 },
1363
1452
  { category: "Queued", value: 11 },
@@ -1373,6 +1462,34 @@ import { PhysicsPileChart } from "semiotic/physics"
1373
1462
 
1374
1463
  Key props: `unitValue` controls how many simulated bodies appear. Increase it for large values so the settled piles remain readable and the frame budget stays bounded.
1375
1464
 
1465
+ For a live unit pile, the ref ingests the same source-row shape the static
1466
+ `data` prop uses:
1467
+
1468
+ ```jsx
1469
+ import { useEffect, useRef } from "react"
1470
+ import { UnitPileChart } from "semiotic/physics"
1471
+
1472
+ const pileRef = useRef(null)
1473
+
1474
+ useEffect(() => {
1475
+ pileRef.current?.push({ id: "c", team: "Blue", value: 2 })
1476
+ }, [])
1477
+
1478
+ <UnitPileChart
1479
+ ref={pileRef}
1480
+ categoryAccessor="team"
1481
+ valueAccessor="value"
1482
+ unitValue={1}
1483
+ seed={42}
1484
+ title="Queued work by team"
1485
+ />
1486
+ ```
1487
+
1488
+ `pushRows` and `dataIdAccessor` are not physics chart props. Keep an `id` on
1489
+ source records when identity matters; the physics HOC retains it on the spawned
1490
+ bodies. For a static JSON proposal, append the incoming rows to `data` so the
1491
+ snapshot can render immediately.
1492
+
1376
1493
  ### CollisionSwarmChart (axis-preserving collision layout)
1377
1494
 
1378
1495
  ```jsx
@@ -1397,12 +1514,12 @@ import { CollisionSwarmChart } from "semiotic/physics"
1397
1514
  Key props: `xAccessor` preserves the quantitative position, `groupAccessor` creates lanes, and collision settings separate overlapping records without losing the axis.
1398
1515
 
1399
1516
 
1400
- ### PhysicalFlowChart (packet flow over routes)
1517
+ ### PacketFlowChart (packet flow over routes)
1401
1518
 
1402
1519
  ```jsx
1403
- import { PhysicalFlowChart } from "semiotic/physics"
1520
+ import { PacketFlowChart } from "semiotic/physics"
1404
1521
 
1405
- <PhysicalFlowChart
1522
+ <PacketFlowChart
1406
1523
  nodes={[
1407
1524
  { id: "Inbound", x: 0.08, y: 0.5 },
1408
1525
  { id: "Queue", x: 0.45, y: 0.32 },
@@ -1449,6 +1566,36 @@ import { ProcessFlowChart } from "semiotic/physics"
1449
1566
 
1450
1567
  Key props: `stages` declare force / capacity / absorb behavior, `groupBy` forms feature sockets that complete when every member is absorbed, and `liveCapacity` installs FIFO queue controllers for capacitated stages. Prefer ProcessFlowChart for many independent work items; use GauntletChart for one compound project degraded by gates.
1451
1568
 
1569
+ ### ChainReactionChart (dependency reach and blockers)
1570
+
1571
+ ```jsx
1572
+ import { ChainReactionChart } from "semiotic/physics"
1573
+
1574
+ const releaseTasks = [
1575
+ { id: "brief", title: "Brief", lane: "Product", dependsOn: [], status: "done", completedAt: 1 },
1576
+ { id: "privacy", title: "Privacy review", lane: "Product", dependsOn: ["brief"], status: "blocked", blocker: "Legal review" },
1577
+ { id: "schema", title: "Schema", lane: "Data", dependsOn: ["privacy"], status: "waiting" },
1578
+ { id: "ingest", title: "Ingest", lane: "Data", dependsOn: ["schema"], status: "waiting" },
1579
+ ]
1580
+
1581
+ <ChainReactionChart
1582
+ data={releaseTasks}
1583
+ taskIDAccessor="id"
1584
+ labelAccessor="title"
1585
+ laneAccessor="lane"
1586
+ dependencyAccessor="dependsOn"
1587
+ statusAccessor="status"
1588
+ completionTimeAccessor="completedAt"
1589
+ blockerAccessor="blocker"
1590
+ currentTime={10}
1591
+ mode="snapshot"
1592
+ insight="blocker-amplification"
1593
+ size={[800, 420]}
1594
+ />
1595
+ ```
1596
+
1597
+ Key props: `dependencyAccessor` must name explicit prerequisite ids — the chart never invents edges from a flat table. `statusAccessor` and `completionTimeAccessor` are authored task facts; delivery balls only enact satisfied prerequisites. Use `insight="blocker-amplification"` to expose how many unfinished downstream tasks and lanes each blocker reaches.
1598
+
1452
1599
  ### GauntletChart (compound project through timed gates)
1453
1600
 
1454
1601
  ```jsx
@@ -1590,7 +1737,7 @@ import { BigNumber } from "semiotic/value"
1590
1737
  />
1591
1738
  ```
1592
1739
 
1593
- Key props: `value` (the one number), `format` ("number"|"currency"|"percent"|"compact"|"duration"|fn), `comparison` derives a delta with auto-sentiment, `target` renders "X% of goal", `thresholds` map value to a semantic theme role (`--semiotic-{success|warning|danger|info}`). Suppress decoration via `mode="thumbnail"` for dense grids or `mode="inline"` for prose. Stream via `ref.current.push({ value, time })` — pair with `stalenessThreshold` to dim the card when updates stop.
1740
+ Key props: `value` (the focal number), `label` (the visible heading), `description` and `summary` (accessible text), `comparison`, `target`, and `thresholds`. BigNumber does not use chart-frame `title` or `accessibleTable` props. Built-in `format` values are `"number"`, `"currency"`, `"percent"`, `"compact"`, and `"duration"`; custom formatter functions are React-only. `"percent"` treats its input as a ratio, so `0.97` renders as 97%. For an existing 0–100 value such as 97, use `format="number"` with `suffix="%"`. Suppress decoration via `mode="thumbnail"` for dense grids or `mode="inline"` for prose. Stream via `ref.current.push({ value, time })` — pair with `stalenessThreshold` to dim the card when updates stop.
1594
1741
 
1595
1742
  ### BigNumber with a Semiotic chart embedded via `trendSlot` (wide / rectangular)
1596
1743