drizzle-cube 0.4.7 → 0.4.8

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 (122) hide show
  1. package/dist/adapters/express/index.cjs +1 -1
  2. package/dist/adapters/express/index.js +2 -2
  3. package/dist/adapters/fastify/index.cjs +1 -1
  4. package/dist/adapters/fastify/index.js +2 -2
  5. package/dist/adapters/handler-BLcxTuwi.cjs +23 -0
  6. package/dist/adapters/handler-odjn7MIB.js +1880 -0
  7. package/dist/adapters/hono/index.cjs +1 -1
  8. package/dist/adapters/hono/index.js +2 -2
  9. package/dist/adapters/{mcp-transport-DFTCWene.js → mcp-transport-CU5g9bxj.js} +3 -3
  10. package/dist/adapters/{mcp-transport-BB998cy5.cjs → mcp-transport-KX92EgkF.cjs} +2 -2
  11. package/dist/adapters/nextjs/index.cjs +2 -2
  12. package/dist/adapters/nextjs/index.js +3 -3
  13. package/dist/client/charts/chartConfigs.d.ts +2 -9
  14. package/dist/client/charts.js +72 -70
  15. package/dist/client/charts.js.map +1 -1
  16. package/dist/client/chunks/{RetentionCombinedChart.config-C-ILIaEb.js → RetentionCombinedChart.config-Bbp2ghim.js} +2 -1
  17. package/dist/client/chunks/RetentionCombinedChart.config-Bbp2ghim.js.map +1 -0
  18. package/dist/client/chunks/{RetentionHeatmap.config-CIvhc-GT.js → RetentionHeatmap.config-BWf_-vdj.js} +2 -1
  19. package/dist/client/chunks/RetentionHeatmap.config-BWf_-vdj.js.map +1 -0
  20. package/dist/client/chunks/{analysis-builder-Dn8xpgPQ.js → analysis-builder-Bov_gLsf.js} +1408 -1393
  21. package/dist/client/chunks/analysis-builder-Bov_gLsf.js.map +1 -0
  22. package/dist/client/chunks/{analysis-builder-shared-D3xYzXlh.js → analysis-builder-shared-NBk6y0md.js} +3 -3
  23. package/dist/client/chunks/{analysis-builder-shared-D3xYzXlh.js.map → analysis-builder-shared-NBk6y0md.js.map} +1 -1
  24. package/dist/client/chunks/{chart-activity-grid-DStNr34n.js → chart-activity-grid-CE7xGFQo.js} +2 -2
  25. package/dist/client/chunks/{chart-activity-grid-DStNr34n.js.map → chart-activity-grid-CE7xGFQo.js.map} +1 -1
  26. package/dist/client/chunks/chart-box-plot-Dja4LS3O.js +313 -0
  27. package/dist/client/chunks/chart-box-plot-Dja4LS3O.js.map +1 -0
  28. package/dist/client/chunks/{chart-config-activity-grid-CAlo1cHA.js → chart-config-activity-grid-CmOqDuOT.js} +4 -5
  29. package/dist/client/chunks/chart-config-activity-grid-CmOqDuOT.js.map +1 -0
  30. package/dist/client/chunks/{chart-config-area-CyyJOO2T.js → chart-config-area-CK_GVApT.js} +4 -5
  31. package/dist/client/chunks/chart-config-area-CK_GVApT.js.map +1 -0
  32. package/dist/client/chunks/{chart-config-bar-soxw6m2o.js → chart-config-bar-C8uzktxl.js} +4 -5
  33. package/dist/client/chunks/chart-config-bar-C8uzktxl.js.map +1 -0
  34. package/dist/client/chunks/chart-config-box-plot-D3DA7_pr.js +85 -0
  35. package/dist/client/chunks/chart-config-box-plot-D3DA7_pr.js.map +1 -0
  36. package/dist/client/chunks/{chart-config-bubble-CuSsCHZ4.js → chart-config-bubble-q3DoQX5F.js} +4 -5
  37. package/dist/client/chunks/chart-config-bubble-q3DoQX5F.js.map +1 -0
  38. package/dist/client/chunks/{chart-config-data-table-BhgqwoqT.js → chart-config-data-table-B20Y5JCm.js} +4 -5
  39. package/dist/client/chunks/chart-config-data-table-B20Y5JCm.js.map +1 -0
  40. package/dist/client/chunks/{chart-config-funnel-BlSQYng0.js → chart-config-funnel-3eYnGg8M.js} +4 -5
  41. package/dist/client/chunks/chart-config-funnel-3eYnGg8M.js.map +1 -0
  42. package/dist/client/chunks/{chart-config-heat-map-DHQGFZhX.js → chart-config-heat-map-_wEnTnRA.js} +4 -5
  43. package/dist/client/chunks/chart-config-heat-map-_wEnTnRA.js.map +1 -0
  44. package/dist/client/chunks/{chart-config-kpi-delta-yTA5ug_l.js → chart-config-kpi-delta-DLGZ2A3X.js} +4 -5
  45. package/dist/client/chunks/chart-config-kpi-delta-DLGZ2A3X.js.map +1 -0
  46. package/dist/client/chunks/{chart-config-kpi-number-nVAwDXzq.js → chart-config-kpi-number-K-wzviXF.js} +4 -5
  47. package/dist/client/chunks/chart-config-kpi-number-K-wzviXF.js.map +1 -0
  48. package/dist/client/chunks/{chart-config-kpi-text-DZjqsx-b.js → chart-config-kpi-text-BjYqwqaJ.js} +4 -5
  49. package/dist/client/chunks/chart-config-kpi-text-BjYqwqaJ.js.map +1 -0
  50. package/dist/client/chunks/{chart-config-line-D5ME6w0v.js → chart-config-line-JNagi9tf.js} +4 -5
  51. package/dist/client/chunks/chart-config-line-JNagi9tf.js.map +1 -0
  52. package/dist/client/chunks/{chart-config-markdown-BXKL5TbQ.js → chart-config-markdown-BWQSjJpy.js} +4 -5
  53. package/dist/client/chunks/chart-config-markdown-BWQSjJpy.js.map +1 -0
  54. package/dist/client/chunks/{chart-config-pie-DlHa2jTy.js → chart-config-pie-CNLXb-fr.js} +4 -5
  55. package/dist/client/chunks/chart-config-pie-CNLXb-fr.js.map +1 -0
  56. package/dist/client/chunks/{chart-config-radar-BBAVIF0S.js → chart-config-radar-oxHfRAa3.js} +4 -5
  57. package/dist/client/chunks/chart-config-radar-oxHfRAa3.js.map +1 -0
  58. package/dist/client/chunks/{chart-config-radial-bar-CTwjDRnB.js → chart-config-radial-bar-_Aw3jAEm.js} +4 -5
  59. package/dist/client/chunks/chart-config-radial-bar-_Aw3jAEm.js.map +1 -0
  60. package/dist/client/chunks/{chart-config-sankey-CNAgsMQ4.js → chart-config-sankey-C8FX9hGF.js} +4 -5
  61. package/dist/client/chunks/chart-config-sankey-C8FX9hGF.js.map +1 -0
  62. package/dist/client/chunks/{chart-config-scatter-CWvN2E-X.js → chart-config-scatter-DFKM80eO.js} +4 -5
  63. package/dist/client/chunks/chart-config-scatter-DFKM80eO.js.map +1 -0
  64. package/dist/client/chunks/{chart-config-sunburst-W_SKwaj0.js → chart-config-sunburst-BmC0NLTU.js} +4 -5
  65. package/dist/client/chunks/chart-config-sunburst-BmC0NLTU.js.map +1 -0
  66. package/dist/client/chunks/{chart-config-tree-map-IRAYf9YM.js → chart-config-tree-map-DGMbNTaa.js} +4 -5
  67. package/dist/client/chunks/chart-config-tree-map-DGMbNTaa.js.map +1 -0
  68. package/dist/client/chunks/{chart-data-table-Ch_1c1Zo.js → chart-data-table-Ba_6tuJw.js} +2 -2
  69. package/dist/client/chunks/{chart-data-table-Ch_1c1Zo.js.map → chart-data-table-Ba_6tuJw.js.map} +1 -1
  70. package/dist/client/chunks/{chart-kpi-delta-CWCmi8vL.js → chart-kpi-delta-D9XJoKuA.js} +3 -3
  71. package/dist/client/chunks/{chart-kpi-delta-CWCmi8vL.js.map → chart-kpi-delta-D9XJoKuA.js.map} +1 -1
  72. package/dist/client/chunks/{chart-kpi-number-C-5m3qt5.js → chart-kpi-number-C29Vj2g8.js} +2 -2
  73. package/dist/client/chunks/{chart-kpi-number-C-5m3qt5.js.map → chart-kpi-number-C29Vj2g8.js.map} +1 -1
  74. package/dist/client/chunks/{chart-kpi-text--t4ibPmx.js → chart-kpi-text-CgjjrurK.js} +2 -2
  75. package/dist/client/chunks/{chart-kpi-text--t4ibPmx.js.map → chart-kpi-text-CgjjrurK.js.map} +1 -1
  76. package/dist/client/chunks/{charts-loader-DcFWOUeV.js → charts-loader-HYQFVOo4.js} +13 -12
  77. package/dist/client/chunks/charts-loader-HYQFVOo4.js.map +1 -0
  78. package/dist/client/chunks/{components-Bdt1AmzS.js → components-O0hh7ooo.js} +5 -5
  79. package/dist/client/chunks/components-O0hh7ooo.js.map +1 -0
  80. package/dist/client/chunks/{icons-DRreo6m8.js → icons-DAeqv1iX.js} +7 -7
  81. package/dist/client/chunks/{icons-DRreo6m8.js.map → icons-DAeqv1iX.js.map} +1 -1
  82. package/dist/client/components/charts/BoxPlotChart.config.d.ts +11 -0
  83. package/dist/client/components/charts/BoxPlotChart.d.ts +4 -0
  84. package/dist/client/components/charts/index.d.ts +1 -0
  85. package/dist/client/components.js +1 -1
  86. package/dist/client/icons.js +1 -1
  87. package/dist/client/index.js +7 -7
  88. package/dist/client/index.js.map +1 -1
  89. package/dist/client/types.d.ts +1 -1
  90. package/dist/client/utils.js +3 -3
  91. package/dist/client-bundle-stats.html +4 -4
  92. package/dist/server/index.cjs +118 -102
  93. package/dist/server/index.js +6161 -4739
  94. package/package.json +6 -6
  95. package/dist/adapters/handler-D6l8AbJV.cjs +0 -7
  96. package/dist/adapters/handler-DsNgnIPK.js +0 -458
  97. package/dist/client/chunks/RetentionCombinedChart.config-C-ILIaEb.js.map +0 -1
  98. package/dist/client/chunks/RetentionHeatmap.config-CIvhc-GT.js.map +0 -1
  99. package/dist/client/chunks/analysis-builder-Dn8xpgPQ.js.map +0 -1
  100. package/dist/client/chunks/chart-config-activity-grid-CAlo1cHA.js.map +0 -1
  101. package/dist/client/chunks/chart-config-area-CyyJOO2T.js.map +0 -1
  102. package/dist/client/chunks/chart-config-bar-soxw6m2o.js.map +0 -1
  103. package/dist/client/chunks/chart-config-bubble-CuSsCHZ4.js.map +0 -1
  104. package/dist/client/chunks/chart-config-data-table-BhgqwoqT.js.map +0 -1
  105. package/dist/client/chunks/chart-config-funnel-BlSQYng0.js.map +0 -1
  106. package/dist/client/chunks/chart-config-heat-map-DHQGFZhX.js.map +0 -1
  107. package/dist/client/chunks/chart-config-kpi-delta-yTA5ug_l.js.map +0 -1
  108. package/dist/client/chunks/chart-config-kpi-number-nVAwDXzq.js.map +0 -1
  109. package/dist/client/chunks/chart-config-kpi-text-DZjqsx-b.js.map +0 -1
  110. package/dist/client/chunks/chart-config-line-D5ME6w0v.js.map +0 -1
  111. package/dist/client/chunks/chart-config-markdown-BXKL5TbQ.js.map +0 -1
  112. package/dist/client/chunks/chart-config-pie-DlHa2jTy.js.map +0 -1
  113. package/dist/client/chunks/chart-config-radar-BBAVIF0S.js.map +0 -1
  114. package/dist/client/chunks/chart-config-radial-bar-CTwjDRnB.js.map +0 -1
  115. package/dist/client/chunks/chart-config-sankey-CNAgsMQ4.js.map +0 -1
  116. package/dist/client/chunks/chart-config-scatter-CWvN2E-X.js.map +0 -1
  117. package/dist/client/chunks/chart-config-sunburst-W_SKwaj0.js.map +0 -1
  118. package/dist/client/chunks/chart-config-tree-map-IRAYf9YM.js.map +0 -1
  119. package/dist/client/chunks/chartConfigRegistry-C5dZm-ZK.js +0 -44
  120. package/dist/client/chunks/chartConfigRegistry-C5dZm-ZK.js.map +0 -1
  121. package/dist/client/chunks/charts-loader-DcFWOUeV.js.map +0 -1
  122. package/dist/client/chunks/components-Bdt1AmzS.js.map +0 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "drizzle-cube",
