@trilogy-data/trilogy-studio-components 0.1.25 → 0.1.27

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 (200) hide show
  1. package/dist/AssetAutoImporter-OHphsfW9.js +403 -0
  2. package/dist/ChatCreatorModal-CuXha6Dg.js +218 -0
  3. package/dist/ChatModelSelect-Cz7axWjP.js +40 -0
  4. package/dist/{CodeBlock-PT4no49I.js → CodeBlock-BBsaC6hX.js} +4 -4
  5. package/dist/{CommunityModels-D7zWnHgG.js → CommunityModels-CIQQhO-y.js} +106 -75
  6. package/dist/{ConnectionErrorPopup-FSs7U-Yl.js → ConnectionErrorPopup-7vpqgF0s.js} +1 -1
  7. package/dist/{ConnectionView-COnTTuA4.js → ConnectionView-7Jj_Ggdi.js} +49 -49
  8. package/dist/{CreateEditorFromDatasourcePopup-snOh1d5h.js → CreateEditorFromDatasourcePopup-CrVHUWFl.js} +4 -4
  9. package/dist/{Dashboard-D1ZCTw5r.js → Dashboard-DxSi9W6Q.js} +276 -280
  10. package/dist/{DashboardImportSelector-CNxibXlS.js → DashboardImportSelector-kuDRDYi8.js} +2 -2
  11. package/dist/{DashboardMobile-D_m0xv17.js → DashboardMobile-CZEgTb0R.js} +39 -39
  12. package/dist/{DrilldownPane-CBs5ZojS.js → DrilldownPane-BheRHJMs.js} +5 -7
  13. package/dist/{Editor-DhsP18KE.js → Editor-D6tdutTm.js} +106 -104
  14. package/dist/{ErrorMessage-XMn_08gJ.js → ErrorMessage-D5JeF3Iz.js} +4 -4
  15. package/dist/{GlobalChatPanel-DFx9A4yP.js → GlobalChatPanel-BXZh0sdD.js} +169 -134
  16. package/dist/{IDE-BRMLxTfP.js → IDE-T8PmyAQ_.js} +200 -203
  17. package/dist/{JobsView-C9PYS6pZ.js → JobsView-Ca97MiSd.js} +12 -13
  18. package/dist/{LLMChat-Cqg6pTgC.js → LLMChat-Cch33Yd_.js} +3 -3
  19. package/dist/{LLMView-VkJpP-49.js → LLMView-BDb6wD74.js} +26 -26
  20. package/dist/{LoadingView-s1uznGwG.js → LoadingView-B-xFwd2N.js} +2 -2
  21. package/dist/{MarkdownRenderer-BNDuEyG-.js → MarkdownRenderer-BWvdx0k3.js} +531 -430
  22. package/dist/MobileIDE-DpdEQEqc.js +783 -0
  23. package/dist/{ModelCard-D8tKkK9-.js → ModelCard-DkAMP4X9.js} +19 -20
  24. package/dist/{ModelView-rAurf9n8.js → ModelView-DomyhN8g.js} +7 -7
  25. package/dist/PageLoading-BAvKGo9h.js +5937 -0
  26. package/dist/{ResultComponent-_-1qZCfv.js → ResultComponent-zoOSoRLe.js} +8 -8
  27. package/dist/{Results-CQGpFmPQ.js → Results-dq-SlJbU.js} +17 -19
  28. package/dist/{StatusIcon-BylPx2EO.js → StatusIcon-AbxNvJ6p.js} +2 -2
  29. package/dist/{StoreTokenModal-zCSYhfrw.js → StoreTokenModal-CM8WXdu1.js} +2 -2
  30. package/dist/{SymbolsPane-BpmL___H.js → SymbolsPane-DfaxeaPS.js} +6 -3
  31. package/dist/{TrilogyEmbedProvider-WA_dlv9e.js → TrilogyEmbedProvider-D3h0gYnX.js} +9 -9
  32. package/dist/{TutorialPage-CZGBRJdq.js → TutorialPage-BtEJG7cT.js} +27 -28
  33. package/dist/{VegaLiteChart-CmkOw6yD.js → VegaLiteChart-BVyAab-o.js} +12191 -10975
  34. package/dist/{WelcomePage-CLKvAvk-.js → WelcomePage-BoqzYBLr.js} +5 -5
  35. package/dist/{embedTheme-Bub46ILG.js → _plugin-vue_export-helper-f9Rw-Il4.js} +14 -6
  36. package/dist/assets/{css.worker-9aDGcEUy.js → css.worker-niORQtzO.js} +14 -14
  37. package/dist/assets/{html.worker-D2LKDpnG.js → html.worker-CO5LvJpF.js} +17 -17
  38. package/dist/assets/json.worker-BezHzWUV.js +58 -0
  39. package/dist/assets/{ts.worker-Bz0-EaKK.js → ts.worker-CYhxGg0r.js} +107 -107
  40. package/dist/{results-DTgAKr5j.js → base-DuKnVD-A.js} +216 -45
  41. package/dist/components/AssetAutoImporter.vue.d.ts.map +1 -1
  42. package/dist/components/FeedbackBanner.vue.d.ts +4 -0
  43. package/dist/components/FeedbackBanner.vue.d.ts.map +1 -0
  44. package/dist/components/TipsCTA.vue.d.ts +1 -1
  45. package/dist/components/VegaLiteChart.vue.d.ts.map +1 -1
  46. package/dist/components/chartHelpers.d.ts +9 -1
  47. package/dist/components/chartHelpers.d.ts.map +1 -1
  48. package/dist/components/chartRenderManager.d.ts +4 -1
  49. package/dist/components/chartRenderManager.d.ts.map +1 -1
  50. package/dist/components/community/AddStoreModal.vue.d.ts +1 -1
  51. package/dist/components/community/AddStoreModal.vue.d.ts.map +1 -1
  52. package/dist/components/community/CommunityModelCard.vue.d.ts.map +1 -1
  53. package/dist/components/dashboard/DashboardCreatorIcon.vue.d.ts +54 -0
  54. package/dist/components/dashboard/DashboardCreatorIcon.vue.d.ts.map +1 -0
  55. package/dist/components/dashboard/DashboardProvenance.vue.d.ts +30 -0
  56. package/dist/components/dashboard/DashboardProvenance.vue.d.ts.map +1 -0
  57. package/dist/components/dashboard/ReportLayout.vue.d.ts +19 -0
  58. package/dist/components/dashboard/ReportLayout.vue.d.ts.map +1 -0
  59. package/dist/components/editor/Editor.vue.d.ts +3 -3
  60. package/dist/components/editor/Editor.vue.d.ts.map +1 -1
  61. package/dist/components/editor/EditorCreatorIcon.vue.d.ts +62 -0
  62. package/dist/components/editor/EditorCreatorIcon.vue.d.ts.map +1 -0
  63. package/dist/components/editor/ValidationComponent.vue.d.ts +50 -0
  64. package/dist/components/editor/ValidationComponent.vue.d.ts.map +1 -0
  65. package/dist/components/jobs/JobsAddStoreModal.vue.d.ts.map +1 -1
  66. package/dist/components/llm/ChatCreatorModal.vue.d.ts +17 -1
  67. package/dist/components/llm/ChatCreatorModal.vue.d.ts.map +1 -1
  68. package/dist/components/llm/ChatModelSelect.vue.d.ts +13 -0
  69. package/dist/components/llm/ChatModelSelect.vue.d.ts.map +1 -0
  70. package/dist/components/llm/GlobalChatPanel.vue.d.ts.map +1 -1
  71. package/dist/components/model/ModelCard.vue.d.ts +3 -3
  72. package/dist/components/sidebar/CommunityModelList.vue.d.ts +33 -50
  73. package/dist/components/sidebar/CommunityModelList.vue.d.ts.map +1 -1
  74. package/dist/components/sidebar/CommunityModelListItem.vue.d.ts.map +1 -1
  75. package/dist/components/sidebar/EditorList.vue.d.ts +32 -49
  76. package/dist/components/sidebar/EditorList.vue.d.ts.map +1 -1
  77. package/dist/components/sidebar/LLMConnectionList.vue.d.ts.map +1 -1
  78. package/dist/components/sidebar/Sidebar.vue.d.ts +65 -99
  79. package/dist/components/sidebar/Sidebar.vue.d.ts.map +1 -1
  80. package/dist/components/tutorial/TutorialPrompt.vue.d.ts +3 -3
  81. package/dist/components/tutorial/TutorialPrompt.vue.d.ts.map +1 -1
  82. package/dist/{remoteWorker-Dkv3TJ0j.js → connections-CWH3zwH2.js} +4544 -4126
  83. package/dist/connections.js +3 -4
  84. package/dist/{cssMode-D4Rzr1Cu.js → cssMode-zpO2ap2B.js} +5 -6
  85. package/dist/dashboard.js +54 -57
  86. package/dist/dashboards/layerSpec.d.ts +38 -4
  87. package/dist/dashboards/layerSpec.d.ts.map +1 -1
  88. package/dist/dashboards/lineAreaSpec.d.ts +8 -80
  89. package/dist/dashboards/lineAreaSpec.d.ts.map +1 -1
  90. package/dist/dashboards/mapSpec.d.ts +1 -0
  91. package/dist/dashboards/mapSpec.d.ts.map +1 -1
  92. package/dist/dashboards/spec.d.ts.map +1 -1
  93. package/dist/data/tutorial/documentation.d.ts.map +1 -1
  94. package/dist/data/tutorial/startupScripts.d.ts +3 -0
  95. package/dist/data/tutorial/startupScripts.d.ts.map +1 -0
  96. package/dist/{dist-CXoL8kXK.js → dist-1z5KURzS.js} +55 -50
  97. package/dist/{dist-DKkuvbPb.js → dist-Bv3D2p5A.js} +20 -18
  98. package/dist/{editor.main-Cl8i7rHY.js → editor.main-BQh6DxDB.js} +33 -33
  99. package/dist/{editorRefinementRuntime-C_YmXRy4.js → editorStore-CAlMJftt.js} +2084 -946
  100. package/dist/embed.js +2 -2
  101. package/dist/entry.dashboard.d.ts +1 -0
  102. package/dist/entry.dashboard.d.ts.map +1 -1
  103. package/dist/{freemarker2-fW5NBILf.js → freemarker2-DQBqlEXc.js} +1 -1
  104. package/dist/{globalChatRuntime-oMLiPLNC.js → globalChatRuntime-CyS7vH51.js} +18 -18
  105. package/dist/{handlebars-dG4w8UUY.js → handlebars-tgYxaM70.js} +1 -1
  106. package/dist/{helpers-DcWCa6bX.js → helpers-BbVlA3Pf.js} +39 -39
  107. package/dist/{html-1Dq70BdU.js → html-jJahD3Mi.js} +1 -1
  108. package/dist/{htmlMode--IQmLBeh.js → htmlMode-BA1-8l2e.js} +5 -6
  109. package/dist/{javascript-CTzBM4sF.js → javascript-Cypfo7va.js} +1 -1
  110. package/dist/{jsonMode-DzeJjIEH.js → jsonMode-xJye8PWS.js} +25 -25
  111. package/dist/{liquid-DlHThiki.js → liquid-BGDrv5da.js} +1 -1
  112. package/dist/llm/data/constants.d.ts +1 -1
  113. package/dist/llm/data/constants.d.ts.map +1 -1
  114. package/dist/llm/data/trilogySyntax.generated.d.ts +7 -1
  115. package/dist/llm/data/trilogySyntax.generated.d.ts.map +1 -1
  116. package/dist/llm/docsIndex.d.ts.map +1 -1
  117. package/dist/llm/openai.d.ts +2 -1
  118. package/dist/llm/openai.d.ts.map +1 -1
  119. package/dist/llm-ClU-2rgk.js +18493 -0
  120. package/dist/llm.js +2 -3
  121. package/dist/{localStorage-CSuYS7QE.js → localStorage-CGQ1iJXt.js} +39 -42
  122. package/dist/{lspLanguageFeatures-Cdfs3EKq.js → lspLanguageFeatures-V3e_p9oN.js} +32 -32
  123. package/dist/{mdx-fn3g4PH5.js → mdx-BUR1aImW.js} +1 -1
  124. package/dist/models/helpers.d.ts.map +1 -1
  125. package/dist/monaco.js +3 -3
  126. package/dist/{python-CCVj0pFt.js → python-YLkl0pc6.js} +1 -1
  127. package/dist/{razor-Cj3flYnk.js → razor-BP8TRMDY.js} +1 -1
  128. package/dist/{reconcile-Bk7M797_.js → reconcile-DXIvGwBk.js} +1 -1
  129. package/dist/{remoteStoreSync-CLvZJrTK.js → remoteStoreSync-CuQBWpWf.js} +3 -3
  130. package/dist/remotes/displayHelpers.d.ts.map +1 -1
  131. package/dist/remotes/genericStoreMetadata.d.ts +1 -0
  132. package/dist/remotes/genericStoreMetadata.d.ts.map +1 -1
  133. package/dist/remotes/models.d.ts +37 -5
  134. package/dist/remotes/models.d.ts.map +1 -1
  135. package/dist/remotes/staticStorePresets.d.ts +22 -0
  136. package/dist/remotes/staticStorePresets.d.ts.map +1 -0
  137. package/dist/remotes/storeService.d.ts +25 -4
  138. package/dist/remotes/storeService.d.ts.map +1 -1
  139. package/dist/{rolldown-runtime-Dqa2HsxW.js → rolldown-runtime-B0aSnxlc.js} +2 -2
  140. package/dist/static/test_import.vue.d.ts +4 -0
  141. package/dist/static/test_import.vue.d.ts.map +1 -0
  142. package/dist/stores/communityApiStore.d.ts +32 -60
  143. package/dist/stores/communityApiStore.d.ts.map +1 -1
  144. package/dist/stores/connectionStore.d.ts.map +1 -1
  145. package/dist/stores/resolver.d.ts +5 -0
  146. package/dist/stores/resolver.d.ts.map +1 -1
  147. package/dist/stores/urlStore.d.ts +1 -0
  148. package/dist/stores/urlStore.d.ts.map +1 -1
  149. package/dist/stores-LlyiwSbK.js +2604 -0
  150. package/dist/stores.js +4 -7
  151. package/dist/trilogy-studio-components.css +1 -1
  152. package/dist/{tsMode-GI4xMYAl.js → tsMode-BH9HS_sH.js} +64 -66
  153. package/dist/{typescript-CPibXi3J.js → typescript-BM-ynfk9.js} +1 -1
  154. package/dist/{useChatWithTools-GV1ufcqw.js → useChatWithTools-m3Jn_SV-.js} +11 -11
  155. package/dist/{useDashboard-OoBKkkuQ.js → useDashboard-BOAuvVEw.js} +1013 -1021
  156. package/dist/{tabulator_esm-CxLvGDp8.js → useGlobalChatPanel-DuP1q7_f.js} +1729 -711
  157. package/dist/{useResizableDialog-B0ePSts4.js → useResizableDialog-Cs90WJdF.js} +2 -2
  158. package/dist/views/MobileIDE.vue.d.ts.map +1 -1
  159. package/dist/views/ModelView.vue.d.ts +6 -6
  160. package/dist/views/ModelView.vue.d.ts.map +1 -1
  161. package/dist/views/TutorialPage.vue.d.ts +41 -58
  162. package/dist/views/TutorialPage.vue.d.ts.map +1 -1
  163. package/dist/views.js +193 -195
  164. package/dist/{editor.api2-ClD5pp8H.js → workers-B9Eybl-M.js} +16252 -15926
  165. package/dist/{xml-BNyphceI.js → xml-M5WFPSpA.js} +1 -1
  166. package/dist/{yaml-DE5Vz0PH.js → yaml-CEeFwjz9.js} +1 -1
  167. package/package.json +29 -20
  168. package/dist/AssetAutoImporter-DfMd_DSk.js +0 -403
  169. package/dist/ChatCreatorModal-BTqY06B6.js +0 -177
  170. package/dist/DashboardCreatorInline-LWvf--2x.js +0 -129
  171. package/dist/DataTable-DoRDynP1.js +0 -365
  172. package/dist/EditorCreatorInline-D6_y1H_h.js +0 -125
  173. package/dist/LoadingButton-OH3frQuO.js +0 -138
  174. package/dist/MobileIDE-CHGJoh05.js +0 -781
  175. package/dist/ModalDialog-D1EOG4rl.js +0 -42
  176. package/dist/ModelCreator-DrxLxeyH.js +0 -253
  177. package/dist/PageLoading-I6mr-7NB.js +0 -2666
  178. package/dist/Tooltip-Dihir4zs.js +0 -103
  179. package/dist/_plugin-vue_export-helper-B3ysoDQm.js +0 -8
  180. package/dist/assets/json.worker-CJ5MmO5Q.js +0 -58
  181. package/dist/base-C8IuZWqY.js +0 -164
  182. package/dist/connectionHistoryStorage-DKJHiKJY.js +0 -111
  183. package/dist/connectionHistoryStore-DQeBvStZ.js +0 -61
  184. package/dist/connections-CJSb1TZl.js +0 -229
  185. package/dist/constants-DgFEYN2b.js +0 -7
  186. package/dist/dashboardStore-CNkWQ4r7.js +0 -641
  187. package/dist/demoSetup-DiW3ROFQ.js +0 -2941
  188. package/dist/editorRefinementToolExecutor-mX8ClQ63.js +0 -4498
  189. package/dist/editorStore-Ch7k-gse.js +0 -972
  190. package/dist/formatting-BbJ5ICgh.js +0 -6
  191. package/dist/llm-_807I79k.js +0 -11965
  192. package/dist/llmStore-CSzM1IZd.js +0 -153
  193. package/dist/monaco.contribution-ikesdolO.js +0 -128
  194. package/dist/stores-C1wUWiFm.js +0 -1708
  195. package/dist/trilogy-BroD2Qmp.js +0 -4
  196. package/dist/urlStore-Dgmwx1YI.js +0 -54
  197. package/dist/useGlobalChatPanel-CIeUyZba.js +0 -85
  198. package/dist/useIsMobile-CNpUQAvk.js +0 -8
  199. package/dist/usePrismHighlight-DVyDiDAL.js +0 -183
  200. package/dist/workers-Br7ThUKL.js +0 -47
