@almadar/std 16.243.0 → 16.244.1

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 (140) hide show
  1. package/behaviors/behaviors-registry.json +72537 -31220
  2. package/behaviors/lolo/agent/atoms/std-agent-context.lolo +24 -4
  3. package/behaviors/lolo/agent/atoms/std-agent-memory.lolo +20 -5
  4. package/behaviors/lolo/agent/atoms/std-agent-proposal.lolo +550 -0
  5. package/behaviors/lolo/agent/atoms/std-agent-session.lolo +284 -25
  6. package/behaviors/lolo/agent/atoms/std-agent-suggestions.lolo +841 -0
  7. package/behaviors/lolo/agent/atoms/std-agent-tool-loop.lolo +58 -8
  8. package/behaviors/lolo/agent/organisms/std-agent-assistant.lolo +1 -0
  9. package/behaviors/lolo/infra/atoms/std-page-treat.lolo +28 -1
  10. package/behaviors/lolo/ui/avl/atoms/ui-avl-state-machine.lolo +22 -0
  11. package/behaviors/lolo/ui/avl/atoms/ui-avl-transition-explainer.lolo +175 -0
  12. package/behaviors/lolo/ui/avl/atoms/ui-module-card.lolo +22 -0
  13. package/behaviors/lolo/ui/core/atoms/std-app-layout.lolo +23 -4
  14. package/behaviors/lolo/ui/core/atoms/std-hero.lolo +72 -33
  15. package/behaviors/lolo/ui/core/molecules/ui-agent-chat-feed.lolo +1 -1
  16. package/behaviors/lolo/ui/core/molecules/ui-markdown-content.lolo +54 -0
  17. package/behaviors/lolo/ui/core/molecules/ui-upload-drop-zone.lolo +5 -0
  18. package/behaviors/lolo/ui/core/organisms/ui-segment-renderer.lolo +127 -3
  19. package/behaviors/lolo/ui/core/organisms/ui-state-machine-view.lolo +22 -0
  20. package/behaviors/lolo/ui/core/templates/ui-dashboard-layout.lolo +2 -2
  21. package/behaviors/lolo/ui/learning/atoms/std-learn-arrangement.lolo +87 -17
  22. package/behaviors/lolo/ui/learning/atoms/std-learn-classify.lolo +172 -37
  23. package/behaviors/lolo/ui/learning/atoms/std-learn-coupled-sim.lolo +183 -70
  24. package/behaviors/lolo/ui/learning/atoms/std-learn-derivation.lolo +78 -13
  25. package/behaviors/lolo/ui/learning/atoms/std-learn-diagram.lolo +58 -2
  26. package/behaviors/lolo/ui/learning/atoms/std-learn-doser.lolo +107 -12
  27. package/behaviors/lolo/ui/learning/atoms/std-learn-estimate.lolo +83 -10
  28. package/behaviors/lolo/ui/learning/atoms/std-learn-goal-seek.lolo +130 -9
  29. package/behaviors/lolo/ui/learning/atoms/std-learn-grid-sim.lolo +143 -59
  30. package/behaviors/lolo/ui/learning/atoms/std-learn-hotspot.lolo +96 -22
  31. package/behaviors/lolo/ui/learning/atoms/std-learn-live-sim.lolo +66 -5
  32. package/behaviors/lolo/ui/learning/atoms/std-learn-predict.lolo +84 -6
  33. package/behaviors/lolo/ui/learning/atoms/std-learn-sandbox.lolo +80 -14
  34. package/behaviors/lolo/ui/learning/atoms/std-learn-scatter-fit.lolo +99 -5
  35. package/behaviors/lolo/ui/learning/atoms/std-learn-scenario.lolo +81 -7
  36. package/behaviors/lolo/ui/learning/atoms/std-learn-speed-drill.lolo +83 -7
  37. package/behaviors/lolo/ui/learning/atoms/std-learn-stepper.lolo +224 -99
  38. package/behaviors/lolo/ui/learning/atoms/std-learn-tour-3d.lolo +63 -2
  39. package/behaviors/lolo/ui/learning/atoms/std-learn-trace-player.lolo +99 -38
  40. package/behaviors/lolo/ui/learning/atoms/std-learn-transport.lolo +7 -7
  41. package/behaviors/lolo/ui/learning/atoms/std-learn-tree.lolo +69 -4
  42. package/behaviors/lolo-behavior-contracts.json +1 -1
  43. package/behaviors/registry/agent/atoms/std-agent-context.orb +205 -6
  44. package/behaviors/registry/agent/atoms/std-agent-memory.orb +146 -4
  45. package/behaviors/registry/agent/atoms/std-agent-proposal.orb +1972 -0
  46. package/behaviors/registry/agent/atoms/std-agent-session.orb +2021 -597
  47. package/behaviors/registry/agent/atoms/std-agent-suggestions.orb +5079 -0
  48. package/behaviors/registry/agent/atoms/std-agent-tool-loop.orb +287 -5
  49. package/behaviors/registry/agent/organisms/std-agent-assistant.orb +7 -0
  50. package/behaviors/registry/factory-signatures.json +1 -1
  51. package/behaviors/registry/infra/atoms/std-page-treat.orb +327 -2
  52. package/behaviors/registry/ui/avl/atoms/ui-avl-state-machine.orb +134 -0
  53. package/behaviors/registry/ui/avl/atoms/ui-avl-transition-explainer.orb +678 -0
  54. package/behaviors/registry/ui/avl/atoms/ui-module-card.orb +122 -0
  55. package/behaviors/registry/ui/core/atoms/std-app-layout.orb +73 -4
  56. package/behaviors/registry/ui/core/atoms/std-hero.orb +174 -97
  57. package/behaviors/registry/ui/core/molecules/ui-markdown-content.orb +204 -1
  58. package/behaviors/registry/ui/core/molecules/ui-upload-drop-zone.orb +12 -0
  59. package/behaviors/registry/ui/core/organisms/ui-segment-renderer.orb +683 -30
  60. package/behaviors/registry/ui/learning/atoms/std-learn-arrangement.orb +748 -21
  61. package/behaviors/registry/ui/learning/atoms/std-learn-classify.orb +1429 -41
  62. package/behaviors/registry/ui/learning/atoms/std-learn-coupled-sim.orb +1031 -185
  63. package/behaviors/registry/ui/learning/atoms/std-learn-derivation.orb +807 -132
  64. package/behaviors/registry/ui/learning/atoms/std-learn-diagram.orb +553 -6
  65. package/behaviors/registry/ui/learning/atoms/std-learn-doser.orb +987 -21
  66. package/behaviors/registry/ui/learning/atoms/std-learn-estimate.orb +582 -16
  67. package/behaviors/registry/ui/learning/atoms/std-learn-goal-seek.orb +954 -13
  68. package/behaviors/registry/ui/learning/atoms/std-learn-grid-sim.orb +828 -88
  69. package/behaviors/registry/ui/learning/atoms/std-learn-hotspot.orb +730 -28
  70. package/behaviors/registry/ui/learning/atoms/std-learn-live-sim.orb +479 -9
  71. package/behaviors/registry/ui/learning/atoms/std-learn-predict.orb +797 -46
  72. package/behaviors/registry/ui/learning/atoms/std-learn-sandbox.orb +757 -58
  73. package/behaviors/registry/ui/learning/atoms/std-learn-scatter-fit.orb +1176 -164
  74. package/behaviors/registry/ui/learning/atoms/std-learn-scenario.orb +599 -12
  75. package/behaviors/registry/ui/learning/atoms/std-learn-speed-drill.orb +832 -150
  76. package/behaviors/registry/ui/learning/atoms/std-learn-stepper.orb +1561 -127
  77. package/behaviors/registry/ui/learning/atoms/std-learn-tour-3d.orb +655 -6
  78. package/behaviors/registry/ui/learning/atoms/std-learn-trace-player.orb +634 -43
  79. package/behaviors/registry/ui/learning/atoms/std-learn-transport.orb +85 -31
  80. package/behaviors/registry/ui/learning/atoms/std-learn-tree.orb +425 -9
  81. package/canonical-operators.json +45 -2
  82. package/dist/behaviors/exports-reader.js +16667 -7868
  83. package/dist/behaviors/functions/index.d.ts +711 -32
  84. package/dist/behaviors/functions/index.js +16651 -7869
  85. package/dist/behaviors/index.d.ts +1 -1
  86. package/dist/behaviors/index.js +16668 -7869
  87. package/dist/behaviors/query.js +16667 -7868
  88. package/dist/behaviors-embeddings.hash.json +3 -3
  89. package/dist/behaviors-embeddings.json +77 -53
  90. package/dist/behaviors-registry.json +72537 -31220
  91. package/dist/index.d.ts +3 -3
  92. package/dist/index.js +16101 -7275
  93. package/dist/knob-embeddings.hash.json +3 -3
  94. package/dist/knob-embeddings.json +11617 -1225
  95. package/dist/modules/anim.d.ts +1 -1
  96. package/dist/modules/array.d.ts +1 -1
  97. package/dist/modules/async.d.ts +1 -1
  98. package/dist/modules/behavior.d.ts +1 -1
  99. package/dist/modules/browser.d.ts +1 -1
  100. package/dist/modules/composition.d.ts +1 -1
  101. package/dist/modules/contract.d.ts +1 -1
  102. package/dist/modules/core.d.ts +1 -1
  103. package/dist/modules/core.js +29 -2
  104. package/dist/modules/data.d.ts +1 -1
  105. package/dist/modules/ease.d.ts +1 -1
  106. package/dist/modules/format.d.ts +1 -1
  107. package/dist/modules/geo.d.ts +1 -1
  108. package/dist/modules/graph.d.ts +1 -1
  109. package/dist/modules/grid.d.ts +1 -1
  110. package/dist/modules/i18n.d.ts +1 -1
  111. package/dist/modules/index.d.ts +1 -1
  112. package/dist/modules/index.js +29 -2
  113. package/dist/modules/integration.d.ts +1 -1
  114. package/dist/modules/json.d.ts +1 -1
  115. package/dist/modules/llm.d.ts +1 -1
  116. package/dist/modules/math.d.ts +1 -1
  117. package/dist/modules/memory.d.ts +1 -1
  118. package/dist/modules/nn.d.ts +1 -1
  119. package/dist/modules/noise.d.ts +1 -1
  120. package/dist/modules/object.d.ts +1 -1
  121. package/dist/modules/os.d.ts +1 -1
  122. package/dist/modules/path.d.ts +1 -1
  123. package/dist/modules/prob.d.ts +1 -1
  124. package/dist/modules/session.d.ts +1 -1
  125. package/dist/modules/str.d.ts +1 -1
  126. package/dist/modules/tensor.d.ts +1 -1
  127. package/dist/modules/time.d.ts +1 -1
  128. package/dist/modules/trace.d.ts +1 -1
  129. package/dist/modules/train.d.ts +1 -1
  130. package/dist/modules/validate.d.ts +1 -1
  131. package/dist/modules/vector.d.ts +1 -1
  132. package/dist/modules/workspace.d.ts +1 -1
  133. package/dist/registry/factory-signatures.json +1 -1
  134. package/dist/registry.d.ts +2 -2
  135. package/dist/registry.js +29 -2
  136. package/dist/{types-Cdb321uM.d.ts → types-Y-yYWEOX.d.ts} +1 -1
  137. package/i18n/ar.json +3 -1
  138. package/i18n/en.json +2 -0
  139. package/i18n/sl.json +3 -1
  140. package/package.json +3 -3