3
- "version": "0.4.7",
3
+ "version": "0.4.8",
4
4
  "description": "Drizzle ORM-first semantic layer with Cube.js compatibility. Type-safe analytics and dashboards with SQL injection protection.",
5
5
  "main": "./dist/server/index.js",
6
6
  "types": "./dist/server/index.d.ts",
@@ -234,7 +234,7 @@
234
234
  "devDependencies": {
235
235
  "@anthropic-ai/sdk": "^0.78.0",
236
236
  "@eslint/eslintrc": "^3.3.1",
237
- "@eslint/js": "^9.34.0",
237
+ "@eslint/js": "^10.0.0",
238
238
  "@fastify/cors": "^11.1.0",
239
239
  "@hono/node-server": "^1.19.0",
240
240
  "@iconify-icons/heroicons-outline": "^1.2.5",
@@ -256,7 +256,7 @@
256
256
  "@types/node": "^24.0.0",
257
257
  "@types/react": "^18.0.0",
258
258
  "@types/react-dom": "^18.0.0",
259
- "@types/supertest": "^6.0.2",
259
+ "@types/supertest": "^7.0.0",
260
260
  "@typescript-eslint/eslint-plugin": "^8.0.0",
261
261
  "@typescript-eslint/parser": "^8.0.0",
262
262
  "@vitejs/plugin-react": "^5.0.0",
@@ -269,14 +269,14 @@
269
269
  "dotenv": "^17.2.3",
270
270
  "drizzle-kit": "^0.31.8",
271
271
  "drizzle-orm": "^0.45.0",
272
- "eslint": "^9.34.0",
272
+ "eslint": "^10.0.0",
273
273
  "eslint-plugin-react-hooks": "^7.0.1",
274
274
  "express": "^5.1.0",
275
275
  "fastify": "^5.6.2",
276
276
  "globals": "^17.0.0",
277
277
  "hono": "^4.0.0",
278
278
  "html2canvas": "^1.4.1",
279
- "jsdom": "^26.0.0",
279
+ "jsdom": "^28.0.0",
280
280
  "modern-screenshot": "^4.6.7",
281
281
  "msw": "^2.12.7",
282
282
  "mysql2": "^3.14.3",
@@ -289,7 +289,7 @@
289
289
  "react-hook-form": "^7.68.0",
290
290
  "react-resizable": "^3.0.5",
291
291
  "recharts": "^3.5.1",
292
- "rollup-plugin-visualizer": "^6.0.3",
292
+ "rollup-plugin-visualizer": "^7.0.0",
293
293
  "sql-formatter": "^15.6.6",
294
294
  "supertest": "^7.0.0",
295
295
  "tailwindcss": "^4.1.12",
@@ -1,7 +0,0 @@
1
- "use strict";var j=Object.create;var T=Object.defineProperty;var O=Object.getOwnPropertyDescriptor;var z=Object.getOwnPropertyNames;var D=Object.getPrototypeOf,U=Object.prototype.hasOwnProperty;var P=(a,t,n,s)=>{if(t&&typeof t=="object"||typeof t=="function")for(let e of z(t))!U.call(a,e)&&e!==n&&T(a,e,{get:()=>t[e],enumerable:!(s=O(t,e))||s.enumerable});return a};var L=(a,t,n)=>(n=a!=null?j(D(a)):{},P(t||!a||!a.__esModule?T(n,"default",{value:a,enumerable:!0}):n,a));Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const f=require("./mcp-transport-BB998cy5.cjs"),q=require("./utils.cjs");function Y(a){if(a.length===0)return"No cubes are currently available.";const t=["## Available Cubes",""];for(const n of a){if(t.push(`### ${n.name}`),n.description&&t.push(n.description),n.measures&&n.measures.length>0){t.push(""),t.push("**Measures:**");for(const s of n.measures){const e=s.description?` - ${s.description}`:"";t.push(`- \`${n.name}.${s.name}\` (${s.type})${e}`)}}if(n.dimensions&&n.dimensions.length>0){t.push(""),t.push("**Dimensions:**");for(const s of n.dimensions){const e=s.description?` - ${s.description}`:"";t.push(`- \`${n.name}.${s.name}\` (${s.type})${e}`)}}if(n.relationships&&n.relationships.length>0){t.push(""),t.push("**Joins:**");for(const s of n.relationships)t.push(`- → \`${s.targetCube}\` (${s.relationship})`)}t.push("")}return t.join(`
2
- `)}function b(a){return a.messages.map(t=>t.content.text).join(`
3
-
4
- `)}function F(a){return["# Drizzle Cube Analytics Agent","","You are an analytics agent that helps users explore and visualize data.","You have access to a semantic layer with cubes (data models) that you can query.","","## Your Workflow","","1. **Discover** available cubes using `discover_cubes` to understand the data","2. **Explain your approach** by calling `add_markdown` to describe what you plan to analyze and why","3. **Query** data using `execute_query` with properly structured queries","4. **Explain results** by calling `add_markdown` to describe what the data shows, key insights, and methodology","5. **Visualize** results by calling `add_portlet` to add charts/tables to the notebook","","## Important Guidelines","","- ALWAYS discover cubes first before attempting queries","- Use `add_portlet` to create visualizations after getting query results","- Use `add_markdown` to explain your findings, methodology, and insights","- Choose appropriate chart types: bar for categories, line for trends, table for detailed data","- When showing data, always add both a portlet (visualization) and markdown (explanation)","- If a query fails, explain the error and try an alternative approach","","## Output Format Rules","","### CRITICAL: Always think before acting","- EVERY single turn MUST begin with a text message (1-2 sentences) BEFORE any tool calls. This is your #1 rule — never violate it.","- This applies to EVERY turn, including turns where you are adding visualizations or explanations to the notebook.",`- Even when adding multiple portlets/markdowns in sequence, each turn must start with text like "Now I'll add the productivity chart." or "Next, let me visualize the department breakdown."`,'- Example good turn: "Let me discover what data is available." → discover_cubes',`- Example good turn: "I'll add a bar chart showing the top employees." → add_markdown → add_portlet`,"- Example bad turn: (no text) → add_portlet ← NEVER do this","","### Text vs Notebook","- ALL analysis, findings, methodology, and insights MUST go through `add_markdown` tool calls — never in your text responses","- Your text responses must be 1-2 short sentences (under 50 words) summarizing what you are about to do next — status updates only","- Never use markdown formatting (headers, bullets, bold, code blocks) in text responses — plain sentences only","","### Notebook content rules","- Before each `add_portlet`, ALWAYS call `add_markdown` first to explain WHY you are adding this visualization and what it shows","- Before calling `add_portlet`, verify the query is valid: all fields in `order` must also appear in `measures` or `dimensions`",'- Never put data tables in markdown blocks — use `add_portlet` with chartType "table" instead',"- Think out loud in the notebook: use `add_markdown` to share your reasoning at each step so users can follow along","","---","",b(f.MCP_GUIDE_PROMPT),"","---","",b(f.QUERY_RULES_PROMPT),"","---","",b(f.QUERY_BUILDING_PROMPT),"","---","",b(f.DATE_FILTERING_PROMPT),"","---","",Y(a)].join(`
5
- `)}function J(){return[{name:"discover_cubes",description:"Search for available data cubes by topic or intent. Call this FIRST to understand what data is available. Returns cube names, measures, dimensions, and relationships.",input_schema:{type:"object",properties:{topic:{type:"string",description:'Keyword to search (e.g., "sales", "employees")'},intent:{type:"string",description:'Natural language goal (e.g., "analyze productivity trends")'},limit:{type:"number",description:"Max results (default: 10)"},minScore:{type:"number",description:"Min relevance 0-1 (default: 0.1)"}}}},{name:"get_cube_metadata",description:"Get full metadata for all registered cubes including all measures, dimensions, types, and relationships. Use this for detailed schema information.",input_schema:{type:"object",properties:{}}},{name:"execute_query",description:"Execute a semantic query and return data results. The query follows the Cube.js query format with measures, dimensions, filters, timeDimensions, order, and limit.",input_schema:{type:"object",properties:{measures:{type:"array",items:{type:"string"},description:'Aggregation measures (e.g., ["Employees.count"])'},dimensions:{type:"array",items:{type:"string"},description:'Grouping dimensions (e.g., ["Employees.name"])'},filters:{type:"array",items:{type:"object",properties:{member:{type:"string"},operator:{type:"string"},values:{type:"array",items:{}}},required:["member","operator"]},description:"Filter conditions"},timeDimensions:{type:"array",items:{type:"object",properties:{dimension:{type:"string"},granularity:{type:"string"},dateRange:{}},required:["dimension"]},description:"Time dimensions with optional granularity"},order:{type:"object",description:'Sort order (e.g., {"Employees.count": "desc"})'},limit:{type:"number",description:"Row limit"}}}},{name:"add_portlet",description:"Add a chart or table visualization to the notebook. The query is validated before adding — if invalid, an error is returned so you can fix the query. The portlet fetches its own data - you do NOT need to pass data to it.",input_schema:{type:"object",properties:{title:{type:"string",description:"Title for the visualization"},query:{type:"string",description:"JSON string of the CubeQuery to visualize"},chartType:{type:"string",enum:["bar","line","area","pie","scatter","radar","bubble","table","number","funnel","heatmap","sankey","retention"],description:"Chart type to render"},chartConfig:{type:"object",properties:{xAxis:{type:"array",items:{type:"string"}},yAxis:{type:"array",items:{type:"string"}},series:{type:"array",items:{type:"string"}},sizeField:{type:"string"},colorField:{type:"string"}},description:"Chart axis configuration"},displayConfig:{type:"object",properties:{showLegend:{type:"boolean"},showGrid:{type:"boolean"},showTooltip:{type:"boolean"},stacked:{type:"boolean"},orientation:{type:"string",enum:["horizontal","vertical"]}},description:"Chart display configuration"}},required:["title","query","chartType"]}},{name:"add_markdown",description:"Add an explanation or analysis text block to the notebook. Use markdown formatting. Use this to explain findings, methodology, and insights alongside visualizations.",input_schema:{type:"object",properties:{title:{type:"string",description:"Optional title for the text block"},content:{type:"string",description:"Markdown content to display"}},required:["content"]}}]}function B(a){const{semanticLayer:t,securityContext:n}=a,s=new Map;return s.set("discover_cubes",async e=>{const r=await q.handleDiscover(t,{topic:e.topic,intent:e.intent,limit:e.limit,minScore:e.minScore});return{result:JSON.stringify(r,null,2)}}),s.set("get_cube_metadata",async()=>{const e=t.getMetadata();return{result:JSON.stringify(e,null,2)}}),s.set("execute_query",async e=>{try{const r={measures:e.measures,dimensions:e.dimensions,filters:e.filters,timeDimensions:e.timeDimensions,order:e.order,limit:e.limit},i=await q.handleLoad(t,n,{query:r});return{result:JSON.stringify({rowCount:i.data.length,data:i.data,annotation:i.annotation},null,2)}}catch(r){return{result:`Query execution failed: ${r instanceof Error?r.message:"Unknown error"}`,isError:!0}}}),s.set("add_portlet",async e=>{let r;try{r=JSON.parse(e.query)}catch{return{result:"Invalid query: could not parse JSON string. Ensure `query` is a valid JSON string.",isError:!0}}const i=t.validateQuery(r);if(!i.isValid)return{result:`Invalid query — fix these errors and retry:
6
- ${i.errors.join(`
7
- `)}`,isError:!0};const y=`portlet-${Date.now()}-${Math.random().toString(36).slice(2,7)}`,_={id:y,title:e.title,query:e.query,chartType:e.chartType,chartConfig:e.chartConfig,displayConfig:e.displayConfig};return{result:`Portlet "${e.title}" added to notebook (id: ${y}, chart: ${e.chartType}). [Reminder: in your next response, start with a brief sentence about what you will do next BEFORE making any tool calls.]`,sideEffect:{type:"add_portlet",data:_}}}),s.set("add_markdown",async e=>{const r=`markdown-${Date.now()}-${Math.random().toString(36).slice(2,7)}`,i={id:r,title:e.title,content:e.content};return{result:`Markdown block added to notebook (id: ${r}). [Reminder: in your next response, start with a brief sentence about what you will do next BEFORE making any tool calls.]`,sideEffect:{type:"add_markdown",data:i}}}),s}async function*G(a){const{message:t,sessionId:n,semanticLayer:s,securityContext:e,agentConfig:r,apiKey:i}=a;let y;try{const l=await import("@anthropic-ai/sdk");y=l.default||l.Anthropic||l}catch{yield{type:"error",data:{message:"@anthropic-ai/sdk is required. Install it with: npm install @anthropic-ai/sdk"}};return}const _=new y({apiKey:i}),C=J(),R=B({semanticLayer:s,securityContext:e}),S=s.getMetadata(),$=F(S),A=r.model||"claude-sonnet-4-6",I=r.maxTurns||25,N=r.maxTokens||4096,w=[{role:"user",content:t}];try{for(let l=0;l<I;l++){const M=await _.messages.create({model:A,max_tokens:N,system:$,tools:C,messages:w,stream:!0}),u=[];let x=-1,m="",k="";for await(const d of M)switch(d.type){case"content_block_start":{x++;const o=d.content_block;o.type==="tool_use"?(u.push({type:"tool_use",id:o.id,name:o.name,input:{}}),m="",yield{type:"tool_use_start",data:{id:o.id,name:o.name,input:void 0}}):o.type==="text"&&u.push({type:"text",text:""});break}case"content_block_delta":{const o=d.delta;if(o.type==="text_delta"&&o.text){const h=u[x];h&&(h.text=(h.text||"")+o.text),yield{type:"text_delta",data:o.text}}else o.type==="input_json_delta"&&o.partial_json&&(m+=o.partial_json);break}case"content_block_stop":{const o=u[x];if(o?.type==="tool_use"&&m){try{o.input=JSON.parse(m)}catch{o.input={}}m=""}break}case"message_delta":{const o=d.delta;o.stop_reason&&(k=o.stop_reason);break}}if(w.push({role:"assistant",content:u}),k!=="tool_use")break;const g=[];for(const d of u){if(d.type!=="tool_use")continue;const o=d.name,h=d.input||{},p=d.id,v=R.get(o);if(!v){g.push({type:"tool_result",tool_use_id:p,content:`Unknown tool: ${o}`,is_error:!0}),yield{type:"tool_use_result",data:{id:p,name:o,result:`Unknown tool: ${o}`}};continue}try{const c=await v(h);c.sideEffect&&(yield c.sideEffect),g.push({type:"tool_result",tool_use_id:p,content:c.result,...c.isError?{is_error:!0}:{}}),yield{type:"tool_use_result",data:{id:p,name:o,result:c.result}}}catch(c){const E=c instanceof Error?c.message:"Tool execution failed";g.push({type:"tool_result",tool_use_id:p,content:E,is_error:!0}),yield{type:"tool_use_result",data:{id:p,name:o,result:E}}}}yield{type:"turn_complete",data:{}},w.push({role:"user",content:g})}yield{type:"done",data:{sessionId:n||""}}}catch(l){yield{type:"error",data:{message:l instanceof Error?l.message:"Agent execution failed"}}}}exports.handleAgentChat=G;
@@ -1,458 +0,0 @@
1
- import { h as I, Q as N, j, D as M } from "./mcp-transport-DFTCWene.js";
2
- import { handleDiscover as z, handleLoad as D } from "./utils.js";
3
- function O(r) {
4
- if (r.length === 0)
5
- return "No cubes are currently available.";
6
- const o = ["## Available Cubes", ""];
7
- for (const a of r) {
8
- if (o.push(`### ${a.name}`), a.description && o.push(a.description), a.measures && a.measures.length > 0) {
9
- o.push(""), o.push("**Measures:**");
10
- for (const s of a.measures) {
11
- const e = s.description ? ` - ${s.description}` : "";
12
- o.push(`- \`${a.name}.${s.name}\` (${s.type})${e}`);
13
- }
14
- }
15
- if (a.dimensions && a.dimensions.length > 0) {
16
- o.push(""), o.push("**Dimensions:**");
17
- for (const s of a.dimensions) {
18
- const e = s.description ? ` - ${s.description}` : "";
19
- o.push(`- \`${a.name}.${s.name}\` (${s.type})${e}`);
20
- }
21
- }
22
- if (a.relationships && a.relationships.length > 0) {
23
- o.push(""), o.push("**Joins:**");
24
- for (const s of a.relationships)
25
- o.push(`- → \`${s.targetCube}\` (${s.relationship})`);
26
- }
27
- o.push("");
28
- }
29
- return o.join(`
30
- `);
31
- }
32
- function f(r) {
33
- return r.messages.map((o) => o.content.text).join(`
34
-
35
- `);
36
- }
37
- function U(r) {
38
- return [
39
- "# Drizzle Cube Analytics Agent",
40
- "",
41
- "You are an analytics agent that helps users explore and visualize data.",
42
- "You have access to a semantic layer with cubes (data models) that you can query.",
43
- "",
44
- "## Your Workflow",
45
- "",
46
- "1. **Discover** available cubes using `discover_cubes` to understand the data",
47
- "2. **Explain your approach** by calling `add_markdown` to describe what you plan to analyze and why",
48
- "3. **Query** data using `execute_query` with properly structured queries",
49
- "4. **Explain results** by calling `add_markdown` to describe what the data shows, key insights, and methodology",
50
- "5. **Visualize** results by calling `add_portlet` to add charts/tables to the notebook",
51
- "",
52
- "## Important Guidelines",
53
- "",
54
- "- ALWAYS discover cubes first before attempting queries",
55
- "- Use `add_portlet` to create visualizations after getting query results",
56
- "- Use `add_markdown` to explain your findings, methodology, and insights",
57
- "- Choose appropriate chart types: bar for categories, line for trends, table for detailed data",
58
- "- When showing data, always add both a portlet (visualization) and markdown (explanation)",
59
- "- If a query fails, explain the error and try an alternative approach",
60
- "",
61
- "## Output Format Rules",
62
- "",
63
- "### CRITICAL: Always think before acting",
64
- "- EVERY single turn MUST begin with a text message (1-2 sentences) BEFORE any tool calls. This is your #1 rule — never violate it.",
65
- "- This applies to EVERY turn, including turns where you are adding visualizations or explanations to the notebook.",
66
- `- Even when adding multiple portlets/markdowns in sequence, each turn must start with text like "Now I'll add the productivity chart." or "Next, let me visualize the department breakdown."`,
67
- '- Example good turn: "Let me discover what data is available." → discover_cubes',
68
- `- Example good turn: "I'll add a bar chart showing the top employees." → add_markdown → add_portlet`,
69
- "- Example bad turn: (no text) → add_portlet ← NEVER do this",
70
- "",
71
- "### Text vs Notebook",
72
- "- ALL analysis, findings, methodology, and insights MUST go through `add_markdown` tool calls — never in your text responses",
73
- "- Your text responses must be 1-2 short sentences (under 50 words) summarizing what you are about to do next — status updates only",
74
- "- Never use markdown formatting (headers, bullets, bold, code blocks) in text responses — plain sentences only",
75
- "",
76
- "### Notebook content rules",
77
- "- Before each `add_portlet`, ALWAYS call `add_markdown` first to explain WHY you are adding this visualization and what it shows",
78
- "- Before calling `add_portlet`, verify the query is valid: all fields in `order` must also appear in `measures` or `dimensions`",
79
- '- Never put data tables in markdown blocks — use `add_portlet` with chartType "table" instead',
80
- "- Think out loud in the notebook: use `add_markdown` to share your reasoning at each step so users can follow along",
81
- "",
82
- "---",
83
- "",
84
- f(I),
85
- "",
86
- "---",
87
- "",
88
- f(N),
89
- "",
90
- "---",
91
- "",
92
- f(j),
93
- "",
94
- "---",
95
- "",
96
- f(M),
97
- "",
98
- "---",
99
- "",
100
- O(r)
101
- ].join(`
102
- `);
103
- }
104
- function L() {
105
- return [
106
- // Tool 1: discover_cubes
107
- {
108
- name: "discover_cubes",
109
- description: "Search for available data cubes by topic or intent. Call this FIRST to understand what data is available. Returns cube names, measures, dimensions, and relationships.",
110
- input_schema: {
111
- type: "object",
112
- properties: {
113
- topic: { type: "string", description: 'Keyword to search (e.g., "sales", "employees")' },
114
- intent: { type: "string", description: 'Natural language goal (e.g., "analyze productivity trends")' },
115
- limit: { type: "number", description: "Max results (default: 10)" },
116
- minScore: { type: "number", description: "Min relevance 0-1 (default: 0.1)" }
117
- }
118
- }
119
- },
120
- // Tool 2: get_cube_metadata
121
- {
122
- name: "get_cube_metadata",
123
- description: "Get full metadata for all registered cubes including all measures, dimensions, types, and relationships. Use this for detailed schema information.",
124
- input_schema: {
125
- type: "object",
126
- properties: {}
127
- }
128
- },
129
- // Tool 3: execute_query
130
- {
131
- name: "execute_query",
132
- description: "Execute a semantic query and return data results. The query follows the Cube.js query format with measures, dimensions, filters, timeDimensions, order, and limit.",
133
- input_schema: {
134
- type: "object",
135
- properties: {
136
- measures: {
137
- type: "array",
138
- items: { type: "string" },
139
- description: 'Aggregation measures (e.g., ["Employees.count"])'
140
- },
141
- dimensions: {
142
- type: "array",
143
- items: { type: "string" },
144
- description: 'Grouping dimensions (e.g., ["Employees.name"])'
145
- },
146
- filters: {
147
- type: "array",
148
- items: {
149
- type: "object",
150
- properties: {
151
- member: { type: "string" },
152
- operator: { type: "string" },
153
- values: { type: "array", items: {} }
154
- },
155
- required: ["member", "operator"]
156
- },
157
- description: "Filter conditions"
158
- },
159
- timeDimensions: {
160
- type: "array",
161
- items: {
162
- type: "object",
163
- properties: {
164
- dimension: { type: "string" },
165
- granularity: { type: "string" },
166
- dateRange: {}
167
- },
168
- required: ["dimension"]
169
- },
170
- description: "Time dimensions with optional granularity"
171
- },
172
- order: {
173
- type: "object",
174
- description: 'Sort order (e.g., {"Employees.count": "desc"})'
175
- },
176
- limit: {
177
- type: "number",
178
- description: "Row limit"
179
- }
180
- }
181
- }
182
- },
183
- // Tool 4: add_portlet
184
- {
185
- name: "add_portlet",
186
- description: "Add a chart or table visualization to the notebook. The query is validated before adding — if invalid, an error is returned so you can fix the query. The portlet fetches its own data - you do NOT need to pass data to it.",
187
- input_schema: {
188
- type: "object",
189
- properties: {
190
- title: { type: "string", description: "Title for the visualization" },
191
- query: { type: "string", description: "JSON string of the CubeQuery to visualize" },
192
- chartType: {
193
- type: "string",
194
- enum: [
195
- "bar",
196
- "line",
197
- "area",
198
- "pie",
199
- "scatter",
200
- "radar",
201
- "bubble",
202
- "table",
203
- "number",
204
- "funnel",
205
- "heatmap",
206
- "sankey",
207
- "retention"
208
- ],
209
- description: "Chart type to render"
210
- },
211
- chartConfig: {
212
- type: "object",
213
- properties: {
214
- xAxis: { type: "array", items: { type: "string" } },
215
- yAxis: { type: "array", items: { type: "string" } },
216
- series: { type: "array", items: { type: "string" } },
217
- sizeField: { type: "string" },
218
- colorField: { type: "string" }
219
- },
220
- description: "Chart axis configuration"
221
- },
222
- displayConfig: {
223
- type: "object",
224
- properties: {
225
- showLegend: { type: "boolean" },
226
- showGrid: { type: "boolean" },
227
- showTooltip: { type: "boolean" },
228
- stacked: { type: "boolean" },
229
- orientation: { type: "string", enum: ["horizontal", "vertical"] }
230
- },
231
- description: "Chart display configuration"
232
- }
233
- },
234
- required: ["title", "query", "chartType"]
235
- }
236
- },
237
- // Tool 5: add_markdown
238
- {
239
- name: "add_markdown",
240
- description: "Add an explanation or analysis text block to the notebook. Use markdown formatting. Use this to explain findings, methodology, and insights alongside visualizations.",
241
- input_schema: {
242
- type: "object",
243
- properties: {
244
- title: { type: "string", description: "Optional title for the text block" },
245
- content: { type: "string", description: "Markdown content to display" }
246
- },
247
- required: ["content"]
248
- }
249
- }
250
- ];
251
- }
252
- function P(r) {
253
- const { semanticLayer: o, securityContext: a } = r, s = /* @__PURE__ */ new Map();
254
- return s.set("discover_cubes", async (e) => {
255
- const n = await z(o, {
256
- topic: e.topic,
257
- intent: e.intent,
258
- limit: e.limit,
259
- minScore: e.minScore
260
- });
261
- return { result: JSON.stringify(n, null, 2) };
262
- }), s.set("get_cube_metadata", async () => {
263
- const e = o.getMetadata();
264
- return { result: JSON.stringify(e, null, 2) };
265
- }), s.set("execute_query", async (e) => {
266
- try {
267
- const n = {
268
- measures: e.measures,
269
- dimensions: e.dimensions,
270
- filters: e.filters,
271
- timeDimensions: e.timeDimensions,
272
- order: e.order,
273
- limit: e.limit
274
- }, i = await D(o, a, { query: n });
275
- return {
276
- result: JSON.stringify({
277
- rowCount: i.data.length,
278
- data: i.data,
279
- annotation: i.annotation
280
- }, null, 2)
281
- };
282
- } catch (n) {
283
- return {
284
- result: `Query execution failed: ${n instanceof Error ? n.message : "Unknown error"}`,
285
- isError: !0
286
- };
287
- }
288
- }), s.set("add_portlet", async (e) => {
289
- let n;
290
- try {
291
- n = JSON.parse(e.query);
292
- } catch {
293
- return {
294
- result: "Invalid query: could not parse JSON string. Ensure `query` is a valid JSON string.",
295
- isError: !0
296
- };
297
- }
298
- const i = o.validateQuery(n);
299
- if (!i.isValid)
300
- return {
301
- result: `Invalid query — fix these errors and retry:
302
- ${i.errors.join(`
303
- `)}`,
304
- isError: !0
305
- };
306
- const y = `portlet-${Date.now()}-${Math.random().toString(36).slice(2, 7)}`, b = {
307
- id: y,
308
- title: e.title,
309
- query: e.query,
310
- chartType: e.chartType,
311
- chartConfig: e.chartConfig,
312
- displayConfig: e.displayConfig
313
- };
314
- return {
315
- result: `Portlet "${e.title}" added to notebook (id: ${y}, chart: ${e.chartType}). [Reminder: in your next response, start with a brief sentence about what you will do next BEFORE making any tool calls.]`,
316
- sideEffect: { type: "add_portlet", data: b }
317
- };
318
- }), s.set("add_markdown", async (e) => {
319
- const n = `markdown-${Date.now()}-${Math.random().toString(36).slice(2, 7)}`, i = {
320
- id: n,
321
- title: e.title,
322
- content: e.content
323
- };
324
- return {
325
- result: `Markdown block added to notebook (id: ${n}). [Reminder: in your next response, start with a brief sentence about what you will do next BEFORE making any tool calls.]`,
326
- sideEffect: { type: "add_markdown", data: i }
327
- };
328
- }), s;
329
- }
330
- async function* J(r) {
331
- const { message: o, sessionId: a, semanticLayer: s, securityContext: e, agentConfig: n, apiKey: i } = r;
332
- let y;
333
- try {
334
- const l = await import(
335
- /* webpackIgnore: true */
336
- "@anthropic-ai/sdk"
337
- );
338
- y = l.default || l.Anthropic || l;
339
- } catch {
340
- yield {
341
- type: "error",
342
- data: {
343
- message: "@anthropic-ai/sdk is required. Install it with: npm install @anthropic-ai/sdk"
344
- }
345
- };
346
- return;
347
- }
348
- const b = new y({ apiKey: i }), E = L(), T = P({ semanticLayer: s, securityContext: e }), q = s.getMetadata(), C = U(q), R = n.model || "claude-sonnet-4-6", $ = n.maxTurns || 25, S = n.maxTokens || 4096, _ = [
349
- { role: "user", content: o }
350
- ];
351
- try {
352
- for (let l = 0; l < $; l++) {
353
- const A = await b.messages.create({
354
- model: R,
355
- max_tokens: S,
356
- system: C,
357
- tools: E,
358
- messages: _,
359
- stream: !0
360
- }), u = [];
361
- let w = -1, m = "", x = "";
362
- for await (const d of A)
363
- switch (d.type) {
364
- case "content_block_start": {
365
- w++;
366
- const t = d.content_block;
367
- t.type === "tool_use" ? (u.push({ type: "tool_use", id: t.id, name: t.name, input: {} }), m = "", yield {
368
- type: "tool_use_start",
369
- data: { id: t.id, name: t.name, input: void 0 }
370
- }) : t.type === "text" && u.push({ type: "text", text: "" });
371
- break;
372
- }
373
- case "content_block_delta": {
374
- const t = d.delta;
375
- if (t.type === "text_delta" && t.text) {
376
- const h = u[w];
377
- h && (h.text = (h.text || "") + t.text), yield { type: "text_delta", data: t.text };
378
- } else t.type === "input_json_delta" && t.partial_json && (m += t.partial_json);
379
- break;
380
- }
381
- case "content_block_stop": {
382
- const t = u[w];
383
- if (t?.type === "tool_use" && m) {
384
- try {
385
- t.input = JSON.parse(m);
386
- } catch {
387
- t.input = {};
388
- }
389
- m = "";
390
- }
391
- break;
392
- }
393
- case "message_delta": {
394
- const t = d.delta;
395
- t.stop_reason && (x = t.stop_reason);
396
- break;
397
- }
398
- }
399
- if (_.push({ role: "assistant", content: u }), x !== "tool_use")
400
- break;
401
- const g = [];
402
- for (const d of u) {
403
- if (d.type !== "tool_use") continue;
404
- const t = d.name, h = d.input || {}, p = d.id, k = T.get(t);
405
- if (!k) {
406
- g.push({
407
- type: "tool_result",
408
- tool_use_id: p,
409
- content: `Unknown tool: ${t}`,
410
- is_error: !0
411
- }), yield {
412
- type: "tool_use_result",
413
- data: { id: p, name: t, result: `Unknown tool: ${t}` }
414
- };
415
- continue;
416
- }
417
- try {
418
- const c = await k(h);
419
- c.sideEffect && (yield c.sideEffect), g.push({
420
- type: "tool_result",
421
- tool_use_id: p,
422
- content: c.result,
423
- ...c.isError ? { is_error: !0 } : {}
424
- }), yield {
425
- type: "tool_use_result",
426
- data: { id: p, name: t, result: c.result }
427
- };
428
- } catch (c) {
429
- const v = c instanceof Error ? c.message : "Tool execution failed";
430
- g.push({
431
- type: "tool_result",
432
- tool_use_id: p,
433
- content: v,
434
- is_error: !0
435
- }), yield {
436
- type: "tool_use_result",
437
- data: { id: p, name: t, result: v }
438
- };
439
- }
440
- }
441
- yield { type: "turn_complete", data: {} }, _.push({ role: "user", content: g });
442
- }
443
- yield {
444
- type: "done",
445
- data: { sessionId: a || "" }
446
- };
447
- } catch (l) {
448
- yield {
449
- type: "error",
450
- data: {
451
- message: l instanceof Error ? l.message : "Agent execution failed"
452
- }
453
- };
454
- }
455
- }
456
- export {
457
- J as handleAgentChat
458
- };
@@ -1 +0,0 @@
1
- {"version":3,"file":"RetentionCombinedChart.config-C-ILIaEb.js","sources":["../../../src/client/components/charts/RetentionCombinedChart.config.ts"],"sourcesContent":["/**\n * RetentionCombinedChart Configuration\n *\n * The RetentionCombinedChart visualizes retention analysis data with multiple display modes.\n * It auto-configures from retention data and provides display mode selection.\n */\n\nimport type { ChartTypeConfig } from '../../charts/chartConfigs'\n\nexport const retentionCombinedConfig: ChartTypeConfig = {\n // RetentionCombinedChart auto-configures from the retention data structure\n // No drop zones needed as the chart maps directly to retention result data\n dropZones: [],\n\n // Display options\n displayOptionsConfig: [\n {\n key: 'retentionDisplayMode',\n label: 'Display Mode',\n type: 'select',\n defaultValue: 'line',\n options: [\n { value: 'line', label: 'Line Chart' },\n { value: 'heatmap', label: 'Heatmap Table' },\n { value: 'combined', label: 'Combined' },\n ],\n description: 'Choose how to visualize retention data',\n },\n {\n key: 'showLegend',\n label: 'Show Legend',\n type: 'boolean',\n defaultValue: true,\n description: 'Show the legend for breakdown segments',\n },\n {\n key: 'showGrid',\n label: 'Show Grid',\n type: 'boolean',\n defaultValue: true,\n description: 'Show grid lines on the chart',\n },\n {\n key: 'showTooltip',\n label: 'Show Tooltip',\n type: 'boolean',\n defaultValue: true,\n description: 'Show tooltip on hover with detailed stats',\n },\n ],\n\n description: 'Combined retention visualization with line chart and heatmap modes',\n useCase: 'Visualize user retention over time with optional breakdown segmentation',\n}\n"],"names":["retentionCombinedConfig"],"mappings":"AASO,MAAMA,IAA2C;AAAA;AAAA;AAAA,EAGtD,WAAW,CAAA;AAAA;AAAA,EAGX,sBAAsB;AAAA,IACpB;AAAA,MACE,KAAK;AAAA,MACL,OAAO;AAAA,MACP,MAAM;AAAA,MACN,cAAc;AAAA,MACd,SAAS;AAAA,QACP,EAAE,OAAO,QAAQ,OAAO,aAAA;AAAA,QACxB,EAAE,OAAO,WAAW,OAAO,gBAAA;AAAA,QAC3B,EAAE,OAAO,YAAY,OAAO,WAAA;AAAA,MAAW;AAAA,MAEzC,aAAa;AAAA,IAAA;AAAA,IAEf;AAAA,MACE,KAAK;AAAA,MACL,OAAO;AAAA,MACP,MAAM;AAAA,MACN,cAAc;AAAA,MACd,aAAa;AAAA,IAAA;AAAA,IAEf;AAAA,MACE,KAAK;AAAA,MACL,OAAO;AAAA,MACP,MAAM;AAAA,MACN,cAAc;AAAA,MACd,aAAa;AAAA,IAAA;AAAA,IAEf;AAAA,MACE,KAAK;AAAA,MACL,OAAO;AAAA,MACP,MAAM;AAAA,MACN,cAAc;AAAA,MACd,aAAa;AAAA,IAAA;AAAA,EACf;AAAA,EAGF,aAAa;AAAA,EACb,SAAS;AACX;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"RetentionHeatmap.config-CIvhc-GT.js","sources":["../../../src/client/components/charts/RetentionHeatmap.config.ts"],"sourcesContent":["/**\n * RetentionHeatmap Chart Configuration\n *\n * The RetentionHeatmap is a specialized chart for retention analysis.\n * It auto-configures from retention data and doesn't need typical axis configuration.\n */\n\nimport type { ChartTypeConfig } from '../../charts/chartConfigs'\n\nexport const retentionHeatmapConfig: ChartTypeConfig = {\n // RetentionHeatmap auto-configures from the retention data structure\n // No drop zones needed as the chart maps directly to cohort × period matrix\n dropZones: [],\n\n // Display options\n displayOptionsConfig: [\n {\n key: 'showLegend',\n label: 'Show Legend',\n type: 'boolean',\n defaultValue: true,\n description: 'Show the color intensity legend',\n },\n {\n key: 'showTooltip',\n label: 'Show Tooltip',\n type: 'boolean',\n defaultValue: true,\n description: 'Show tooltip on hover with detailed stats',\n },\n ],\n\n description: 'Cohort retention matrix visualization',\n useCase: 'Visualize user retention over time by cohort',\n}\n"],"names":["retentionHeatmapConfig"],"mappings":"AASO,MAAMA,IAA0C;AAAA;AAAA;AAAA,EAGrD,WAAW,CAAA;AAAA;AAAA,EAGX,sBAAsB;AAAA,IACpB;AAAA,MACE,KAAK;AAAA,MACL,OAAO;AAAA,MACP,MAAM;AAAA,MACN,cAAc;AAAA,MACd,aAAa;AAAA,IAAA;AAAA,IAEf;AAAA,MACE,KAAK;AAAA,MACL,OAAO;AAAA,MACP,MAAM;AAAA,MACN,cAAc;AAAA,MACd,aAAa;AAAA,IAAA;AAAA,EACf;AAAA,EAGF,aAAa;AAAA,EACb,SAAS;AACX;"}