package/dist/embed.js CHANGED
@@ -1,4 +1,4 @@
1
- import "./embedTheme-Bub46ILG.js";
1
+ import "./_plugin-vue_export-helper-f9Rw-Il4.js";
2
2
  import { a as e, i as t, n, o as r, r as i, s as a, t as o } from "./config-DwTONafa.js";
3
- import { t as s } from "./TrilogyEmbedProvider-WA_dlv9e.js";
3
+ import { t as s } from "./TrilogyEmbedProvider-D3h0gYnX.js";
4
4
  export { o as TRILOGY_EMBED_CONFIG_KEY, s as TrilogyEmbedProvider, n as normalizeEmbedTheme, i as provideTrilogyEmbedConfig, t as resolveThemeMode, e as resolveThemeVariables, r as useResolvedThemeMode, a as useTrilogyEmbedConfig };
@@ -9,6 +9,7 @@ export { default as DashboardDataSelector } from './components/dashboard/Dashboa
9
9
  export { default as DataTable } from './components/DataTable.vue';
10
10
  export { default as MarkdownRenderer } from './components/MarkdownRenderer.vue';
11
11
  export { default as VegaLiteChart } from './components/VegaLiteChart.vue';
12
+ export { configureCartoBasemapKey } from './dashboards/mapSpec';
12
13
  export { useTrilogyCore } from './composables/useTrilogyCore';
13
14
  export { useTrilogyChat } from './composables/useTrilogyChat';
14
15
  export { useCrossFilterEligibility } from './composables/useCrossFilterEligibility';
@@ -1 +1 @@
1
- {"version":3,"file":"entry.dashboard.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,qBAAqB,EAAE,MAAM,gCAAgC,CAAA;AACjF,YAAY,EACV,gCAAgC,EAChC,UAAU,EACV,WAAW,EACX,WAAW,EACX,gBAAgB,EAChB,mBAAmB,EACnB,2BAA2B,EAC3B,yBAAyB,GAC1B,MAAM,gCAAgC,CAAA;AAEvC,OAAO,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAA;AACvD,YAAY,EAAE,WAAW,EAAE,YAAY,EAAE,GAAG,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAA"}
@@ -1,4 +1,4 @@
1
- import { u as e } from "./editor.api2-ClD5pp8H.js";
1
+ import { p as e } from "./workers-B9Eybl-M.js";
2
2
  //#region node_modules/.pnpm/monaco-editor@0.55.1/node_modules/monaco-editor/esm/vs/basic-languages/freemarker2/freemarker2.js