@@ -91,6 +91,15 @@
91
91
  "parent": "trt_01M075812DYQGS8RJE0J3FWESF",
92
92
  "renames": []
93
93
  },
94
+ "evt_01M459WM5Z8JS6P7094FM192FF": {
95
+ "bakedName": "ROSTER_LOADED",
96
+ "curName": "ROSTER_LOADED",
97
+ "id": "evt_01M459WM5Z8JS6P7094FM192FF",
98
+ "kind": "event",
99
+ "owner": "workspace",
100
+ "parent": "trt_01M075812DYQGS8RJE0J3FWESF",
101
+ "renames": []
102
+ },
94
103
  "orb_01M075812DM89TK888P4V0J9PT": {
95
104
  "bakedName": "HotspotOrbital",
96
105
  "curName": "HotspotOrbital",
@@ -137,6 +146,69 @@
137
146
  "name": "title",
138
147
  "type": "string"
139
148
  },
149
+ {
150
+ "items": {
151
+ "properties": {
152
+ "color": {
153
+ "name": "color",
154
+ "required": false,
155
+ "type": "string"
156
+ },
157
+ "id": {
158
+ "name": "id",
159
+ "required": true,
160
+ "type": "string"
161
+ },
162
+ "label": {
163
+ "name": "label",
164
+ "required": true,
165
+ "type": "string"
166
+ },
167
+ "radius": {
168
+ "name": "radius",
169
+ "required": false,
170
+ "type": "number"
171
+ },
172
+ "x": {
173
+ "name": "x",
174
+ "required": true,
175
+ "type": "number"
176
+ },
177
+ "y": {
178
+ "name": "y",
179
+ "required": true,
180
+ "type": "number"
181
+ }
182
+ },
183
+ "type": "object"
184
+ },
185
+ "name": "shapes",
186
+ "type": "array"
187
+ },
188
+ {
189
+ "items": {
190
+ "properties": {
191
+ "explanation": {
192
+ "name": "explanation",
193
+ "required": false,
194
+ "type": "string"
195
+ },
196
+ "prompt": {
197
+ "name": "prompt",
198
+ "required": true,
199
+ "type": "string"
200
+ },
201
+ "targetId": {
202
+ "name": "targetId",
203
+ "required": true,
204
+ "type": "string"
205
+ }
206
+ },
207
+ "type": "object"
208
+ },
209
+ "name": "prompts",
210
+ "type": "array"
211
+ },
140
212
  {
141
213
  "default": 0.0,
142
214
  "name": "promptIndex",
@@ -373,6 +445,17 @@
373
445
  "tier": "presentation",
374
446
  "type": "string"
375
447
  },
448
+ "rosterSource": {
449
+ "default": "config",
450
+ "description": "Where the shapes and prompts roster comes from: config reads the shapes and prompts knobs at INIT; event waits for ROSTER_LOADED and takes the roster from its payload.",
451
+ "label": "Roster Source",
452
+ "tier": "domain",
453
+ "type": "string",
454
+ "values": [
455
+ "config",
456
+ "event"
457
+ ]
458
+ },
376
459
  "shapes": {
377
460
  "default": [
378
461
  {
@@ -530,10 +613,18 @@
530
613
  "kind": "set",
531
614
  "resource": "@entity.promptText"
532
615
  },
616
+ {
617
+ "kind": "set",
618
+ "resource": "@entity.prompts"
619
+ },
533
620
  {
534
621
  "kind": "set",
535
622
  "resource": "@entity.score"
536
623
  },
624
+ {
625
+ "kind": "set",
626
+ "resource": "@entity.shapes"
627
+ },
537
628
  {
538
629
  "kind": "set",
539
630
  "resource": "@entity.targetId"
@@ -641,7 +732,9 @@
641
732
  "found",
642
733
  "promptIndex",
643
734
  "promptText",
735
+ "prompts",
644
736
  "score",
737
+ "shapes",
645
738
  "targetId",
646
739
  "title",
647
740
  "totalPrompts",
@@ -679,6 +772,76 @@
679
772
  ],
680
773
  "tier": "domain"
681
774
  },
775
+ {
776
+ "description": "Runtime content feed, honoured only when rosterSource is event — mode names the instrument it is for (the matchMode it carries, blank when standalone), shapes is the hotspot roster and prompts the prompt list; a matching instrument re-initialises from it exactly as INIT does from config, any other instrument hides.",
777
+ "id": "evt_01M459WM5Z8JS6P7094FM192FF",
778
+ "key": "ROSTER_LOADED",
779
+ "name": "Roster Loaded",
780
+ "payloadSchema": [
781
+ {
782
+ "name": "mode",
783
+ "required": true,
784
+ "type": "string"
785
+ },
786
+ {
787
+ "name": "shapes",
788
+ "properties": [
789
+ {
790
+ "name": "id",
791
+ "required": true,
792
+ "type": "string"
793
+ },
794
+ {
795
+ "name": "label",
796
+ "required": true,
797
+ "type": "string"
798
+ },
799
+ {
800
+ "name": "x",
801
+ "required": true,
802
+ "type": "number"
803
+ },
804
+ {
805
+ "name": "y",
806
+ "required": true,
807
+ "type": "number"
808
+ },
809
+ {
810
+ "name": "radius",
811
+ "type": "number"
812
+ },
813
+ {
814
+ "name": "color",
815
+ "type": "string"
816
+ }
817
+ ],
818
+ "required": true,
819
+ "type": "[object]"
820
+ },
821
+ {
822
+ "name": "prompts",
823
+ "properties": [
824
+ {
825
+ "name": "prompt",
826
+ "required": true,
827
+ "type": "string"
828
+ },
829
+ {
830
+ "name": "targetId",
831
+ "required": true,
832
+ "type": "string"
833
+ },
834
+ {
835
+ "name": "explanation",
836
+ "type": "string"
837
+ }
838
+ ],
839
+ "required": true,
840
+ "type": "[object]"
841
+ }
842
+ ],
843
+ "tier": "domain"
844
+ },
682
845
  {
683
846
  "description": "Learner tapped a shape on the canvas — the canvas callback wraps its click info as payload { id, type, index }; the id names the hotspot (or its label) and the tap is judged against the current prompt's target.",
684
847
  "id": "evt_01M075812JEJR3YKZ3EVCXYZ6W",
@@ -805,6 +968,16 @@
805
968
  "transitions": [
806
969
  {
807
970
  "effects": [
971
+ [
972
+ "set",
973
+ "@entity.shapes",
974
+ "@config.shapes"
975
+ ],
976
+ [
977
+ "set",
978
+ "@entity.prompts",
979
+ "@config.prompts"
980
+ ],
808
981
  [
809
982
  "let",
810
983
  [
@@ -812,7 +985,7 @@
812
985
  "first",
813
986
  [
814
987
  "array/nth",
815
- "@config.prompts",
988
+ "@entity.prompts",
816
989
  0.0
817
990
  ]
818
991
  ],
@@ -820,7 +993,7 @@
820
993
  "circles",
821
994
  [
822
995
  "array/map",
823
- "@config.shapes",
996
+ "@entity.shapes",
824
997
  [
825
998
  "fn",
826
999
  "s",
@@ -868,7 +1041,7 @@
868
1041
  "labels",
869
1042
  [
870
1043
  "array/map",
871
- "@config.shapes",
1044
+ "@entity.shapes",
872
1045
  [
873
1046
  "fn",
874
1047
  "s",
@@ -938,7 +1111,7 @@
938
1111
  "@entity.totalPrompts",
939
1112
  [
940
1113
  "array/len",
941
- "@config.prompts"
1114
+ "@entity.prompts"
942
1115
  ]
943
1116
  ],
944
1117
  [
@@ -1226,9 +1399,17 @@
1226
1399
  "eventId": "evt_01M075812D7NCEX7G3TP34MXBS",
1227
1400
  "from": "idle",
1228
1401
  "guard": [
1229
- "==",
1230
- "@config.matchMode",
1231
- ""
1402
+ "and",
1403
+ [
1404
+ "==",
1405
+ "@config.matchMode",
1406
+ ""
1407
+ ],
1408
+ [
1409
+ "==",
1410
+ "@config.rosterSource",
1411
+ "config"
1412
+ ]
1232
1413
  ],
1233
1414
  "to": "idle"
1234
1415
  },
@@ -1271,6 +1452,16 @@
1271
1452
  },
1272
1453
  {
1273
1454
  "effects": [
1455
+ [
1456
+ "set",
1457
+ "@entity.shapes",
1458
+ "@config.shapes"
1459
+ ],
1460
+ [
1461
+ "set",
1462
+ "@entity.prompts",
1463
+ "@config.prompts"
1464
+ ],
1274
1465
  [
1275
1466
  "let",
1276
1467
  [
@@ -1278,7 +1469,7 @@
1278
1469
  "first",
1279
1470
  [
1280
1471
  "array/nth",
1281
- "@config.prompts",
1472
+ "@entity.prompts",
1282
1473
  0.0
1283
1474
  ]
1284
1475
  ],
@@ -1286,7 +1477,7 @@
1286
1477
  "circles",
1287
1478
  [
1288
1479
  "array/map",
1289
- "@config.shapes",
1480
+ "@entity.shapes",
1290
1481
  [
1291
1482
  "fn",
1292
1483
  "s",
@@ -1334,7 +1525,7 @@
1334
1525
  "labels",
1335
1526
  [
1336
1527
  "array/map",
1337
- "@config.shapes",
1528
+ "@entity.shapes",
1338
1529
  [
1339
1530
  "fn",
1340
1531
  "s",
@@ -1404,7 +1595,7 @@
1404
1595
  "@entity.totalPrompts",
1405
1596
  [
1406
1597
  "array/len",
1407
- "@config.prompts"
1598
+ "@entity.prompts"
1408
1599
  ]
1409
1600
  ],
1410
1601
  [
@@ -1692,9 +1883,520 @@
1692
1883
  "eventId": "evt_01M075812JWBR49NJTVRXS2MWY",
1693
1884
  "from": "idle",
1694
1885
  "guard": [
1695
- "==",
1696
- "@payload.mode",
1697
- "@config.matchMode"
1886
+ "and",
1887
+ [
1888
+ "==",
1889
+ "@payload.mode",
1890
+ "@config.matchMode"
1891
+ ],
1892
+ [
1893
+ "==",
1894
+ "@config.rosterSource",
1895
+ "config"
1896
+ ]
1897
+ ],
1898
+ "to": "idle"
1899
+ },
1900
+ {
1901
+ "effects": [
1902
+ [
1903
+ "set",
1904
+ "@entity.shapes",
1905
+ "@payload.shapes"
1906
+ ],
1907
+ [
1908
+ "set",
1909
+ "@entity.prompts",
1910
+ "@payload.prompts"
1911
+ ],
1912
+ [
1913
+ "let",
1914
+ [
1915
+ [
1916
+ "first",
1917
+ [
1918
+ "array/nth",
1919
+ "@entity.prompts",
1920
+ 0.0
1921
+ ]
1922
+ ],
1923
+ [
1924
+ "circles",
1925
+ [
1926
+ "array/map",
1927
+ "@entity.shapes",
1928
+ [
1929
+ "fn",
1930
+ "s",
1931
+ {
1932
+ "fillStyle": "solid",
1933
+ "fillTone": [
1934
+ "object/get",
1935
+ "@s",
1936
+ "color",
1937
+ "series-1"
1938
+ ],
1939
+ "id": [
1940
+ "object/get",
1941
+ "@s",
1942
+ "id"
1943
+ ],
1944
+ "radius": [
1945
+ "object/get",
1946
+ "@s",
1947
+ "radius",
1948
+ 22.0
1949
+ ],
1950
+ "tone": [
1951
+ "object/get",
1952
+ "@s",
1953
+ "color",
1954
+ "series-1"
1955
+ ],
1956
+ "type": "circle",
1957
+ "x": [
1958
+ "object/get",
1959
+ "@s",
1960
+ "x"
1961
+ ],
1962
+ "y": [
1963
+ "object/get",
1964
+ "@s",
1965
+ "y"
1966
+ ]
1967
+ }
1968
+ ]
1969
+ ]
1970
+ ],
1971
+ [
1972
+ "labels",
1973
+ [
1974
+ "array/map",
1975
+ "@entity.shapes",
1976
+ [
1977
+ "fn",
1978
+ "s",
1979
+ {
1980
+ "align": "center",
1981
+ "id": [
1982
+ "str/concat",
1983
+ "label-",
1984
+ [
1985
+ "object/get",
1986
+ "@s",
1987
+ "id"
1988
+ ]
1989
+ ],
1990
+ "text": [
1991
+ "object/get",
1992
+ "@s",
1993
+ "label"
1994
+ ],
1995
+ "textSize": "xs",
1996
+ "tone": "label",
1997
+ "type": "text",
1998
+ "x": [
1999
+ "object/get",
2000
+ "@s",
2001
+ "x"
2002
+ ],
2003
+ "y": [
2004
+ "+",
2005
+ [
2006
+ "object/get",
2007
+ "@s",
2008
+ "y"
2009
+ ],
2010
+ [
2011
+ "object/get",
2012
+ "@s",
2013
+ "radius",
2014
+ 22.0
2015
+ ],
2016
+ 14.0
2017
+ ]
2018
+ }
2019
+ ]
2020
+ ]
2021
+ ]
2022
+ ],
2023
+ [
2024
+ "do",
2025
+ [
2026
+ "set",
2027
+ "@entity.active",
2028
+ true
2029
+ ],
2030
+ [
2031
+ "set",
2032
+ "@entity.title",
2033
+ "@config.title"
2034
+ ],
2035
+ [
2036
+ "set",
2037
+ "@entity.promptIndex",
2038
+ 0.0
2039
+ ],
2040
+ [
2041
+ "set",
2042
+ "@entity.totalPrompts",
2043
+ [
2044
+ "array/len",
2045
+ "@entity.prompts"
2046
+ ]
2047
+ ],
2048
+ [
2049
+ "set",
2050
+ "@entity.score",
2051
+ 0.0
2052
+ ],
2053
+ [
2054
+ "set",
2055
+ "@entity.tries",
2056
+ 0.0
2057
+ ],
2058
+ [
2059
+ "set",
2060
+ "@entity.found",
2061
+ false
2062
+ ],
2063
+ [
2064
+ "set",
2065
+ "@entity.done",
2066
+ false
2067
+ ],
2068
+ [
2069
+ "set",
2070
+ "@entity.promptText",
2071
+ [
2072
+ "object/get",
2073
+ "@first",
2074
+ "prompt"
2075
+ ]
2076
+ ],
2077
+ [
2078
+ "set",
2079
+ "@entity.targetId",
2080
+ [
2081
+ "object/get",
2082
+ "@first",
2083
+ "targetId"
2084
+ ]
2085
+ ],
2086
+ [
2087
+ "set",
2088
+ "@entity.explanation",
2089
+ [
2090
+ "object/get",
2091
+ "@first",
2092
+ "explanation",
2093
+ ""
2094
+ ]
2095
+ ],
2096
+ [
2097
+ "set",
2098
+ "@entity.feedback",
2099
+ ""
2100
+ ],
2101
+ [
2102
+ "set",
2103
+ "@entity.canvasShapes",
2104
+ [
2105
+ "array/concat",
2106
+ "@circles",
2107
+ "@labels"
2108
+ ]
2109
+ ],
2110
+ [
2111
+ "set",
2112
+ "@entity.view",
2113
+ [
2114
+ {
2115
+ "children": [
2116
+ {
2117
+ "content": "@entity.promptText",
2118
+ "type": "typography",
2119
+ "variant": "body"
2120
+ }
2121
+ ],
2122
+ "padding": "md",
2123
+ "type": "card",
2124
+ "variant": "bordered"
2125
+ },
2126
+ {
2127
+ "animate": false,
2128
+ "backgroundColor": "@config.backgroundColor",
2129
+ "height": "@config.height",
2130
+ "interactive": true,
2131
+ "keyMap": {
2132
+ "ArrowRight": "NEXT",
2133
+ "KeyR": "RETRY",
2134
+ "Space": "NEXT"
2135
+ },
2136
+ "onShapeClick": "TAP_SHAPE",
2137
+ "shapes": "@entity.canvasShapes",
2138
+ "type": "learning-canvas",
2139
+ "width": "@config.width"
2140
+ },
2141
+ {
2142
+ "children": [
2143
+ {
2144
+ "content": "@entity.feedback",
2145
+ "type": "typography",
2146
+ "variant": "body"
2147
+ }
2148
+ ],
2149
+ "direction": "horizontal",
2150
+ "gap": "xs",
2151
+ "type": "stack"
2152
+ },
2153
+ {
2154
+ "align": "center",
2155
+ "children": [
2156
+ {
2157
+ "action": "NEXT",
2158
+ "disabled": [
2159
+ "if",
2160
+ "@entity.found",
2161
+ false,
2162
+ true
2163
+ ],
2164
+ "icon": "chevron-right",
2165
+ "label": "@config.nextLabel",
2166
+ "type": "button",
2167
+ "variant": "primary"
2168
+ },
2169
+ {
2170
+ "color": "muted",
2171
+ "content": [
2172
+ "str/concat",
2173
+ "First-try ",
2174
+ "@entity.score",
2175
+ " of ",
2176
+ "@entity.totalPrompts"
2177
+ ],
2178
+ "type": "typography",
2179
+ "variant": "caption"
2180
+ }
2181
+ ],
2182
+ "direction": "horizontal",
2183
+ "gap": "sm",
2184
+ "type": "stack",
2185
+ "wrap": true
2186
+ }
2187
+ ]
2188
+ ]
2189
+ ]
2190
+ ],
2191
+ [
2192
+ "render-ui",
2193
+ "main",
2194
+ {
2195
+ "children": [
2196
+ {
2197
+ "children": [
2198
+ {
2199
+ "align": "start",
2200
+ "children": [
2201
+ {
2202
+ "children": [
2203
+ {
2204
+ "content": "@entity.title",
2205
+ "type": "typography",
2206
+ "variant": "h4"
2207
+ },
2208
+ [
2209
+ "if",
2210
+ [
2211
+ "==",
2212
+ "@config.summary",
2213
+ ""
2214
+ ],
2215
+ null,
2216
+ {
2217
+ "color": "muted",
2218
+ "content": "@config.summary",
2219
+ "type": "typography",
2220
+ "variant": "body2"
2221
+ }
2222
+ ]
2223
+ ],
2224
+ "direction": "vertical",
2225
+ "gap": "xs",
2226
+ "type": "stack"
2227
+ },
2228
+ {
2229
+ "label": [
2230
+ "if",
2231
+ "@entity.done",
2232
+ "Round complete",
2233
+ [
2234
+ "if",
2235
+ "@entity.found",
2236
+ "Correct",
2237
+ [
2238
+ "if",
2239
+ [
2240
+ ">",
2241
+ "@entity.tries",
2242
+ 0.0
2243
+ ],
2244
+ "Try again",
2245
+ [
2246
+ "str/concat",
2247
+ "Score ",
2248
+ "@entity.score",
2249
+ " / ",
2250
+ "@entity.totalPrompts"
2251
+ ]
2252
+ ]
2253
+ ]
2254
+ ],
2255
+ "type": "badge",
2256
+ "variant": [
2257
+ "if",
2258
+ "@entity.done",
2259
+ "primary",
2260
+ [
2261
+ "if",
2262
+ "@entity.found",
2263
+ "success",
2264
+ [
2265
+ "if",
2266
+ [
2267
+ ">",
2268
+ "@entity.tries",
2269
+ 0.0
2270
+ ],
2271
+ "error",
2272
+ "neutral"
2273
+ ]
2274
+ ]
2275
+ ]
2276
+ }
2277
+ ],
2278
+ "direction": "horizontal",
2279
+ "gap": "md",
2280
+ "justify": "between",
2281
+ "type": "stack"
2282
+ },
2283
+ {
2284
+ "label": [
2285
+ "str/concat",
2286
+ "Prompt ",
2287
+ [
2288
+ "str/concat",
2289
+ "",
2290
+ [
2291
+ "+",
2292
+ "@entity.promptIndex",
2293
+ 1.0
2294
+ ]
2295
+ ],
2296
+ " of ",
2297
+ [
2298
+ "str/concat",
2299
+ "",
2300
+ "@entity.totalPrompts"
2301
+ ]
2302
+ ],
2303
+ "max": "@entity.totalPrompts",
2304
+ "showPercentage": false,
2305
+ "type": "progress-bar",
2306
+ "value": [
2307
+ "+",
2308
+ "@entity.promptIndex",
2309
+ 1.0
2310
+ ]
2311
+ },
2312
+ {
2313
+ "children": "@entity.view",
2314
+ "direction": "vertical",
2315
+ "gap": "md",
2316
+ "type": "stack"
2317
+ }
2318
+ ],
2319
+ "direction": "vertical",
2320
+ "gap": "md",
2321
+ "type": "stack"
2322
+ }
2323
+ ],
2324
+ "padding": "md",
2325
+ "type": "box"
2326
+ }
2327
+ ]
2328
+ ],
2329
+ "event": "ROSTER_LOADED",
2330
+ "eventId": "evt_01M459WM5Z8JS6P7094FM192FF",
2331
+ "from": "idle",
2332
+ "guard": [
2333
+ "and",
2334
+ [
2335
+ "==",
2336
+ "@config.rosterSource",
2337
+ "event"
2338
+ ],
2339
+ [
2340
+ "and",
2341
+ [
2342
+ "==",
2343
+ "@payload.mode",
2344
+ "@config.matchMode"
2345
+ ],
2346
+ [
2347
+ "and",
2348
+ [
2349
+ ">",
2350
+ [
2351
+ "array/len",
2352
+ "@payload.shapes"
2353
+ ],
2354
+ 0.0
2355
+ ],
2356
+ [
2357
+ ">",
2358
+ [
2359
+ "array/len",
2360
+ "@payload.prompts"
2361
+ ],
2362
+ 0.0
2363
+ ]
2364
+ ]
2365
+ ]
2366
+ ],
2367
+ "to": "idle"
2368
+ },
2369
+ {
2370
+ "effects": [
2371
+ [
2372
+ "set",
2373
+ "@entity.active",
2374
+ false
2375
+ ],
2376
+ [
2377
+ "render-ui",
2378
+ "main",
2379
+ null
2380
+ ]
2381
+ ],
2382
+ "event": "ROSTER_LOADED",
2383
+ "eventId": "evt_01M459WM5Z8JS6P7094FM192FF",
2384
+ "from": "idle",
2385
+ "guard": [
2386
+ "and",
2387
+ [
2388
+ "==",
2389
+ "@config.rosterSource",
2390
+ "event"
2391
+ ],
2392
+ [
2393
+ "not",
2394
+ [
2395
+ "==",
2396
+ "@payload.mode",
2397
+ "@config.matchMode"
2398
+ ]
2399
+ ]
1698
2400
  ],
1699
2401
  "to": "idle"
1700
2402
  },
@@ -1729,7 +2431,7 @@
1729
2431
  "tapped",
1730
2432
  [
1731
2433
  "array/find",
1732
- "@config.shapes",
2434
+ "@entity.shapes",
1733
2435
  [
1734
2436
  "fn",
1735
2437
  "s",
@@ -1758,7 +2460,7 @@
1758
2460
  "target",
1759
2461
  [
1760
2462
  "array/find",
1761
- "@config.shapes",
2463
+ "@entity.shapes",
1762
2464
  [
1763
2465
  "fn",
1764
2466
  "s",
@@ -1778,7 +2480,7 @@
1778
2480
  "circles",
1779
2481
  [
1780
2482
  "array/map",
1781
- "@config.shapes",
2483
+ "@entity.shapes",
1782
2484
  [
1783
2485
  "fn",
1784
2486
  "s",
@@ -1826,7 +2528,7 @@
1826
2528
  "labels",
1827
2529
  [
1828
2530
  "array/map",
1829
- "@config.shapes",
2531
+ "@entity.shapes",
1830
2532
  [
1831
2533
  "fn",
1832
2534
  "s",
@@ -2369,7 +3071,7 @@
2369
3071
  ],
2370
3072
  [
2371
3073
  "array/len",
2372
- "@config.prompts"
3074
+ "@entity.prompts"
2373
3075
  ]
2374
3076
  ],
2375
3077
  [
@@ -2379,7 +3081,7 @@
2379
3081
  "score": "@entity.score",
2380
3082
  "total": [
2381
3083
  "array/len",
2382
- "@config.prompts"
3084
+ "@entity.prompts"
2383
3085
  ]
2384
3086
  }
2385
3087
  ],
@@ -2403,7 +3105,7 @@
2403
3105
  "@nextIndex",
2404
3106
  [
2405
3107
  "array/len",
2406
- "@config.prompts"
3108
+ "@entity.prompts"
2407
3109
  ]
2408
3110
  ]
2409
3111
  ],
@@ -2411,7 +3113,7 @@
2411
3113
  "next",
2412
3114
  [
2413
3115
  "array/nth",
2414
- "@config.prompts",
3116
+ "@entity.prompts",
2415
3117
  [
2416
3118
  "math/min",
2417
3119
  "@nextIndex",
@@ -2419,7 +3121,7 @@
2419
3121
  "-",
2420
3122
  [
2421
3123
  "array/len",
2422
- "@config.prompts"
3124
+ "@entity.prompts"
2423
3125
  ],
2424
3126
  1.0
2425
3127
  ]
@@ -2430,7 +3132,7 @@
2430
3132
  "circles",
2431
3133
  [
2432
3134
  "array/map",
2433
- "@config.shapes",
3135
+ "@entity.shapes",
2434
3136
  [
2435
3137
  "fn",
2436
3138
  "s",
@@ -2478,7 +3180,7 @@
2478
3180
  "labels",
2479
3181
  [
2480
3182
  "array/map",
2481
- "@config.shapes",
3183
+ "@entity.shapes",
2482
3184
  [
2483
3185
  "fn",
2484
3186
  "s",
@@ -2902,7 +3604,7 @@
2902
3604
  "first",
2903
3605
  [
2904
3606
  "array/nth",
2905
- "@config.prompts",
3607
+ "@entity.prompts",
2906
3608
  0.0
2907
3609
  ]
2908
3610
  ],
@@ -2910,7 +3612,7 @@
2910
3612
  "circles",
2911
3613
  [
2912
3614
  "array/map",
2913
- "@config.shapes",
3615
+ "@entity.shapes",
2914
3616
  [
2915
3617
  "fn",
2916
3618
  "s",
@@ -2958,7 +3660,7 @@
2958
3660
  "labels",
2959
3661
  [
2960
3662
  "array/map",
2961
- "@config.shapes",
3663
+ "@entity.shapes",
2962
3664
  [
2963
3665
  "fn",
2964
3666
  "s",