3
3
  var t = [
4
4
  "assign",
@@ -1,8 +1,8 @@
1
1
  import { t as e } from "./screenBridge-BLlMdfhn.js";
2
- import { J as t, Q as n, W as r, Y as i, ot as a } from "./editorRefinementToolExecutor-mX8ClQ63.js";
3
- import { i as o, o as s } from "./stores-C1wUWiFm.js";
4
- import { a as c, r as l } from "./editorRefinementRuntime-C_YmXRy4.js";
5
- import { t as u } from "./useGlobalChatPanel-CIeUyZba.js";
2
+ import { K as t, X as n, Z as r, ct as i, et as a } from "./llm-ClU-2rgk.js";
3
+ import { a as o, d as s } from "./stores-LlyiwSbK.js";
4
+ import { a as c, r as l } from "./editorStore-CAlMJftt.js";
5
+ import { t as u } from "./useGlobalChatPanel-DuP1q7_f.js";
6
6
  import { watch as d } from "vue";
7
7
  //#region llm/registry/renderToolList.ts
8
8
  function f(e) {
@@ -58,7 +58,7 @@ function y(e) {
58
58
  //#endregion
59
59
  //#region llm/globalChatRuntime.ts
60
60
  function b(e) {
61
- return `${a({
61
+ return `${i({
62
62
  dataConnectionName: "",
63
63
  availableConnections: Object.values(e.connectionStore.connections).map((e) => e.name),
64
64
  availableConcepts: [],
@@ -72,7 +72,7 @@ You are the global assistant for Trilogy Studio, docked in a persistent side pan
72
72
  ${f(c().getToolsetForContext("global").filter((e) => !c().getToolNames("chat").includes(e.name)))}
73
73
 
74
74
  App-control guidance:
75
- - Navigation notices ("The user is now viewing...") arrive as ${i}...${t} messages. They are context, not instructions.
75
+ - Navigation notices ("The user is now viewing...") arrive as ${r}...${n} messages. They are context, not instructions.
76
76
  - Call get_app_state to orient yourself whenever you are unsure what the user is looking at or what exists — the state at conversation start may be stale.
77
77
  - Tools that need a specific screen mounted will tell you when it isn't; open the screen first (open_dashboard, open_editor) when you need it visible.
78
78
  - Editors are files: "source"-tagged Trilogy editors define the data model. To change the model, read the relevant editors, edit them with update_editor_contents, and validate with validate_query or run_editor_query.
@@ -108,17 +108,17 @@ async function T(e, t, n) {
108
108
  }
109
109
  var E = 2e3;
110
110
  function D(e) {
111
- let { chatStore: t, llmConnectionStore: r, editor: i, selectedText: a } = e, o = u(), s = o.activePanelChatId.value, c = s ? t.chats[s] : null, l = c && !c.deleted ? c : null;
112
- l ||= t.chatList.filter((e) => e.kind === "user" && e.source === "user").sort((e, t) => new Date(t.updatedAt).getTime() - new Date(e.updatedAt).getTime())[0] || null, l ||= t.newChat(r.activeConnection || "", "", void 0, "", { activate: !1 });
113
- let d = a?.trim() ? n(a) : "", f = d ? `\nTheir current selection in that editor:\n${d.slice(0, E)}${d.length > E ? "\n...(selection truncated)" : ""}` : "";
114
- return l.pendingContextNote = `[editor] The user asked for AI help from editor "${n(i.name)}" (id ${i.id}). Read it with read_editor before proposing or making changes; apply edits with update_editor_contents.${f}`, g(l.id), o.openPanel(l.id), l.id;
111
+ let { chatStore: t, llmConnectionStore: n, editor: r, selectedText: i } = e, o = u(), s = o.activePanelChatId.value, c = s ? t.chats[s] : null, l = c && !c.deleted ? c : null;
112
+ l ||= t.chatList.filter((e) => e.kind === "user" && e.source === "user").sort((e, t) => new Date(t.updatedAt).getTime() - new Date(e.updatedAt).getTime())[0] || null, l ||= t.newChat(n.activeConnection || "", "", void 0, "", { activate: !1 });
113
+ let d = i?.trim() ? a(i) : "", f = d ? `\nTheir current selection in that editor:\n${d.slice(0, E)}${d.length > E ? "\n...(selection truncated)" : ""}` : "";
114
+ return l.pendingContextNote = `[editor] The user asked for AI help from editor "${a(r.name)}" (id ${r.id}). Read it with read_editor before proposing or making changes; apply edits with update_editor_contents.${f}`, g(l.id), o.openPanel(l.id), l.id;
115
115
  }
116
- async function O(a) {
117
- let { chatId: l, message: u, chatStore: d, deps: f } = a, p = d.chats[l];
116
+ async function O(i) {
117
+ let { chatId: l, message: u, chatStore: d, deps: f } = i, p = d.chats[l];
118
118
  if (!p) return;
119
119
  (p.llmConnectionName || f.llmConnectionStore.activeConnection) && p.pendingContextNote && (d.addMessageToChat(l, {
120
120
  role: "user",
121
- content: `${i}${n(p.pendingContextNote)}${t}`,
121
+ content: `${r}${a(p.pendingContextNote)}${n}`,
122
122
  hidden: !0
123
123
  }), p.pendingContextNote = null);
124
124
  let m = c(), h = {
@@ -138,16 +138,16 @@ async function O(a) {
138
138
  chatId: l,
139
139
  cache: /* @__PURE__ */ new Map(),
140
140
  requestCompaction: async (e) => {
141
- let t = f.llmConnectionStore.connections[p.llmConnectionName || f.llmConnectionStore.activeConnection];
142
- if (!t) return {
141
+ let n = f.llmConnectionStore.connections[p.llmConnectionName || f.llmConnectionStore.activeConnection];
142
+ if (!n) return {
143
143
  success: !1,
144
144
  error: "No LLM provider available for compaction."
145
145
  };
146
146
  try {
147
- let n = await r(t, p, { focus: e });
148
- return n ? {
147
+ let r = await t(n, p, { focus: e });
148
+ return r ? {
149
149
  success: !0,
150
- message: `Compacted ${n.archivedCount} earlier messages into a summary. The reduced history applies from the next turn.`
150
+ message: `Compacted ${r.archivedCount} earlier messages into a summary. The reduced history applies from the next turn.`
151
151
  } : {
152
152
  success: !0,
153
153
  message: "The conversation is still small — nothing worth compacting yet."
@@ -1,4 +1,4 @@
1
- import { u as e } from "./editor.api2-ClD5pp8H.js";
1
+ import { p as e } from "./workers-B9Eybl-M.js";
2
2
  //#region node_modules/.pnpm/monaco-editor@0.55.1/node_modules/monaco-editor/esm/vs/basic-languages/handlebars/handlebars.js
3
3
  var t = [
4
4
  "area",
@@ -1,11 +1,10 @@
1
- import { Dt as e, sn as t } from "./editorRefinementToolExecutor-mX8ClQ63.js";
2
- import { D as n, S as r } from "./editorRefinementRuntime-C_YmXRy4.js";
3
- import { s as i } from "./base-C8IuZWqY.js";
4
- import { u as a } from "./editorStore-Ch7k-gse.js";
5
- import "./dashboardStore-CNkWQ4r7.js";
6
- import { n as o } from "./reconcile-Bk7M797_.js";
1
+ import { s as e } from "./base-DuKnVD-A.js";
2
+ import { It as t, gn as n } from "./llm-ClU-2rgk.js";
3
+ import "./stores-LlyiwSbK.js";
4
+ import { M as r, Y as i, at as a, tt as o } from "./editorStore-CAlMJftt.js";
5
+ import { n as s } from "./reconcile-DXIvGwBk.js";
7
6
  //#region models/helpers.ts
8
- var s = class {
7
+ var c = class {
9
8
  editorStore;
10
9
  modelStore;
11
10
  dashboardStore;
@@ -18,17 +17,18 @@ var s = class {
18
17
  async fetchModelImportBase(e, t) {
19
18
  let n = await fetch(e, this.buildRequestInit(t));
20
19
  if (!n.ok) throw Error(`Failed to fetch model import from ${e}: ${n.statusText}`);
21
- let r = await n.text();
20
+ let r = await n.text(), a;
22
21
  try {
23
- return JSON.parse(r);
22
+ a = JSON.parse(r);
24
23
  } catch (t) {
25
24
  throw Error(`Invalid JSON in model import from ${e}: ${t}`);
26
25
  }
26
+ return i(a, e);
27
27
  }
28
28
  purposeToTag(e) {
29
29
  switch (e) {
30
- case "source": return r.SOURCE;
31
- case "setup": return r.STARTUP_SCRIPT;
30
+ case "source": return o.SOURCE;
31
+ case "setup": return o.STARTUP_SCRIPT;
32
32
  default: return null;
33
33
  }
34
34
  }
@@ -68,32 +68,32 @@ var s = class {
68
68
  }
69
69
  getRemoteEditorPath(e) {
70
70
  let t = this.getComponentEditorType(e);
71
- if (e.name?.trim()) return n(e.name, t);
71
+ if (e.name?.trim()) return a(e.name, t);
72
72
  if (e.url?.trim()) try {
73
- let r = new URL(e.url);
74
- return n(decodeURIComponent(r.pathname.split("/").filter(Boolean).pop() || ""), t);
73
+ let n = new URL(e.url), r = decodeURIComponent(n.pathname.split("/").filter(Boolean).pop() || "");
74
+ return a(r, t);
75
75
  } catch {
76
- return n(e.url, t);
76
+ return a(e.url, t);
77
77
  }
78
- return n("untitled", t);
78
+ return a("untitled", t);
79
79
  }
80
80
  resolveRemotePath(e, t) {
81
81
  if (e.name?.trim()) return this.getRemoteEditorPath(e);
82
82
  if (!t) return null;
83
83
  try {
84
- let n = `${a(t)}/`, r = new URL(n), i = new URL(e.url, r);
85
- if (i.origin !== r.origin || !i.pathname.startsWith(r.pathname)) return null;
86
- let o = i.pathname.slice(r.pathname.length);
84
+ let n = `${r(t)}/`, i = new URL(n), a = new URL(e.url, i);
85
+ if (a.origin !== i.origin || !a.pathname.startsWith(i.pathname)) return null;
86
+ let o = a.pathname.slice(i.pathname.length);
87
87
  return decodeURIComponent(o);
88
88
  } catch {
89
89
  return null;
90
90
  }
91
91
  }
92
92
  createOrUpdateEditor(e, t, n = {}) {
93
- let r = n.remote ? this.resolveRemotePath(e, n.remoteBaseUrl) : null, i = n.remote && r || e.name, a = this.getComponentEditorType(e), s;
93
+ let r = n.remote ? this.resolveRemotePath(e, n.remoteBaseUrl) : null, i = n.remote && r || e.name, a = this.getComponentEditorType(e), o;
94
94
  if (n.remote && n.remoteStoreId) {
95
95
  let c = r || i;
96
- s = o(this.editorStore, {
96
+ o = s(this.editorStore, {
97
97
  id: `remote:${n.remoteStoreId}:${encodeURIComponent(c)}`,
98
98
  name: i,
99
99
  type: a,
@@ -105,42 +105,42 @@ var s = class {
105
105
  });
106
106
  } else {
107
107
  let n = Object.values(this.editorStore.editors).find((e) => e.name === i && e.connection === t && e.storage !== "remote");
108
- n ? (s = n, this.editorStore.setEditorContents(n.id, e.content)) : s = this.editorStore.newEditor(i, a, t, e.content);
108
+ n ? (o = n, this.editorStore.setEditorContents(n.id, e.content)) : o = this.editorStore.newEditor(i, a, t, e.content);
109
109
  }
110
- return e.purpose && !s.tags.includes(e.purpose) && this.editorStore.editors[s.id].tags.push(e.purpose), s;
110
+ return e.purpose && !o.tags.includes(e.purpose) && this.editorStore.editors[o.id].tags.push(e.purpose), o;
111
111
  }
112
- createOrUpdateDashboard(t, n, r, a = {}) {
113
- if (!t.content) {
114
- console.warn(`Dashboard ${t.name} has no content, skipping`);
112
+ createOrUpdateDashboard(n, r, i, a = {}) {
113
+ if (!n.content) {
114
+ console.warn(`Dashboard ${n.name} has no content, skipping`);
115
115
  return;
116
116
  }
117
117
  try {
118
- let o = e.fromSerialized(JSON.parse(t.content));
119
- o.storage = "local", o.connection = n, o.connectionId = i({
120
- name: n,
118
+ let o = t.fromSerialized(JSON.parse(n.content));
119
+ o.storage = "local", o.connection = r, o.connectionId = e({
120
+ name: r,
121
121
  storage: a.remote ? "remote" : "local",
122
122
  remoteStoreId: a.remoteStoreId
123
123
  }), o.state = "published";
124
124
  let s = !!a.remote;
125
125
  o.imports = o.imports.map((e) => ({
126
126
  ...e,
127
- id: this.editorStore.editorList.find((t) => t.name === e.name && t.connection === n && t.storage === "remote" === s)?.id || ""
127
+ id: this.editorStore.editorList.find((t) => t.name === e.name && t.connection === r && t.storage === "remote" === s)?.id || ""
128
128
  }));
129
- let c = Object.values(this.dashboardStore.dashboards).find((e) => e.name === o.name && e.connection === n && e.storage !== "remote");
130
- c ? (o.id = c.id, this.dashboardStore.dashboards[c.id] = o) : (o.id = Math.random().toString(36).substring(2, 15), this.dashboardStore.addDashboard(o)), r.set(t.name, o.id);
129
+ let c = Object.values(this.dashboardStore.dashboards).find((e) => e.name === o.name && e.connection === r && e.storage !== "remote");
130
+ c ? (o.id = c.id, this.dashboardStore.dashboards[c.id] = o) : (o.id = Math.random().toString(36).substring(2, 15), this.dashboardStore.addDashboard(o)), i.set(n.name, o.id);
131
131
  } catch (e) {
132
- console.error(`Error importing dashboard ${t.name}:`, e);
132
+ console.error(`Error importing dashboard ${n.name}:`, e);
133
133
  }
134
134
  }
135
- async importModel(e, n, r, i = {}) {
136
- if (!n) return null;
135
+ async importModel(e, t, r, i = {}) {
136
+ if (!t) return null;
137
137
  let a = /* @__PURE__ */ new Map(), o = /* @__PURE__ */ new Map(), s = /* @__PURE__ */ new Map(), c = /* @__PURE__ */ new Map();
138
138
  try {
139
- let l = await this.fetchModelImportBase(n, i.token), u = await this.fetchModelImports(l, i.token), d = u.filter((e) => e.type === "sql" || e.type === "trilogy" || e.type === "python"), f = u.filter((e) => e.type === "dashboard"), p = [];
139
+ let l = await this.fetchModelImportBase(t, i.token), u = await this.fetchModelImports(l, i.token), d = u.filter((e) => e.type === "sql" || e.type === "trilogy" || e.type === "python"), f = u.filter((e) => e.type === "dashboard"), p = [];
140
140
  for (let e of d) {
141
141
  console.log(`Processing editor: ${e.name}`);
142
- let n = this.createOrUpdateEditor(e, r, i);
143
- e.type === "sql" ? o.set(e.name, n.id) : e.type === "trilogy" ? (s.set(e.name, n.id), p.push(new t(n.id, e.alias || e.name, [], []))) : e.type === "python" && c.set(e.name, n.id);
142
+ let t = this.createOrUpdateEditor(e, r, i);
143
+ e.type === "sql" ? o.set(e.name, t.id) : e.type === "trilogy" ? (s.set(e.name, t.id), p.push(new n(t.id, e.alias || e.name, [], []))) : e.type === "python" && c.set(e.name, t.id);
144
144
  }
145
145
  for (let e of f) console.log(`Processing dashboard: ${e.name}`), this.createOrUpdateDashboard(e, r, a, i);
146
146
  return this.modelStore.models[e].sources = p, this.modelStore.models[e].storage = i.remote ? "remote" : "local", this.modelStore.models[e].changed = !0, {
@@ -155,4 +155,4 @@ var s = class {
155
155
  }
156
156
  };
157
157
  //#endregion
158
- export { s as t };
158
+ export { c as t };
@@ -1,4 +1,4 @@
1
- import { u as e } from "./editor.api2-ClD5pp8H.js";
1
+ import { p as e } from "./workers-B9Eybl-M.js";
2
2
  //#region node_modules/.pnpm/monaco-editor@0.55.1/node_modules/monaco-editor/esm/vs/basic-languages/html/html.js
3
3
  var t = [
4
4
  "area",
@@ -1,10 +1,9 @@
1
- import { u as e } from "./editor.api2-ClD5pp8H.js";
2
- import { t } from "./workers-Br7ThUKL.js";
3
- import { _ as n, a as r, c as i, d as a, f as o, g as s, h as c, i as l, l as u, m as d, n as f, o as p, p as m, r as h, s as g, t as _, u as v, v as y } from "./lspLanguageFeatures-Cdfs3EKq.js";
1
+ import { p as e, t } from "./workers-B9Eybl-M.js";
2
+ import { _ as n, a as r, c as i, d as a, f as o, g as s, h as c, i as l, l as u, m as d, n as f, o as p, p as m, r as h, s as g, t as _, u as v, v as y } from "./lspLanguageFeatures-V3e_p9oN.js";
4
3
  //#region node_modules/.pnpm/monaco-editor@0.55.1/node_modules/monaco-editor/esm/vs/language/html/workerManager.js
5
- var b = 120 * 1e3, x = class {
4
+ var b = 12e4, x = class {
6
5
  constructor(e) {
7
- this._defaults = e, this._worker = null, this._client = null, this._idleCheckInterval = window.setInterval(() => this._checkIfIdle(), 30 * 1e3), this._lastUsedTime = 0, this._configChangeListener = this._defaults.onDidChange(() => this._stopWorker());
6
+ this._defaults = e, this._worker = null, this._client = null, this._idleCheckInterval = window.setInterval(() => this._checkIfIdle(), 3e4), this._lastUsedTime = 0, this._configChangeListener = this._defaults.onDidChange(() => this._stopWorker());
8
7
  }
9
8
  _stopWorker() {
10
9
  this._worker &&= (this._worker.dispose(), null), this._client = null;
@@ -20,7 +19,7 @@ var b = 120 * 1e3, x = class {
20
19
  moduleId: "vs/language/html/htmlWorker",
21
20
  createWorker: () => new Worker(new URL(
22
21
  /* @vite-ignore */
23
- "/assets/html.worker-D2LKDpnG.js",
22
+ "/assets/html.worker-CO5LvJpF.js",
24
23
  "" + import.meta.url
25
24
  ), { type: "module" }),
26
25
  createData: {
@@ -1,4 +1,4 @@
1
- import { conf as e, language as t } from "./typescript-CPibXi3J.js";
1
+ import { conf as e, language as t } from "./typescript-BM-ynfk9.js";
2
2
  //#region node_modules/.pnpm/monaco-editor@0.55.1/node_modules/monaco-editor/esm/vs/basic-languages/javascript/javascript.js
3
3
  var n = e, r = {
4
4
  defaultToken: "invalid",
@@ -1,10 +1,9 @@
1
- import { c as e, u as t } from "./editor.api2-ClD5pp8H.js";
2
- import { t as n } from "./workers-Br7ThUKL.js";
3
- import { _ as r, a as i, c as a, d as o, f as s, g as c, h as l, i as u, l as d, m as f, n as p, o as m, p as h, r as g, s as _, t as v, u as y, v as b } from "./lspLanguageFeatures-Cdfs3EKq.js";
1
+ import { d as e, p as t, t as n } from "./workers-B9Eybl-M.js";
2
+ import { _ as r, a as i, c as a, d as o, f as s, g as c, h as l, i as u, l as d, m as f, n as p, o as m, p as h, r as g, s as _, t as v, u as y, v as b } from "./lspLanguageFeatures-V3e_p9oN.js";
4
3
  //#region node_modules/.pnpm/monaco-editor@0.55.1/node_modules/monaco-editor/esm/vs/language/json/workerManager.js
5
- var x = 120 * 1e3, S = class {
4
+ var x = 12e4, S = class {
6
5
  constructor(e) {
7
- this._defaults = e, this._worker = null, this._client = null, this._idleCheckInterval = window.setInterval(() => this._checkIfIdle(), 30 * 1e3), this._lastUsedTime = 0, this._configChangeListener = this._defaults.onDidChange(() => this._stopWorker());
6
+ this._defaults = e, this._worker = null, this._client = null, this._idleCheckInterval = window.setInterval(() => this._checkIfIdle(), 3e4), this._lastUsedTime = 0, this._configChangeListener = this._defaults.onDidChange(() => this._stopWorker());
8
7
  }
9
8
  _stopWorker() {
10
9
  this._worker &&= (this._worker.dispose(), null), this._client = null;
@@ -20,7 +19,7 @@ var x = 120 * 1e3, S = class {
20
19
  moduleId: "vs/language/json/jsonWorker",
21
20
  createWorker: () => new Worker(new URL(
22
21
  /* @vite-ignore */
23
- "/assets/json.worker-CJ5MmO5Q.js",
22
+ "/assets/json.worker-BezHzWUV.js",
24
23
  "" + import.meta.url
25
24
  ), { type: "module" }),
26
25
  label: this._defaults.languageId,
@@ -63,13 +62,17 @@ function C(e, t = !1) {
63
62
  let t = r;
64
63
  if (e.charCodeAt(r) === 48) r++;
65
64
  else for (r++; r < e.length && E(e.charCodeAt(r));) r++;
66
- if (r < e.length && e.charCodeAt(r) === 46) if (r++, r < e.length && E(e.charCodeAt(r))) for (r++; r < e.length && E(e.charCodeAt(r));) r++;
67
- else return d = 3, e.substring(t, r);
65
+ if (r < e.length && e.charCodeAt(r) === 46) {
66
+ if (r++, r < e.length && E(e.charCodeAt(r))) for (r++; r < e.length && E(e.charCodeAt(r));) r++;
67
+ else return d = 3, e.substring(t, r);
68
+ }
68
69
  let n = r;
69
- if (r < e.length && (e.charCodeAt(r) === 69 || e.charCodeAt(r) === 101)) if (r++, (r < e.length && e.charCodeAt(r) === 43 || e.charCodeAt(r) === 45) && r++, r < e.length && E(e.charCodeAt(r))) {
70
- for (r++; r < e.length && E(e.charCodeAt(r));) r++;
71
- n = r;
72
- } else d = 3;
70
+ if (r < e.length && (e.charCodeAt(r) === 69 || e.charCodeAt(r) === 101)) {
71
+ if (r++, (r < e.length && e.charCodeAt(r) === 43 || e.charCodeAt(r) === 45) && r++, r < e.length && E(e.charCodeAt(r))) {
72
+ for (r++; r < e.length && E(e.charCodeAt(r));) r++;
73
+ n = r;
74
+ } else d = 3;
75
+ }
73
76
  return e.substring(t, n);
74
77
  }
75
78
  function h() {
@@ -123,10 +126,13 @@ function C(e, t = !1) {
123
126
  i = r;
124
127
  continue;
125
128
  }
126
- if (a >= 0 && a <= 31) if (T(a)) {
127
- t += e.substring(i, r), d = 2;
128
- break;
129
- } else d = 6;
129
+ if (a >= 0 && a <= 31) {
130
+ if (T(a)) {
131
+ t += e.substring(i, r), d = 2;
132
+ break;
133
+ }
134
+ d = 6;
135
+ }
130
136
  r++;
131
137
  }
132
138
  return t;
@@ -313,9 +319,7 @@ function q(e, t, n, r = 0) {
313
319
  case 2:
314
320
  t = "\"" + t, i = 1;
315
321
  break;
316
- case 1:
317
- t = "/*" + t, i = 2;
318
- break;
322
+ case 1: t = "/*" + t, i = 2;
319
323
  }
320
324
  let o = A(t), s = n.lastWasColon, c = n.parents, l = {
321
325
  tokens: [],
@@ -355,17 +359,13 @@ function q(e, t, n, r = 0) {
355
359
  let e = (c ? c.type : 0) === 1;
356
360
  u = s || e ? B : H, s = !1;
357
361
  break;
358
- case 11:
359
- u = V, s = !1;
360
- break;
362
+ case 11: u = V, s = !1;
361
363
  }
362
364
  switch (d) {
363
365
  case 12:
364
366
  u = W;
365
367
  break;
366
- case 13:
367
- u = U;
368
- break;
368
+ case 13: u = U;
369
369
  }
370
370
  l.endState = new K(n.getStateData(), o.getTokenError(), s, c), l.tokens.push({
371
371
  startIndex: e,
@@ -1,4 +1,4 @@
1
- import { u as e } from "./editor.api2-ClD5pp8H.js";
1
+ import { p as e } from "./workers-B9Eybl-M.js";
2
2
  //#region node_modules/.pnpm/monaco-editor@0.55.1/node_modules/monaco-editor/esm/vs/basic-languages/liquid/liquid.js
3
3
  var t = [
4
4
  "area",
@@ -1,2 +1,2 @@
1
- export { pytrilogySyntaxVersion, trilogySyntaxReference, rulesInput, aggFunctions, functions, datatypes, } from './trilogySyntax.generated';
1
+ export { pytrilogySyntaxVersion, trilogySyntaxReference, rulesInput, aggFunctions, functions, datatypes, syntaxExamples, } from './trilogySyntax.generated';
2
2
  //# sourceMappingURL=constants.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../llm/data/constants.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,sBAAsB,EACtB,sBAAsB,EACtB,UAAU,EACV,YAAY,EACZ,SAAS,EACT,SAAS,GACV,MAAM,2BAA2B,CAAA"}
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../llm/data/constants.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,sBAAsB,EACtB,sBAAsB,EACtB,UAAU,EACV,YAAY,EACZ,SAAS,EACT,SAAS,EACT,cAAc,GACf,MAAM,2BAA2B,CAAA"}
@@ -1,7 +1,13 @@
1
- export declare const pytrilogySyntaxVersion = "0.3.337";
1
+ export declare const pytrilogySyntaxVersion = "0.3.370";
2
2
  export declare const trilogySyntaxReference = "# Trilogy Syntax\n\nTrilogy statements define a semantic model or a query; collections of statements\nare written as `.preql` files. A statement returns data (SELECT) or defines\nconcepts (key | property | auto | metric), datasources, or parameters.\n\nimport <model> as <alias>; makes a model's fields available. <model> is a DOT-SEPARATED MODULE PATH relative to the project root (where trilogy.toml lives), never a file path: the file `raw/store_sales.preql` is imported as `import raw.store_sales as ss;` \u2014 replace each `/` with `.`, drop the `.preql`, keep the folder segment. When an imported model imports others (a fact with imported dimensions), those are dot paths: `enroll.student.name`. Typical usage imports ONE fact and reaches dimensions through it; nested dimensions carry ALL values (order.customers includes customers without orders).\n\nkey | property | auto | metric; define new concepts. `auto x <- ...` is a DEFINITION, not a precomputed value: each reference expands and re-evaluates in the consuming query's scope.\n\nparameter NAME TYPE [default <literal>]; \u2014 a runtime value supplied via `--param NAME=VALUE` (repeatable); append `?` to the type to allow null.\n\n## Combining models\n\n| Goal | Use |\n|---|---|\n| Typical query | no merge, no join: access all fields through dot-paths |\n| Blend two models on shared keys inside one query | scoped `subset\\|union join` |\n| Make a connection universal to a whole file | `merge` |\n| Stack subsets/channels as rows | `union(...)` |\n| Rows in A but never in B (set difference) | `except(...)` |\n| Rows present in every source (set intersection) | `intersect(...)` |\n\n### Query-scoped join\n\nA typical fact already has its dimensions merged in, so no join is needed. Blending fact models or rowset outputs takes a scoped join, placed right after the select list, which DECLARES how the key domains relate: `subset join a = b` (a's values are contained in b's, a \u2286 b; b authoritative for the key) or `union join a = b` (neither contains the other; the key is the coalesce of both sides and unmatched rows from BOTH sides are kept).\n\nTwo rules decide whether the numbers are right, so apply them before reaching for the example:\n\n- Joins NEVER drop a row and NULL keys match null-safely; there is NO inner join. An intersection is an explicit `where <optional-side attr> is not null`.\n- JOIN ON THE FULL GRAIN: `explore` prints each fact's grain as @<k1, k2>; write one clause PER key. Matching only one key of a multi-key grain causes duplication.\n\nChaining, expression keys, union/subset mixing, multi-key and self-pair shapes: trilogy agent-info syntax example scoped-join.\n\nmerge <a> into ~<b>; is the persistent (whole-file) equivalent of `subset join a = b`; plain `merge a into b;` declares EXACT domain equivalence. Standalone statements; prefer a scoped join unless the connection is universal.\n\n### union / except / intersect (row set operations)\n\n`union(...)` row-stacks self-contained select arms positionally (SQL UNION ALL) into one named rowset (`with combined as union((armA), (armB), ...) -> (out1, out2, ...)`); `except(...)` / `intersect(...)` share that arm shape but are SQL SET operators (DISTINCT rows, null-safe whole-row compare, and except subtracts later arms from the FIRST, so arm order matters). Prefer except over a multi-column `not in` for \"in A but never in B\". Each arm dedups to its own output grain BEFORE stacking, so aggregate INSIDE each arm or the total silently undersums. Examples: trilogy agent-info syntax example union-stack-channels / except-intersect-setops.\n\n## Query structure\n\nTop-level statements first (each `;`-terminated), then a query with clauses in this EXACT order \u2014 all optional except select:\n\n```\n<top-level statements>; # import / key / auto / rowset / merge / def / parameter\nwith <name> as # optional: name the select as a reusable rowset (CTE)\nwhere <row condition> # 1. filters INPUT rows, BEFORE aggregation\nselect <col>, <agg> as name, # 2. projection \u2014 grouping is AUTOMATIC by the\n # non-aggregated columns; never write GROUP BY\n subset|union join a = b (= c)? # 3. blend models; one clause per key, right after the select list\nby rollup|cube|grouping sets (...) # 4. optional multi-level grouping for the whole select\nhaving <result condition> # 5. filters aggregated/joined RESULTS\norder by <col> asc|desc # 6. sort\nlimit <n>; # 7. cap rows\n```\n\nA rowset (`with <name> as where ... select ...;`) is a standalone statement, evaluated in isolation \u2014 it does NOT respond to the consuming query's context. All its outputs are namespaced: output `abc.def` of rowset `foo` is referenced as `foo.abc.def`, and joined back like any concept (`subset join foo.key = other.key`). Alias every reused expression with `as`.\n\nFull annotated example: trilogy agent-info syntax example query-structure.\n\n### Not SQL \u2014 what to never write\n\n- **No FROM, GROUP BY, DISTINCT, SELECT \\*, or SQL-style set operators between selects.** Stack rows with `union(...)`; set difference/intersection with `except(...)`/`intersect(...)`; blend fact models with a scoped join.\n- **Grouping is automatic** by the non-aggregated fields in the SELECT \u2014 never write GROUP BY. Aggregates inherit the select's grain wherever they appear (where/select/having). Override per-aggregate with `agg(x) by <dims>`; `by *` aggregates across all data (single row). To weight a related dimension property once per fact row, project it to the fact grain first: `auto row_birth_year <- group(enroll.student.birth_year) by enroll.student_id, enroll.course_id;` then aggregate that.\n- **Output rows are deduplicated to the select grain.** To preserve legitimate duplicates (one row per matching fact), include the fact's grain keys in the select \u2014 hidden with the PREFIX `--` if they shouldn't appear in the output.\n- **Never write `distinct`.** `count(<key>)` is already distinct because keys are unique; `count_distinct(<property>)` counts distinct values of a non-key property.\n- **Count a COMPOSITE grain with `grain(...)`.** `count(grain(order_id, item.id))` counts order+item combinations; `grain(...)` is NEVER NULL. Never count one column of a multi-key grain \u2014 a coarser key counts its own distinct values and undercounts. `count_distinct(a, b)` is accepted as sugar for `count(grain(a, b))` (distinct combinations, NULL members included).\n- **An aggregate over a group with no qualifying rows is NULL, never 0.** `sum(x ? cond) by k` yields NULL for groups where nothing matches, so `= 0` matches nothing. Test emptiness with `count(key ? cond) by k = 0` or wrap: `coalesce(sum(x ? cond), 0)`.\n- **`count(1)` is invalid** \u2014 a constant does not identify rows. Use the row key, `count(grain(...))`, or `sum(1) by <grain>`.\n- **One-column expression subqueries only.** `(select ...)` is allowed where a scalar or membership set is expected (exactly one projected column) \u2014 never as a SQL-style FROM-subquery. For related-entity filters prefer the dot-path: `where enrollments.student.state = 'TN'`, not a subselect.\n- **`--` is a HIDDEN-field prefix, not a comment** (it still changes query structure). Comments use `#` only.\n- **Aliases**: always use the full dot-path (`enroll.student.id`); alias every new expression with `as`; a select alias is usable in `having`/`order by` but NOT inside other select expressions or `where`, and must not rename a field back to an existing concept name.\n\n## Filtering\n\n`where` filters input rows before aggregation; `having` filters results after aggregation/windows. The inline filter `x ? cond` filters the immediate prior expression: `sum(credits ? enrolled = true)`.\n\nAggregates/windows in WHERE do not filter each other's inputs. Use inline filters, or a staged `then where` chain: each `then where` stage's aggregates compute over only the rows passing earlier stages (`where x = 5 then where sum(y) > 10` \u2261 `where x = 5 and sum(y ? x = 5) > 10`). One rule: the SAME cross-row expression cannot gate two different stages \u2014 give one an inline filter.\n\nWindows need all rows in their range: filter AFTER the window (in `having`) rather than in `where` when the window must see the full set.\n\n## Membership (semijoins)\n\n`in` / `not in` cross models without any declared relationship \u2014 the semijoin IS a scoped intersection. The right side is a concept or expression (never a subselect); build computed sets with an inline filter: `auto big_zip <- student.zip ? (count(student.id ? student.honors = true) by student.zip) > 10; ... where school.zip in big_zip`.\n\nMembership is IDENTITY matching, not SQL three-valued logic: NULL matches NULL; the result is always TRUE or FALSE (safe as a projected flag); `not in` is the exact complement (a NULL in the set never empties the result). For strict SQL behavior, add `x is not null`.\n\nA fact model contains ALL dimensional members, so `where students.id not in enroll.student_id` is typically a tautology \u2014 use `where enroll.id is null` instead. Tuple membership `(a, b) in (m.a, m.b)` requires both right-side concepts to resolve to ONE source (model or rowset); to test against a cross-model pair, stage it through a rowset first. Examples: existence-anti-join, staged-membership.\n\n## Aggregation\n\nAn aggregate without an explicit `by` is RESPONSIVE \u2014 its grain is set where it is consumed, not where it is declared (`auto avg_credits <- avg(enroll.credits);` becomes per-department when selected with `enroll.department`). Pin a grain inline: `sum(metric) by dim1, dim2 as name`; `by` accepts bare identifiers or parenthesized expressions: `avg(price) by (substring(phone, 1, 2))`.\n\nMulti-level grouping (`by rollup|cube|grouping sets (...)`) is a clause of the WHOLE select, placed before `having`: it computes every no-explicit-grain aggregate at every level in one pass (`by rollup (d1, d2)` \u2192 leaf, per-d1 subtotal, grand total). `grouping(<field>)` = 1 on rolled-up rows \u2014 use it to label levels rather than testing for NULL. Full detail: trilogy agent-info syntax example rollup.\n\n## Window functions\n\nDefault to windows for self-referential queries (period-over-period, running totals, rank, share of group). SQL-style syntax: `rank(<key>) over (partition by <g> order by <expr> desc)` (`dense_rank`/`row_number` same shape; multi-key `rank(a, b)`); `sum(x) over (partition by g order by t)` for running totals; `lag(<field>, <offset>) over (...)` / `lead(...)` for offsets (default 1). `partition by` is optional and accepts expressions.\n\n## Data types\n\nScalars: `string`, `bytes`, `bool`, `int`, `bigint`, `float`, `double`, `number`, `numeric(p,s)` (alias `decimal`; use for exact money), `date`, `datetime`, `timestamp`, `geography`, `any`. Composites: `array<T>`, `map<K, V>`, `struct<name: T, ...>`, `enum<T>[v1, v2, ...]`. Cast with `::type` or `cast(x as type)`: `\"2020-01-01\"::date`.\n\n`?` after a type marks it nullable (`property user.middle_name string?;`). `~` prefixing a concept marks the reference as a PARTIAL subset of the concept's domain \u2014 on a select item (`~customer.id`) or in `merge a into ~b` (a \u2286 b); it tells the planner this side is not authoritative.\n\n## Expression gotchas\n\n- `x ? cond` binds to a primary \u2014 wrap arithmetic: `(a - b) ? cond`, NOT `a - b ? cond`.\n- `a || b` is NULL if either side is NULL; `concat(...)` skips NULL arguments; `concat_ws(sep, ...)` joins with sep, skipping NULLs.\n- Date parts are unquoted: `date_part(d, year)`, never `'year'`; prefer `year(d)`. `date_diff(start, end, unit)` = end \u2212 start (a shipping lag is `date_diff(sold_date, ship_date, day)`).\n- Zero-argument functions still take parentheses: `current_date()`.\n- Factor repeated calculations into a `def` macro (invoked `@name(...)`) or reusable `auto` concepts.\n\n\nFunctions (the `aggregate` family doubles as the Aggregate Functions list):\naggregate: count|count_distinct|sum|max|min|avg|stddev|variance|array_agg|bool_or|bool_and|any|grouping(<arg1>) ; grouping_id(<arg1>, <arg2>, ..., <argN>)\nstring: concat|concat_strict|concat_ws(<arg1>, <arg2>, ..., <argN>) ; split|strpos|contains|trim|regexp_contains|format_time|parse_time(<arg1>, <arg2>) ; len|lower|upper|ltrim|rtrim|hex(<arg1>) ; substring|replace|regexp_extract|regexp_replace(<arg1>, <arg2>, <arg3>)\ndate/time: date|datetime|timestamp|second|minute|hour|day|day_of_week|week|month|quarter|year|month_name|day_name|unix_to_timestamp(<arg1>) ; date_spine(<arg1>, <arg2>) ; current_date|current_datetime()\n date_part(<arg1>, <arg2>) e.g. date_part('2020-01-01'::date, year)\n date_truncate(<arg1>, <arg2>) e.g. date_trunc('2020-01-01'::date, month)\n date_add(<arg1>, <arg2>, <arg3>) e.g. date_add('2020-01-01'::date, month, 1)\n date_sub(<arg1>, <arg2>, <arg3>) e.g. date_sub('2020-01-01'::date, day, 1)\n date_diff(<arg1>, <arg2>, <arg3>) e.g. date_diff('2020-01-01'::date, '2020-01-02'::date, day)\n current_timestamp() e.g. now()\narray/map/struct: unnest|array_distinct|array_sum|map_keys|map_values(<arg1>) ; struct|array(<arg1>, <arg2>, ..., <argN>) ; array_sort|array_to_string(<arg1>, <arg2>) ; array_transform|array_filter|generate_array(<arg1>, <arg2>, <arg3>)\nmath: mod|round|log|power|hash(<arg1>, <arg2>) ; abs|sqrt|random|floor|ceil(<arg1>)\nconditional/cast: case|simple_case|coalesce|greatest|least(<arg1>, <arg2>, ..., <argN>) ; cast|nullif(<arg1>, <arg2>) ; isnull(<arg1>)\ngeo: geo_from_text|geo_x|geo_y|geo_centroid(<arg1>) ; geo_point|geo_distance(<arg1>, <arg2>) ; geo_transform(<arg1>, <arg2>, <arg3>)\nother: is_not_distinct(<arg1>, <arg2>)\n\nSome types carry trait metadata that adds meaning: 'latitude', 'longitude' and 'currency' are all 'float' with extra semantics.\n\nAdditional syntax examples:\nThese less-common patterns have complete, copy-pasteable examples. Do NOT guess\nthe syntax \u2014 print the full example on demand with\n`trilogy agent-info syntax example <name>`:\n- `python-datasource` - run a local Python script as a datasource: wrap a function in `trilogy.io.run`, which writes the Arrow IPC stream to stdout for you from a table, dataframe, or list of dicts; declare concepts, map script columns in `datasource (...)`, use `grain (...) file `path.py`;`, then reference locally declared concepts WITHOUT the datasource name as a prefix\n- `query-structure` - the exact clause order of a query, and how to define a rowset\n- `chart` - drawing a result rather than tabulating it: `chart layer <type> ( <role> <- <expr> as <name>, ... )` is a STATEMENT that wraps its own query - the bindings ARE the select; layers, roles, scales, reference lines and `from <select>`\n- `filtered-aggregate` - aggregating only the rows matching a condition, and counting rows correctly\n- `row-level-where-vs-having` - choosing between WHERE and HAVING for a threshold condition\n- `nested-aggregate-group-average` - the \"above 1.2x the group norm\" ask: inner `sum(x) by entity, group`, outer `avg(inner) by group`; use WHERE for the comparison when a separate output-only filter must not narrow the benchmark\n- `pivot-columns` - turn distinct values of a dimension into columns with a reusable `def` macro + filtered aggregate\n- `case-when` - `case when <cond> then <val> ... else <val> end` to relabel codes or bucket a measure into a derived value, then group by it\n- `window-period-over-period` - `lead`/`lag` over (order by ...) to compare a row to an offset period; build a scoped set with `<col> ? <cond>` and filter with `in`\n- `union-stack-channels` - stacking several sources/channels together as rows\n- `except-intersect-setops` - set difference or co-occurrence across sources\n- `scoped-join` - blending a second fact model or rowset into one query\n- `existence-anti-join` - keeping or excluding rows by whether a key matches another model\n- `set-intersect-difference` - count tuples present in / absent from other groups via per-group presence flags - the multi-column INTERSECT/EXCEPT idiom\n- `dedup-before-aggregate` - a `rowset <- select <cols>` collapses identical tuples to one row (SELECT-grain group by) before a downstream sum - the `distinct`/UNION substitute\n- `rollup` - subtotals and a grand total in one pass, and labeling the levels\n- `rank-over-rollup` - rank rollup subtotals/leaves with a SINGLE `rank(a,b) over (partition by level, parent ...)` - not separate ranks per level\n- `staged-membership` - filtering a fine-grain query by a set computed at a coarser grain\n- `correlated-exists-via-grouped-counts` - translate `EXISTS other` / `NOT EXISTS other matching` over the same model into two `count(...) by <grain>` compared in `where` (`> 1` = another exists, `= 1` = no other matches) - pin the correlation grain with `by`";
3
3
  export declare const rulesInput = "# Trilogy Syntax\n\nTrilogy statements define a semantic model or a query; collections of statements\nare written as `.preql` files. A statement returns data (SELECT) or defines\nconcepts (key | property | auto | metric), datasources, or parameters.\n\nimport <model> as <alias>; makes a model's fields available. <model> is a DOT-SEPARATED MODULE PATH relative to the project root (where trilogy.toml lives), never a file path: the file `raw/store_sales.preql` is imported as `import raw.store_sales as ss;` \u2014 replace each `/` with `.`, drop the `.preql`, keep the folder segment. When an imported model imports others (a fact with imported dimensions), those are dot paths: `enroll.student.name`. Typical usage imports ONE fact and reaches dimensions through it; nested dimensions carry ALL values (order.customers includes customers without orders).\n\nkey | property | auto | metric; define new concepts. `auto x <- ...` is a DEFINITION, not a precomputed value: each reference expands and re-evaluates in the consuming query's scope.\n\nparameter NAME TYPE [default <literal>]; \u2014 a runtime value supplied via `--param NAME=VALUE` (repeatable); append `?` to the type to allow null.\n\n## Combining models\n\n| Goal | Use |\n|---|---|\n| Typical query | no merge, no join: access all fields through dot-paths |\n| Blend two models on shared keys inside one query | scoped `subset\\|union join` |\n| Make a connection universal to a whole file | `merge` |\n| Stack subsets/channels as rows | `union(...)` |\n| Rows in A but never in B (set difference) | `except(...)` |\n| Rows present in every source (set intersection) | `intersect(...)` |\n\n### Query-scoped join\n\nA typical fact already has its dimensions merged in, so no join is needed. Blending fact models or rowset outputs takes a scoped join, placed right after the select list, which DECLARES how the key domains relate: `subset join a = b` (a's values are contained in b's, a \u2286 b; b authoritative for the key) or `union join a = b` (neither contains the other; the key is the coalesce of both sides and unmatched rows from BOTH sides are kept).\n\nTwo rules decide whether the numbers are right, so apply them before reaching for the example:\n\n- Joins NEVER drop a row and NULL keys match null-safely; there is NO inner join. An intersection is an explicit `where <optional-side attr> is not null`.\n- JOIN ON THE FULL GRAIN: `explore` prints each fact's grain as @<k1, k2>; write one clause PER key. Matching only one key of a multi-key grain causes duplication.\n\nChaining, expression keys, union/subset mixing, multi-key and self-pair shapes: trilogy agent-info syntax example scoped-join.\n\nmerge <a> into ~<b>; is the persistent (whole-file) equivalent of `subset join a = b`; plain `merge a into b;` declares EXACT domain equivalence. Standalone statements; prefer a scoped join unless the connection is universal.\n\n### union / except / intersect (row set operations)\n\n`union(...)` row-stacks self-contained select arms positionally (SQL UNION ALL) into one named rowset (`with combined as union((armA), (armB), ...) -> (out1, out2, ...)`); `except(...)` / `intersect(...)` share that arm shape but are SQL SET operators (DISTINCT rows, null-safe whole-row compare, and except subtracts later arms from the FIRST, so arm order matters). Prefer except over a multi-column `not in` for \"in A but never in B\". Each arm dedups to its own output grain BEFORE stacking, so aggregate INSIDE each arm or the total silently undersums. Examples: trilogy agent-info syntax example union-stack-channels / except-intersect-setops.\n\n## Query structure\n\nTop-level statements first (each `;`-terminated), then a query with clauses in this EXACT order \u2014 all optional except select:\n\n```\n<top-level statements>; # import / key / auto / rowset / merge / def / parameter\nwith <name> as # optional: name the select as a reusable rowset (CTE)\nwhere <row condition> # 1. filters INPUT rows, BEFORE aggregation\nselect <col>, <agg> as name, # 2. projection \u2014 grouping is AUTOMATIC by the\n # non-aggregated columns; never write GROUP BY\n subset|union join a = b (= c)? # 3. blend models; one clause per key, right after the select list\nby rollup|cube|grouping sets (...) # 4. optional multi-level grouping for the whole select\nhaving <result condition> # 5. filters aggregated/joined RESULTS\norder by <col> asc|desc # 6. sort\nlimit <n>; # 7. cap rows\n```\n\nA rowset (`with <name> as where ... select ...;`) is a standalone statement, evaluated in isolation \u2014 it does NOT respond to the consuming query's context. All its outputs are namespaced: output `abc.def` of rowset `foo` is referenced as `foo.abc.def`, and joined back like any concept (`subset join foo.key = other.key`). Alias every reused expression with `as`.\n\nFull annotated example: trilogy agent-info syntax example query-structure.\n\n### Not SQL \u2014 what to never write\n\n- **No FROM, GROUP BY, DISTINCT, SELECT \\*, or SQL-style set operators between selects.** Stack rows with `union(...)`; set difference/intersection with `except(...)`/`intersect(...)`; blend fact models with a scoped join.\n- **Grouping is automatic** by the non-aggregated fields in the SELECT \u2014 never write GROUP BY. Aggregates inherit the select's grain wherever they appear (where/select/having). Override per-aggregate with `agg(x) by <dims>`; `by *` aggregates across all data (single row). To weight a related dimension property once per fact row, project it to the fact grain first: `auto row_birth_year <- group(enroll.student.birth_year) by enroll.student_id, enroll.course_id;` then aggregate that.\n- **Output rows are deduplicated to the select grain.** To preserve legitimate duplicates (one row per matching fact), include the fact's grain keys in the select \u2014 hidden with the PREFIX `--` if they shouldn't appear in the output.\n- **Never write `distinct`.** `count(<key>)` is already distinct because keys are unique; `count_distinct(<property>)` counts distinct values of a non-key property.\n- **Count a COMPOSITE grain with `grain(...)`.** `count(grain(order_id, item.id))` counts order+item combinations; `grain(...)` is NEVER NULL. Never count one column of a multi-key grain \u2014 a coarser key counts its own distinct values and undercounts. `count_distinct(a, b)` is accepted as sugar for `count(grain(a, b))` (distinct combinations, NULL members included).\n- **An aggregate over a group with no qualifying rows is NULL, never 0.** `sum(x ? cond) by k` yields NULL for groups where nothing matches, so `= 0` matches nothing. Test emptiness with `count(key ? cond) by k = 0` or wrap: `coalesce(sum(x ? cond), 0)`.\n- **`count(1)` is invalid** \u2014 a constant does not identify rows. Use the row key, `count(grain(...))`, or `sum(1) by <grain>`.\n- **One-column expression subqueries only.** `(select ...)` is allowed where a scalar or membership set is expected (exactly one projected column) \u2014 never as a SQL-style FROM-subquery. For related-entity filters prefer the dot-path: `where enrollments.student.state = 'TN'`, not a subselect.\n- **`--` is a HIDDEN-field prefix, not a comment** (it still changes query structure). Comments use `#` only.\n- **Aliases**: always use the full dot-path (`enroll.student.id`); alias every new expression with `as`; a select alias is usable in `having`/`order by` but NOT inside other select expressions or `where`, and must not rename a field back to an existing concept name.\n\n## Filtering\n\n`where` filters input rows before aggregation; `having` filters results after aggregation/windows. The inline filter `x ? cond` filters the immediate prior expression: `sum(credits ? enrolled = true)`.\n\nAggregates/windows in WHERE do not filter each other's inputs. Use inline filters, or a staged `then where` chain: each `then where` stage's aggregates compute over only the rows passing earlier stages (`where x = 5 then where sum(y) > 10` \u2261 `where x = 5 and sum(y ? x = 5) > 10`). One rule: the SAME cross-row expression cannot gate two different stages \u2014 give one an inline filter.\n\nWindows need all rows in their range: filter AFTER the window (in `having`) rather than in `where` when the window must see the full set.\n\n## Membership (semijoins)\n\n`in` / `not in` cross models without any declared relationship \u2014 the semijoin IS a scoped intersection. The right side is a concept or expression (never a subselect); build computed sets with an inline filter: `auto big_zip <- student.zip ? (count(student.id ? student.honors = true) by student.zip) > 10; ... where school.zip in big_zip`.\n\nMembership is IDENTITY matching, not SQL three-valued logic: NULL matches NULL; the result is always TRUE or FALSE (safe as a projected flag); `not in` is the exact complement (a NULL in the set never empties the result). For strict SQL behavior, add `x is not null`.\n\nA fact model contains ALL dimensional members, so `where students.id not in enroll.student_id` is typically a tautology \u2014 use `where enroll.id is null` instead. Tuple membership `(a, b) in (m.a, m.b)` requires both right-side concepts to resolve to ONE source (model or rowset); to test against a cross-model pair, stage it through a rowset first. Examples: existence-anti-join, staged-membership.\n\n## Aggregation\n\nAn aggregate without an explicit `by` is RESPONSIVE \u2014 its grain is set where it is consumed, not where it is declared (`auto avg_credits <- avg(enroll.credits);` becomes per-department when selected with `enroll.department`). Pin a grain inline: `sum(metric) by dim1, dim2 as name`; `by` accepts bare identifiers or parenthesized expressions: `avg(price) by (substring(phone, 1, 2))`.\n\nMulti-level grouping (`by rollup|cube|grouping sets (...)`) is a clause of the WHOLE select, placed before `having`: it computes every no-explicit-grain aggregate at every level in one pass (`by rollup (d1, d2)` \u2192 leaf, per-d1 subtotal, grand total). `grouping(<field>)` = 1 on rolled-up rows \u2014 use it to label levels rather than testing for NULL. Full detail: trilogy agent-info syntax example rollup.\n\n## Window functions\n\nDefault to windows for self-referential queries (period-over-period, running totals, rank, share of group). SQL-style syntax: `rank(<key>) over (partition by <g> order by <expr> desc)` (`dense_rank`/`row_number` same shape; multi-key `rank(a, b)`); `sum(x) over (partition by g order by t)` for running totals; `lag(<field>, <offset>) over (...)` / `lead(...)` for offsets (default 1). `partition by` is optional and accepts expressions.\n\n## Data types\n\nScalars: `string`, `bytes`, `bool`, `int`, `bigint`, `float`, `double`, `number`, `numeric(p,s)` (alias `decimal`; use for exact money), `date`, `datetime`, `timestamp`, `geography`, `any`. Composites: `array<T>`, `map<K, V>`, `struct<name: T, ...>`, `enum<T>[v1, v2, ...]`. Cast with `::type` or `cast(x as type)`: `\"2020-01-01\"::date`.\n\n`?` after a type marks it nullable (`property user.middle_name string?;`). `~` prefixing a concept marks the reference as a PARTIAL subset of the concept's domain \u2014 on a select item (`~customer.id`) or in `merge a into ~b` (a \u2286 b); it tells the planner this side is not authoritative.\n\n## Expression gotchas\n\n- `x ? cond` binds to a primary \u2014 wrap arithmetic: `(a - b) ? cond`, NOT `a - b ? cond`.\n- `a || b` is NULL if either side is NULL; `concat(...)` skips NULL arguments; `concat_ws(sep, ...)` joins with sep, skipping NULLs.\n- Date parts are unquoted: `date_part(d, year)`, never `'year'`; prefer `year(d)`. `date_diff(start, end, unit)` = end \u2212 start (a shipping lag is `date_diff(sold_date, ship_date, day)`).\n- Zero-argument functions still take parentheses: `current_date()`.\n- Factor repeated calculations into a `def` macro (invoked `@name(...)`) or reusable `auto` concepts.";
4
4
  export declare const aggFunctions: string[];
5
5
  export declare const functions: string[];
6
6
  export declare const datatypes: string[];
7
+ export declare const syntaxExamples: {
8
+ name: string;
9
+ title: string;
10
+ summary: string;
11
+ body: string;
12
+ }[];
7
13
  //# sourceMappingURL=trilogySyntax.generated.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"trilogySyntax.generated.d.ts","sourceRoot":"","sources":["../../../llm/data/trilogySyntax.generated.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,sBAAsB,YAAY,CAAA;AAC/C,eAAO,MAAM,sBAAsB,mjhBAA27gB,CAAA;AAC99gB,eAAO,MAAM,UAAU,+vXAA4oX,CAAA;AACnqX,eAAO,MAAM,YAAY,UAExB,CAAA;AACD,eAAO,MAAM,SAAS,UAerB,CAAA;AACD,eAAO,MAAM,SAAS,UAsBrB,CAAA"}
1
+ {"version":3,"file":"trilogySyntax.generated.d.ts","sourceRoot":"","sources":["../../../llm/data/trilogySyntax.generated.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,sBAAsB,YAAY,CAAA;AAC/C,eAAO,MAAM,sBAAsB,mjhBAA27gB,CAAA;AAC99gB,eAAO,MAAM,UAAU,+vXAA4oX,CAAA;AACnqX,eAAO,MAAM,YAAY,UAExB,CAAA;AACD,eAAO,MAAM,SAAS,UAerB,CAAA;AACD,eAAO,MAAM,SAAS,UAsBrB,CAAA;AACD,eAAO,MAAM,cAAc;;;;;GAmH1B,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"docsIndex.d.ts","sourceRoot":"","sources":["../../llm/docsIndex.ts"],"names":[],"mappings":"AAQA,MAAM,WAAW,QAAQ;IACvB,+EAA+E;IAC/E,EAAE,EAAE,MAAM,CAAA;IACV,SAAS,EAAE,MAAM,CAAA;IACjB,YAAY,EAAE,MAAM,CAAA;IACpB,cAAc,EAAE,MAAM,CAAA;IACtB,OAAO,EAAE,MAAM,CAAA;IACf,IAAI,EAAE,KAAK,GAAG,UAAU,GAAG,UAAU,CAAA;CACtC;AAED,MAAM,WAAW,SAAS;IACxB,KAAK,EAAE,QAAQ,CAAA;IACf,KAAK,EAAE,MAAM,CAAA;IACb,OAAO,EAAE,MAAM,CAAA;CAChB;AA0CD,wBAAgB,cAAc,IAAI,QAAQ,EAAE,CA4C3C;AA2CD,wBAAgB,UAAU,CACxB,KAAK,EAAE,MAAM,EACb,IAAI,GAAE;IAAE,KAAK,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC,CAAA;CAAO,GACrD,SAAS,EAAE,CAYb;AAED,MAAM,WAAW,UAAU;IACzB,EAAE,EAAE,MAAM,CAAA;IACV,SAAS,EAAE,MAAM,CAAA;IACjB,YAAY,EAAE,MAAM,CAAA;IACpB,UAAU,EAAE,KAAK,CAAC;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;CACtD;AAED;+EAC+E;AAC/E,wBAAgB,UAAU,CAAC,EAAE,EAAE,MAAM,GAAG,UAAU,GAAG,IAAI,CAaxD;AAED,iDAAiD;AACjD,wBAAgB,sBAAsB,IAAI,IAAI,CAE7C"}
1
+ {"version":3,"file":"docsIndex.d.ts","sourceRoot":"","sources":["../../llm/docsIndex.ts"],"names":[],"mappings":"AAQA,MAAM,WAAW,QAAQ;IACvB,+EAA+E;IAC/E,EAAE,EAAE,MAAM,CAAA;IACV,SAAS,EAAE,MAAM,CAAA;IACjB,YAAY,EAAE,MAAM,CAAA;IACpB,cAAc,EAAE,MAAM,CAAA;IACtB,OAAO,EAAE,MAAM,CAAA;IACf,IAAI,EAAE,KAAK,GAAG,UAAU,GAAG,UAAU,CAAA;CACtC;AAED,MAAM,WAAW,SAAS;IACxB,KAAK,EAAE,QAAQ,CAAA;IACf,KAAK,EAAE,MAAM,CAAA;IACb,OAAO,EAAE,MAAM,CAAA;CAChB;AA4CD,wBAAgB,cAAc,IAAI,QAAQ,EAAE,CAqE3C;AA2CD,wBAAgB,UAAU,CACxB,KAAK,EAAE,MAAM,EACb,IAAI,GAAE;IAAE,KAAK,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC,CAAA;CAAO,GACrD,SAAS,EAAE,CAYb;AAED,MAAM,WAAW,UAAU;IACzB,EAAE,EAAE,MAAM,CAAA;IACV,SAAS,EAAE,MAAM,CAAA;IACjB,YAAY,EAAE,MAAM,CAAA;IACpB,UAAU,EAAE,KAAK,CAAC;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;CACtD;AAED;+EAC+E;AAC/E,wBAAgB,UAAU,CAAC,EAAE,EAAE,MAAM,GAAG,UAAU,GAAG,IAAI,CAaxD;AAED,iDAAiD;AACjD,wBAAgB,sBAAsB,IAAI,IAAI,CAE7C"}
@@ -16,6 +16,7 @@ export declare function parseOpenAIModelVersion(model: string): {
16
16
  */
17
17
  export declare function compareOpenAIModels(a: string, b: string): number;
18
18
  export declare class OpenAIProvider extends LLMProvider {
19
+ static readonly DEFAULT_MODEL = "gpt-6-luna";
19
20
  private baseCompletionUrl;
20
21
  private baseModelUrl;
21
22
  models: string[];
@@ -37,7 +38,7 @@ export declare class OpenAIProvider extends LLMProvider {
37
38
  static filterModels(models: string[]): string[];
38
39
  /**
39
40
  * Get the default model to use for OpenAI.
40
- * Returns the latest gpt-X.y model (not mini or other variants).
41
+ * Prefer GPT-6 Luna, falling back to the latest non-variant model when unavailable.
41
42
  * @param models - Array of model IDs (already filtered)
42
43
  * @returns The default model ID to use
43
44
  */
@@ -1 +1 @@
1
- {"version":3,"file":"openai.d.ts","sourceRoot":"","sources":["../../llm/openai.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AACpC,OAAO,KAAK,EAAE,iBAAiB,EAAE,WAAW,EAAE,UAAU,EAAe,MAAM,QAAQ,CAAA;AACrF,OAAO,EAAkB,KAAK,YAAY,EAAE,MAAM,SAAS,CAAA;AAC3D;;;;;GAKG;AACH,wBAAgB,uBAAuB,CACrC,KAAK,EAAE,MAAM,GACZ;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAA;CAAE,GAAG,IAAI,CAoBxE;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,CA6BhE;AAED,qBAAa,cAAe,SAAQ,WAAW;IAC7C,OAAO,CAAC,iBAAiB,CAAgD;IACzE,OAAO,CAAC,YAAY,CAA6C;IAC1D,MAAM,EAAE,MAAM,EAAE,CAAA;IAChB,IAAI,EAAE,MAAM,CAAW;IAC9B,OAAO,CAAC,YAAY,CAAc;gBAGhC,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,MAAM,EACd,KAAK,EAAE,MAAM,EACb,cAAc,GAAE,OAAe,EAC/B,YAAY,CAAC,EAAE,YAAY;IAiB7B;;;OAGG;WACU,mBAAmB,CAAC,QAAQ,EAAE,QAAQ,GAAG,OAAO,CAAC,MAAM,CAAC;IAY/D,KAAK,IAAI,OAAO,CAAC,IAAI,CAAC;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