drizzle-cube 0.4.29 → 0.4.30
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.
- package/dist/adapters/anthropic-BIva8k1r.cjs +1 -0
- package/dist/adapters/anthropic-B_rg0BhK.js +140 -0
- package/dist/adapters/dist-Boc63-1q.cjs +2 -0
- package/dist/adapters/dist-De5fzUEM.js +581 -0
- package/dist/adapters/express/index.cjs +2 -10
- package/dist/adapters/express/index.js +232 -342
- package/dist/adapters/fastify/index.cjs +2 -10
- package/dist/adapters/fastify/index.js +275 -424
- package/dist/adapters/google-CT4kgmBf.js +154 -0
- package/dist/adapters/google-Dgo9-Kb5.cjs +2 -0
- package/dist/adapters/handler-B8vuFQYP.cjs +25 -0
- package/dist/adapters/handler-D-2-6uLM.js +2951 -0
- package/dist/adapters/hono/index.cjs +2 -10
- package/dist/adapters/hono/index.js +307 -402
- package/dist/adapters/mcp-prompts-BAutSQYA.js +344 -0
- package/dist/adapters/mcp-prompts-DsAkafVn.cjs +5 -0
- package/dist/adapters/mcp-transport-CuugoG8t.js +7821 -0
- package/dist/adapters/mcp-transport-Dpp6hdZe.cjs +253 -0
- package/dist/adapters/nextjs/index.cjs +1 -9
- package/dist/adapters/nextjs/index.js +377 -600
- package/dist/adapters/openai-CjBvA6mK.js +4114 -0
- package/dist/adapters/openai-DhLE0A9Z.cjs +1 -0
- package/dist/adapters/openai-Zjw4Zo4R.js +153 -0
- package/dist/adapters/openai-eJBw3LfQ.cjs +16 -0
- package/dist/adapters/types.cjs +0 -1
- package/dist/adapters/types.js +0 -1
- package/dist/adapters/utils-ChhNGUOF.js +5396 -0
- package/dist/adapters/utils-CwJplXR5.cjs +15 -0
- package/dist/adapters/utils.cjs +1 -19
- package/dist/adapters/utils.js +2 -21333
- package/dist/client/charts.js +15 -186
- package/dist/client/chunks/DashboardEditModal-C076pscL.js +6678 -0
- package/dist/client/chunks/DashboardEditModal-C076pscL.js.map +1 -0
- package/dist/client/chunks/FieldSearchModal-C0DjSWk3.js +2631 -0
- package/dist/client/chunks/FieldSearchModal-C0DjSWk3.js.map +1 -0
- package/dist/client/chunks/RetentionCombinedChart-DuGXc-AP.js +270 -0
- package/dist/client/chunks/RetentionCombinedChart-DuGXc-AP.js.map +1 -0
- package/dist/client/chunks/RetentionCombinedChart.config-DprbXd1N.js +56 -0
- package/dist/client/chunks/RetentionCombinedChart.config-DprbXd1N.js.map +1 -0
- package/dist/client/chunks/RetentionHeatmap-BoGY6mlZ.js +193 -0
- package/dist/client/chunks/RetentionHeatmap-BoGY6mlZ.js.map +1 -0
- package/dist/client/chunks/RetentionHeatmap.config-cbaNExVy.js +25 -0
- package/dist/client/chunks/RetentionHeatmap.config-cbaNExVy.js.map +1 -0
- package/dist/client/chunks/analysis-builder-DF0XntqC.js +6111 -0
- package/dist/client/chunks/analysis-builder-DF0XntqC.js.map +1 -0
- package/dist/client/chunks/analysis-builder-shared-2QhKYbs6.js +3114 -0
- package/dist/client/chunks/analysis-builder-shared-2QhKYbs6.js.map +1 -0
- package/dist/client/chunks/chart-activity-grid-CNES9VBk.js +803 -0
- package/dist/client/chunks/chart-activity-grid-CNES9VBk.js.map +1 -0
- package/dist/client/chunks/chart-area-CRJc3KOu.js +449 -0
- package/dist/client/chunks/chart-area-CRJc3KOu.js.map +1 -0
- package/dist/client/chunks/chart-bar-DD2PjJ5n.js +270 -0
- package/dist/client/chunks/chart-bar-DD2PjJ5n.js.map +1 -0
- package/dist/client/chunks/chart-box-plot-BcqleldJ.js +377 -0
- package/dist/client/chunks/chart-box-plot-BcqleldJ.js.map +1 -0
- package/dist/client/chunks/chart-bubble-BmQkVk4K.js +273 -0
- package/dist/client/chunks/chart-bubble-BmQkVk4K.js.map +1 -0
- package/dist/client/chunks/chart-candlestick-C3Rep469.js +306 -0
- package/dist/client/chunks/chart-candlestick-C3Rep469.js.map +1 -0
- package/dist/client/chunks/chart-config-activity-grid-USo7JrPh.js +51 -0
- package/dist/client/chunks/chart-config-activity-grid-USo7JrPh.js.map +1 -0
- package/dist/client/chunks/chart-config-area-D_ZufYzg.js +93 -0
- package/dist/client/chunks/chart-config-area-D_ZufYzg.js.map +1 -0
- package/dist/client/chunks/chart-config-bar-BCi2Wmd6.js +87 -0
- package/dist/client/chunks/chart-config-bar-BCi2Wmd6.js.map +1 -0
- package/dist/client/chunks/chart-config-box-plot-afKLzJSp.js +35 -0
- package/dist/client/chunks/chart-config-box-plot-afKLzJSp.js.map +1 -0
- package/dist/client/chunks/chart-config-bubble-CgbBjPv8.js +82 -0
- package/dist/client/chunks/chart-config-bubble-CgbBjPv8.js.map +1 -0
- package/dist/client/chunks/chart-config-candlestick-7boGjZ-A.js +72 -0
- package/dist/client/chunks/chart-config-candlestick-7boGjZ-A.js.map +1 -0
- package/dist/client/chunks/chart-config-data-table-Cl7sBasW.js +30 -0
- package/dist/client/chunks/chart-config-data-table-Cl7sBasW.js.map +1 -0
- package/dist/client/chunks/chart-config-funnel-CXPYQtTl.js +93 -0
- package/dist/client/chunks/chart-config-funnel-CXPYQtTl.js.map +1 -0
- package/dist/client/chunks/chart-config-gauge-DUNEUCvh.js +64 -0
- package/dist/client/chunks/chart-config-gauge-DUNEUCvh.js.map +1 -0
- package/dist/client/chunks/chart-config-heat-map-BFf1tO11.js +91 -0
- package/dist/client/chunks/chart-config-heat-map-BFf1tO11.js.map +1 -0
- package/dist/client/chunks/chart-config-kpi-delta-C5k2waIJ.js +94 -0
- package/dist/client/chunks/chart-config-kpi-delta-C5k2waIJ.js.map +1 -0
- package/dist/client/chunks/chart-config-kpi-number-DptOyhk0.js +75 -0
- package/dist/client/chunks/chart-config-kpi-number-DptOyhk0.js.map +1 -0
- package/dist/client/chunks/chart-config-kpi-text-D9DdVWqd.js +47 -0
- package/dist/client/chunks/chart-config-kpi-text-D9DdVWqd.js.map +1 -0
- package/dist/client/chunks/chart-config-line-B3NgLF7K.js +104 -0
- package/dist/client/chunks/chart-config-line-B3NgLF7K.js.map +1 -0
- package/dist/client/chunks/chart-config-markdown-tlfivQTt.js +117 -0
- package/dist/client/chunks/chart-config-markdown-tlfivQTt.js.map +1 -0
- package/dist/client/chunks/chart-config-measure-profile-D7XDwrU2.js +82 -0
- package/dist/client/chunks/chart-config-measure-profile-D7XDwrU2.js.map +1 -0
- package/dist/client/chunks/chart-config-pie-wY0B52PC.js +68 -0
- package/dist/client/chunks/chart-config-pie-wY0B52PC.js.map +1 -0
- package/dist/client/chunks/chart-config-radar-DRpJBy1M.js +49 -0
- package/dist/client/chunks/chart-config-radar-DRpJBy1M.js.map +1 -0
- package/dist/client/chunks/chart-config-radial-bar-DCUpXv9G.js +38 -0
- package/dist/client/chunks/chart-config-radial-bar-DCUpXv9G.js.map +1 -0
- package/dist/client/chunks/chart-config-sankey-CdOhlm4h.js +66 -0
- package/dist/client/chunks/chart-config-sankey-CdOhlm4h.js.map +1 -0
- package/dist/client/chunks/chart-config-scatter-B2su_x8f.js +61 -0
- package/dist/client/chunks/chart-config-scatter-B2su_x8f.js.map +1 -0
- package/dist/client/chunks/chart-config-sunburst-BPdjbk18.js +45 -0
- package/dist/client/chunks/chart-config-sunburst-BPdjbk18.js.map +1 -0
- package/dist/client/chunks/chart-config-tree-map-Cbsh2fe2.js +51 -0
- package/dist/client/chunks/chart-config-tree-map-Cbsh2fe2.js.map +1 -0
- package/dist/client/chunks/chart-config-waterfall-DGmuZfQF.js +59 -0
- package/dist/client/chunks/chart-config-waterfall-DGmuZfQF.js.map +1 -0
- package/dist/client/chunks/chart-data-table-DehW1C1G.js +4088 -0
- package/dist/client/chunks/chart-data-table-DehW1C1G.js.map +1 -0
- package/dist/client/chunks/chart-funnel-BjkpnG5g.js +447 -0
- package/dist/client/chunks/chart-funnel-BjkpnG5g.js.map +1 -0
- package/dist/client/chunks/chart-gauge-BWW_HEfg.js +424 -0
- package/dist/client/chunks/chart-gauge-BWW_HEfg.js.map +1 -0
- package/dist/client/chunks/chart-heat-map-BWuOuDcm.js +236 -0
- package/dist/client/chunks/chart-heat-map-BWuOuDcm.js.map +1 -0
- package/dist/client/chunks/chart-kpi-delta-D5OHtDJx.js +343 -0
- package/dist/client/chunks/chart-kpi-delta-D5OHtDJx.js.map +1 -0
- package/dist/client/chunks/chart-kpi-number-C9zH-aKC.js +326 -0
- package/dist/client/chunks/chart-kpi-number-C9zH-aKC.js.map +1 -0
- package/dist/client/chunks/chart-kpi-text-ChVn3S7j.js +149 -0
- package/dist/client/chunks/chart-kpi-text-ChVn3S7j.js.map +1 -0
- package/dist/client/chunks/chart-line-DOIMkP0b.js +431 -0
- package/dist/client/chunks/chart-line-DOIMkP0b.js.map +1 -0
- package/dist/client/chunks/chart-markdown-DXxc43w1.js +3457 -0
- package/dist/client/chunks/chart-markdown-DXxc43w1.js.map +1 -0
- package/dist/client/chunks/chart-measure-profile-C6wrr9il.js +179 -0
- package/dist/client/chunks/chart-measure-profile-C6wrr9il.js.map +1 -0
- package/dist/client/chunks/chart-pie-BU_FgwDc.js +172 -0
- package/dist/client/chunks/chart-pie-BU_FgwDc.js.map +1 -0
- package/dist/client/chunks/chart-radar-DlufwnAX.js +154 -0
- package/dist/client/chunks/chart-radar-DlufwnAX.js.map +1 -0
- package/dist/client/chunks/chart-radial-bar-B5vS_Aw5.js +148 -0
- package/dist/client/chunks/chart-radial-bar-B5vS_Aw5.js.map +1 -0
- package/dist/client/chunks/chart-sankey-FChb26UX.js +222 -0
- package/dist/client/chunks/chart-sankey-FChb26UX.js.map +1 -0
- package/dist/client/chunks/chart-scatter-DW0cAZ2H.js +255 -0
- package/dist/client/chunks/chart-scatter-DW0cAZ2H.js.map +1 -0
- package/dist/client/chunks/chart-sunburst-Clf-6WxW.js +221 -0
- package/dist/client/chunks/chart-sunburst-Clf-6WxW.js.map +1 -0
- package/dist/client/chunks/chart-tree-map-p_VwUJPF.js +298 -0
- package/dist/client/chunks/chart-tree-map-p_VwUJPF.js.map +1 -0
- package/dist/client/chunks/chart-waterfall-jt44IQ-w.js +237 -0
- package/dist/client/chunks/chart-waterfall-jt44IQ-w.js.map +1 -0
- package/dist/client/chunks/charts-core-CUVzf4cV.js +215 -0
- package/dist/client/chunks/charts-core-CUVzf4cV.js.map +1 -0
- package/dist/client/chunks/charts-loader-AGpph8_I.js +259 -0
- package/dist/client/chunks/charts-loader-AGpph8_I.js.map +1 -0
- package/dist/client/chunks/core-D1TOj17W.js +845 -0
- package/dist/client/chunks/core-D1TOj17W.js.map +1 -0
- package/dist/client/chunks/dist-DDBeV_JI.js +847 -0
- package/dist/client/chunks/dist-DDBeV_JI.js.map +1 -0
- package/dist/client/chunks/javascript-BBwTSo6e.js +438 -0
- package/dist/client/chunks/javascript-BBwTSo6e.js.map +1 -0
- package/dist/client/chunks/json-BpTrLZSh.js +38 -0
- package/dist/client/chunks/json-BpTrLZSh.js.map +1 -0
- package/dist/client/chunks/lazyChartConfigRegistry-BjhxDaSf.js +149 -0
- package/dist/client/chunks/lazyChartConfigRegistry-BjhxDaSf.js.map +1 -0
- package/dist/client/chunks/providers-DX3Vw5kc.js +7 -0
- package/dist/client/chunks/providers-DX3Vw5kc.js.map +1 -0
- package/dist/client/chunks/retention-UEXlSdZ-.js +132 -0
- package/dist/client/chunks/retention-UEXlSdZ-.js.map +1 -0
- package/dist/client/chunks/rolldown-runtime-lc2dmIiU.js +20 -0
- package/dist/client/chunks/schema-visualization-ZugB4Io9.js +1073 -0
- package/dist/client/chunks/schema-visualization-ZugB4Io9.js.map +1 -0
- package/dist/client/chunks/sql-B0chxcEK.js +120 -0
- package/dist/client/chunks/sql-B0chxcEK.js.map +1 -0
- package/dist/client/chunks/syntaxHighlighting-87bOwTxj.js +30 -0
- package/dist/client/chunks/syntaxHighlighting-87bOwTxj.js.map +1 -0
- package/dist/client/chunks/useDebounce-BQjNWndQ.js +1394 -0
- package/dist/client/chunks/useDebounce-BQjNWndQ.js.map +1 -0
- package/dist/client/chunks/useDirtyStateTracking-CgKZWkel.js +66 -0
- package/dist/client/chunks/useDirtyStateTracking-CgKZWkel.js.map +1 -0
- package/dist/client/chunks/useExplainAI-c_bHxZe5.js +203 -0
- package/dist/client/chunks/useExplainAI-c_bHxZe5.js.map +1 -0
- package/dist/client/chunks/useNotebookLayout-BFZ_33Kb.js +37 -0
- package/dist/client/chunks/useNotebookLayout-BFZ_33Kb.js.map +1 -0
- package/dist/client/chunks/utils-A54Ny29G.js +128 -0
- package/dist/client/chunks/utils-A54Ny29G.js.map +1 -0
- package/dist/client/chunks/vendor-CoPBRumI.js +828 -0
- package/dist/client/chunks/vendor-CoPBRumI.js.map +1 -0
- package/dist/client/components.js +4 -18
- package/dist/client/hooks.js +6 -58
- package/dist/client/icons.js +2 -15
- package/dist/client/index.js +1061 -1295
- package/dist/client/index.js.map +1 -1
- package/dist/client/providers.js +3 -9
- package/dist/client/styles.css +2 -1
- package/dist/client/types.d.ts +1 -0
- package/dist/client/utils.js +7 -74
- package/dist/client-bundle-stats.html +1 -1
- package/dist/server/anthropic-BsNspi1r.js +140 -0
- package/dist/server/anthropic-DsCEX6Fm.cjs +1 -0
- package/dist/server/dist-CMWZC51B.js +581 -0
- package/dist/server/dist-DxegvyZF.cjs +2 -0
- package/dist/server/google-BXwMolCu.js +154 -0
- package/dist/server/google-DzQWXFwF.cjs +2 -0
- package/dist/server/index.cjs +109 -129
- package/dist/server/index.js +15089 -34394
- package/dist/server/openai-BPhmb8mi.js +4114 -0
- package/dist/server/openai-CLsoLaue.cjs +1 -0
- package/dist/server/openai-D1kZ5sdM.js +153 -0
- package/dist/server/openai-DkOKbVLC.cjs +16 -0
- package/package.json +5 -5
- package/dist/adapters/anthropic-BTkjgFpT.cjs +0 -1
- package/dist/adapters/anthropic-CTu9E801.js +0 -126
- package/dist/adapters/google-BAK9pnQf.cjs +0 -2
- package/dist/adapters/google-DficVAsJ.js +0 -146
- package/dist/adapters/handler-BHguLZOY.js +0 -2713
- package/dist/adapters/handler-DOIyiFPg.cjs +0 -39
- package/dist/adapters/index-BgCeQBuN.cjs +0 -2
- package/dist/adapters/index-C3PskWTr.js +0 -5353
- package/dist/adapters/index-C45_meK_.js +0 -719
- package/dist/adapters/index-ht4NPca9.cjs +0 -23
- package/dist/adapters/mcp-transport-CWGqDQSI.cjs +0 -259
- package/dist/adapters/mcp-transport-CyeHMDPl.js +0 -11055
- package/dist/adapters/openai-BvA6eLs8.cjs +0 -1
- package/dist/adapters/openai-mcE24du8.js +0 -131
- package/dist/client/charts.js.map +0 -1
- package/dist/client/chunks/RetentionCombinedChart--SnU4Y_I.js +0 -256
- package/dist/client/chunks/RetentionCombinedChart--SnU4Y_I.js.map +0 -1
- package/dist/client/chunks/RetentionCombinedChart.config-Bbp2ghim.js +0 -48
- package/dist/client/chunks/RetentionCombinedChart.config-Bbp2ghim.js.map +0 -1
- package/dist/client/chunks/RetentionHeatmap-BHYU8MXY.js +0 -178
- package/dist/client/chunks/RetentionHeatmap-BHYU8MXY.js.map +0 -1
- package/dist/client/chunks/RetentionHeatmap.config-BWf_-vdj.js +0 -29
- package/dist/client/chunks/RetentionHeatmap.config-BWf_-vdj.js.map +0 -1
- package/dist/client/chunks/analysis-builder-DMFoAkjT.js +0 -6203
- package/dist/client/chunks/analysis-builder-DMFoAkjT.js.map +0 -1
- package/dist/client/chunks/analysis-builder-shared-CunrT3gi.js +0 -3140
- package/dist/client/chunks/analysis-builder-shared-CunrT3gi.js.map +0 -1
- package/dist/client/chunks/chart-activity-grid-DCznpK6N.js +0 -347
- package/dist/client/chunks/chart-activity-grid-DCznpK6N.js.map +0 -1
- package/dist/client/chunks/chart-area-CqKRIUpj.js +0 -234
- package/dist/client/chunks/chart-area-CqKRIUpj.js.map +0 -1
- package/dist/client/chunks/chart-bar-Bl5jvrU_.js +0 -267
- package/dist/client/chunks/chart-bar-Bl5jvrU_.js.map +0 -1
- package/dist/client/chunks/chart-box-plot-CzMb00z_.js +0 -322
- package/dist/client/chunks/chart-box-plot-CzMb00z_.js.map +0 -1
- package/dist/client/chunks/chart-bubble-BF8Z52eW.js +0 -249
- package/dist/client/chunks/chart-bubble-BF8Z52eW.js.map +0 -1
- package/dist/client/chunks/chart-candlestick-ByWS945g.js +0 -269
- package/dist/client/chunks/chart-candlestick-ByWS945g.js.map +0 -1
- package/dist/client/chunks/chart-config-activity-grid-CmOqDuOT.js +0 -50
- package/dist/client/chunks/chart-config-activity-grid-CmOqDuOT.js.map +0 -1
- package/dist/client/chunks/chart-config-area-CK_GVApT.js +0 -77
- package/dist/client/chunks/chart-config-area-CK_GVApT.js.map +0 -1
- package/dist/client/chunks/chart-config-bar-C8uzktxl.js +0 -71
- package/dist/client/chunks/chart-config-bar-C8uzktxl.js.map +0 -1
- package/dist/client/chunks/chart-config-box-plot-D_E_SSc2.js +0 -38
- package/dist/client/chunks/chart-config-box-plot-D_E_SSc2.js.map +0 -1
- package/dist/client/chunks/chart-config-bubble-q3DoQX5F.js +0 -71
- package/dist/client/chunks/chart-config-bubble-q3DoQX5F.js.map +0 -1
- package/dist/client/chunks/chart-config-candlestick-CRCpD43-.js +0 -70
- package/dist/client/chunks/chart-config-candlestick-CRCpD43-.js.map +0 -1
- package/dist/client/chunks/chart-config-data-table-B20Y5JCm.js +0 -28
- package/dist/client/chunks/chart-config-data-table-B20Y5JCm.js.map +0 -1
- package/dist/client/chunks/chart-config-funnel-3eYnGg8M.js +0 -92
- package/dist/client/chunks/chart-config-funnel-3eYnGg8M.js.map +0 -1
- package/dist/client/chunks/chart-config-gauge-CQx9w3d4.js +0 -64
- package/dist/client/chunks/chart-config-gauge-CQx9w3d4.js.map +0 -1
- package/dist/client/chunks/chart-config-heat-map-_wEnTnRA.js +0 -77
- package/dist/client/chunks/chart-config-heat-map-_wEnTnRA.js.map +0 -1
- package/dist/client/chunks/chart-config-kpi-delta-DLGZ2A3X.js +0 -97
- package/dist/client/chunks/chart-config-kpi-delta-DLGZ2A3X.js.map +0 -1
- package/dist/client/chunks/chart-config-kpi-number-K-wzviXF.js +0 -75
- package/dist/client/chunks/chart-config-kpi-number-K-wzviXF.js.map +0 -1
- package/dist/client/chunks/chart-config-kpi-text-BjYqwqaJ.js +0 -47
- package/dist/client/chunks/chart-config-kpi-text-BjYqwqaJ.js.map +0 -1
- package/dist/client/chunks/chart-config-line-JNagi9tf.js +0 -88
- package/dist/client/chunks/chart-config-line-JNagi9tf.js.map +0 -1
- package/dist/client/chunks/chart-config-markdown-BWQSjJpy.js +0 -97
- package/dist/client/chunks/chart-config-markdown-BWQSjJpy.js.map +0 -1
- package/dist/client/chunks/chart-config-measure-profile-ZYaMrtws.js +0 -70
- package/dist/client/chunks/chart-config-measure-profile-ZYaMrtws.js.map +0 -1
- package/dist/client/chunks/chart-config-pie-CNLXb-fr.js +0 -39
- package/dist/client/chunks/chart-config-pie-CNLXb-fr.js.map +0 -1
- package/dist/client/chunks/chart-config-radar-oxHfRAa3.js +0 -44
- package/dist/client/chunks/chart-config-radar-oxHfRAa3.js.map +0 -1
- package/dist/client/chunks/chart-config-radial-bar-_Aw3jAEm.js +0 -37
- package/dist/client/chunks/chart-config-radial-bar-_Aw3jAEm.js.map +0 -1
- package/dist/client/chunks/chart-config-sankey-C8FX9hGF.js +0 -61
- package/dist/client/chunks/chart-config-sankey-C8FX9hGF.js.map +0 -1
- package/dist/client/chunks/chart-config-scatter-DFKM80eO.js +0 -53
- package/dist/client/chunks/chart-config-scatter-DFKM80eO.js.map +0 -1
- package/dist/client/chunks/chart-config-sunburst-BmC0NLTU.js +0 -50
- package/dist/client/chunks/chart-config-sunburst-BmC0NLTU.js.map +0 -1
- package/dist/client/chunks/chart-config-tree-map-DGMbNTaa.js +0 -47
- package/dist/client/chunks/chart-config-tree-map-DGMbNTaa.js.map +0 -1
- package/dist/client/chunks/chart-config-waterfall-DTyXV_fo.js +0 -60
- package/dist/client/chunks/chart-config-waterfall-DTyXV_fo.js.map +0 -1
- package/dist/client/chunks/chart-data-table-HwfF-Ujv.js +0 -293
- package/dist/client/chunks/chart-data-table-HwfF-Ujv.js.map +0 -1
- package/dist/client/chunks/chart-funnel-WmuoWlCq.js +0 -259
- package/dist/client/chunks/chart-funnel-WmuoWlCq.js.map +0 -1
- package/dist/client/chunks/chart-gauge-Cot4By-w.js +0 -374
- package/dist/client/chunks/chart-gauge-Cot4By-w.js.map +0 -1
- package/dist/client/chunks/chart-heat-map-bGNtsZMr.js +0 -231
- package/dist/client/chunks/chart-heat-map-bGNtsZMr.js.map +0 -1
- package/dist/client/chunks/chart-kpi-delta-DeyKMxgq.js +0 -351
- package/dist/client/chunks/chart-kpi-delta-DeyKMxgq.js.map +0 -1
- package/dist/client/chunks/chart-kpi-number-D1z1gxXO.js +0 -476
- package/dist/client/chunks/chart-kpi-number-D1z1gxXO.js.map +0 -1
- package/dist/client/chunks/chart-kpi-text-b7q6KWc0.js +0 -165
- package/dist/client/chunks/chart-kpi-text-b7q6KWc0.js.map +0 -1
- package/dist/client/chunks/chart-line-3Nf-EPqJ.js +0 -450
- package/dist/client/chunks/chart-line-3Nf-EPqJ.js.map +0 -1
- package/dist/client/chunks/chart-markdown-BT_-MBq1.js +0 -2721
- package/dist/client/chunks/chart-markdown-BT_-MBq1.js.map +0 -1
- package/dist/client/chunks/chart-measure-profile-BVjUonqU.js +0 -114
- package/dist/client/chunks/chart-measure-profile-BVjUonqU.js.map +0 -1
- package/dist/client/chunks/chart-pie-DblG6w7g.js +0 -137
- package/dist/client/chunks/chart-pie-DblG6w7g.js.map +0 -1
- package/dist/client/chunks/chart-radar-BHZbeeTg.js +0 -129
- package/dist/client/chunks/chart-radar-BHZbeeTg.js.map +0 -1
- package/dist/client/chunks/chart-radial-bar-AlEJC1Jo.js +0 -119
- package/dist/client/chunks/chart-radial-bar-AlEJC1Jo.js.map +0 -1
- package/dist/client/chunks/chart-sankey-E8vYKjQF.js +0 -189
- package/dist/client/chunks/chart-sankey-E8vYKjQF.js.map +0 -1
- package/dist/client/chunks/chart-scatter-Bbxqi0iw.js +0 -202
- package/dist/client/chunks/chart-scatter-Bbxqi0iw.js.map +0 -1
- package/dist/client/chunks/chart-sunburst-BgnTKolT.js +0 -188
- package/dist/client/chunks/chart-sunburst-BgnTKolT.js.map +0 -1
- package/dist/client/chunks/chart-tree-map-i9LGCLwl.js +0 -284
- package/dist/client/chunks/chart-tree-map-i9LGCLwl.js.map +0 -1
- package/dist/client/chunks/chart-waterfall-BeIhCm83.js +0 -191
- package/dist/client/chunks/chart-waterfall-BeIhCm83.js.map +0 -1
- package/dist/client/chunks/charts-core-BUUO36OM.js +0 -692
- package/dist/client/chunks/charts-core-BUUO36OM.js.map +0 -1
- package/dist/client/chunks/charts-loader-goTYnavu.js +0 -258
- package/dist/client/chunks/charts-loader-goTYnavu.js.map +0 -1
- package/dist/client/chunks/components-BFgYvFq6.js +0 -10066
- package/dist/client/chunks/components-BFgYvFq6.js.map +0 -1
- package/dist/client/chunks/core-Y9e-sNfb.js +0 -1068
- package/dist/client/chunks/core-Y9e-sNfb.js.map +0 -1
- package/dist/client/chunks/flow-utils-CjQZG5qq.js +0 -16
- package/dist/client/chunks/flow-utils-CjQZG5qq.js.map +0 -1
- package/dist/client/chunks/funnel-utils-CyonoNeC.js +0 -135
- package/dist/client/chunks/funnel-utils-CyonoNeC.js.map +0 -1
- package/dist/client/chunks/icons-CwvgmdIP.js +0 -1636
- package/dist/client/chunks/icons-CwvgmdIP.js.map +0 -1
- package/dist/client/chunks/index-CApFCBF9.js +0 -81
- package/dist/client/chunks/index-CApFCBF9.js.map +0 -1
- package/dist/client/chunks/index-_2PSgbkC.js +0 -1046
- package/dist/client/chunks/index-_2PSgbkC.js.map +0 -1
- package/dist/client/chunks/javascript-DII1YQGr.js +0 -659
- package/dist/client/chunks/javascript-DII1YQGr.js.map +0 -1
- package/dist/client/chunks/json-C_6Prymp.js +0 -39
- package/dist/client/chunks/json-C_6Prymp.js.map +0 -1
- package/dist/client/chunks/providers-Ds7DRmnO.js +0 -554
- package/dist/client/chunks/providers-Ds7DRmnO.js.map +0 -1
- package/dist/client/chunks/retention-CzCo8262.js +0 -120
- package/dist/client/chunks/retention-CzCo8262.js.map +0 -1
- package/dist/client/chunks/schema-visualization-B97a1Ybu.js +0 -772
- package/dist/client/chunks/schema-visualization-B97a1Ybu.js.map +0 -1
- package/dist/client/chunks/sql-IeKX8fQ8.js +0 -616
- package/dist/client/chunks/sql-IeKX8fQ8.js.map +0 -1
- package/dist/client/chunks/syntaxHighlighting-DAMSW_A6.js +0 -34
- package/dist/client/chunks/syntaxHighlighting-DAMSW_A6.js.map +0 -1
- package/dist/client/chunks/theme-Dp3hFed1.js +0 -112
- package/dist/client/chunks/theme-Dp3hFed1.js.map +0 -1
- package/dist/client/chunks/useDirtyStateTracking-CyAXd07d.js +0 -1231
- package/dist/client/chunks/useDirtyStateTracking-CyAXd07d.js.map +0 -1
- package/dist/client/chunks/useExplainAI-CfQ_JmF1.js +0 -182
- package/dist/client/chunks/useExplainAI-CfQ_JmF1.js.map +0 -1
- package/dist/client/chunks/vendor-B2EH3V58.js +0 -2892
- package/dist/client/chunks/vendor-B2EH3V58.js.map +0 -1
- package/dist/client/components.js.map +0 -1
- package/dist/client/hooks.js.map +0 -1
- package/dist/client/icons.js.map +0 -1
- package/dist/client/providers.js.map +0 -1
- package/dist/client/utils.js.map +0 -1
- package/dist/server/anthropic-BTkjgFpT.cjs +0 -1
- package/dist/server/anthropic-CTu9E801.js +0 -126
- package/dist/server/google-BAK9pnQf.cjs +0 -2
- package/dist/server/google-DficVAsJ.js +0 -146
- package/dist/server/index-BgCeQBuN.cjs +0 -2
- package/dist/server/index-C3PskWTr.js +0 -5353
- package/dist/server/index-C45_meK_.js +0 -719
- package/dist/server/index-ht4NPca9.cjs +0 -23
- package/dist/server/openai-BvA6eLs8.cjs +0 -1
- package/dist/server/openai-mcE24du8.js +0 -131
|
@@ -0,0 +1,344 @@
|
|
|
1
|
+
//#region src/server/ai/mcp-prompts.ts
|
|
2
|
+
var e = {
|
|
3
|
+
name: "drizzle-cube-mcp-guide",
|
|
4
|
+
description: "How to use drizzle-cube MCP tools to generate and run queries",
|
|
5
|
+
messages: [{
|
|
6
|
+
role: "user",
|
|
7
|
+
content: {
|
|
8
|
+
type: "text",
|
|
9
|
+
text: [
|
|
10
|
+
"You are an analyst agent using drizzle-cube MCP.",
|
|
11
|
+
"",
|
|
12
|
+
"Workflow:",
|
|
13
|
+
"1) tools/call name=discover {topic|intent} - Find cubes and understand schema",
|
|
14
|
+
"2) Construct your query using the schema from discover (see cross-cube joins below)",
|
|
15
|
+
"3) tools/call name=validate {query} - Optional: fix schema issues",
|
|
16
|
+
"4) tools/call name=load {query} - Execute and get results",
|
|
17
|
+
"",
|
|
18
|
+
"CRITICAL - CROSS-CUBE JOINS:",
|
|
19
|
+
"The \"joins\" property in discover results shows relationships between cubes.",
|
|
20
|
+
"You can include dimensions from ANY related cube in your query!",
|
|
21
|
+
"Example: If Productivity joins to Employees, query:",
|
|
22
|
+
"{ \"measures\": [\"Productivity.totalPullRequests\"], \"dimensions\": [\"Employees.name\"] }",
|
|
23
|
+
"The system automatically joins the cubes for you.",
|
|
24
|
+
"",
|
|
25
|
+
"Query shapes:",
|
|
26
|
+
"- Regular: { measures, dimensions, filters[], timeDimensions[], order, limit, offset }",
|
|
27
|
+
"- Funnel: { funnel: { bindingKey, timeDimension, steps[], includeTimeMetrics? } }",
|
|
28
|
+
"- Flow: { flow: { bindingKey, eventDimension, steps?, window? } }",
|
|
29
|
+
"- Retention: { retention: { bindingKey, timeDimension, periods, granularity, retentionType, breakdownDimensions } }",
|
|
30
|
+
"",
|
|
31
|
+
"Time handling:",
|
|
32
|
+
"- For AGGREGATED TOTALS (e.g., \"last 3 months\"): use filters with inDateRange, NOT timeDimensions",
|
|
33
|
+
"- For TIME SERIES (e.g., \"by month\"): use timeDimensions with granularity",
|
|
34
|
+
"- You can combine both when needed",
|
|
35
|
+
"",
|
|
36
|
+
"Filters: flat arrays of { member, operator, values }. Do not nest arrays.",
|
|
37
|
+
"Do NOT hallucinate cube/field names—always use discover first."
|
|
38
|
+
].join("\n")
|
|
39
|
+
}
|
|
40
|
+
}]
|
|
41
|
+
}, t = {
|
|
42
|
+
name: "drizzle-cube-query-rules",
|
|
43
|
+
description: "Key generation rules aligned with Gemini single-step prompt",
|
|
44
|
+
messages: [{
|
|
45
|
+
role: "user",
|
|
46
|
+
content: {
|
|
47
|
+
type: "text",
|
|
48
|
+
text: [
|
|
49
|
+
"Rules (keep JSON only):",
|
|
50
|
+
"- Use only measures/dimensions/timeDimensions from schema. Fields are always `CubeName.fieldName` — never use just the cube name (e.g. `PullRequests.count` not `PullRequests`).",
|
|
51
|
+
"- timeDimensions: include granularity when grouping; use inDateRange filter for relative windows; combine when both requested.",
|
|
52
|
+
"- Funnel detection keywords: funnel, conversion, journey, drop off, step by step; use funnel format only if eventStream metadata exists.",
|
|
53
|
+
"- Funnel rules: bindingKey/timeDimension from cube metadata; include time filter on step 0 (default last 6 months) using inDateRange; steps ordered; flat filters.",
|
|
54
|
+
"- Chart selection: line/area for time trends; bar for categories; scatter for 2-measure correlations; bubble for 3-measure correlations; funnel for funnels.",
|
|
55
|
+
"- Correlation keywords (correlation/relationship/vs/compare) -> scatter/bubble, never line.",
|
|
56
|
+
"- Prefer .name fields over .id; avoid Id dimensions unless requested.",
|
|
57
|
+
"- Filters: flat array of {member, operator, values}; operators equals, notEquals, contains, notContains, gt, gte, lt, lte, inDateRange, set, notSet."
|
|
58
|
+
].join("\n")
|
|
59
|
+
}
|
|
60
|
+
}]
|
|
61
|
+
}, n = {
|
|
62
|
+
name: "drizzle-cube-query-building",
|
|
63
|
+
description: "CRITICAL: Complete guide for building valid queries of all types with examples",
|
|
64
|
+
messages: [{
|
|
65
|
+
role: "user",
|
|
66
|
+
content: {
|
|
67
|
+
type: "text",
|
|
68
|
+
text: [
|
|
69
|
+
"# Drizzle Cube Query Building Guide",
|
|
70
|
+
"",
|
|
71
|
+
"## CRITICAL: Cross-Cube Joins",
|
|
72
|
+
"",
|
|
73
|
+
"You can combine measures from one cube with dimensions from RELATED cubes!",
|
|
74
|
+
"Check the \"joins\" property in discover results to see relationships.",
|
|
75
|
+
"",
|
|
76
|
+
"Example: \"Top 5 employees by pull requests last 3 months\"",
|
|
77
|
+
"- Productivity cube has: measures (totalPullRequests), dimensions (date)",
|
|
78
|
+
"- Productivity joins to Employees (via employeeId)",
|
|
79
|
+
"- Employees cube has: dimensions (name, department)",
|
|
80
|
+
"",
|
|
81
|
+
"Query combining BOTH cubes:",
|
|
82
|
+
"```json",
|
|
83
|
+
"{",
|
|
84
|
+
" \"measures\": [\"Productivity.totalPullRequests\"],",
|
|
85
|
+
" \"dimensions\": [\"Employees.name\"],",
|
|
86
|
+
" \"filters\": [",
|
|
87
|
+
" { \"member\": \"Productivity.date\", \"operator\": \"inDateRange\", \"values\": [\"last 3 months\"] }",
|
|
88
|
+
" ],",
|
|
89
|
+
" \"order\": { \"Productivity.totalPullRequests\": \"desc\" },",
|
|
90
|
+
" \"limit\": 5",
|
|
91
|
+
"}",
|
|
92
|
+
"```",
|
|
93
|
+
"The system AUTOMATICALLY joins Productivity to Employees for you!",
|
|
94
|
+
"",
|
|
95
|
+
"---",
|
|
96
|
+
"",
|
|
97
|
+
"## Date Filtering vs Time Grouping",
|
|
98
|
+
"",
|
|
99
|
+
"### For AGGREGATED TOTALS (no time breakdown)",
|
|
100
|
+
"Use `filters` with `inDateRange` operator. Do NOT use timeDimensions.",
|
|
101
|
+
"",
|
|
102
|
+
"```json",
|
|
103
|
+
"{",
|
|
104
|
+
" \"measures\": [\"Productivity.totalPullRequests\"],",
|
|
105
|
+
" \"dimensions\": [\"Employees.name\"],",
|
|
106
|
+
" \"filters\": [{ \"member\": \"Productivity.date\", \"operator\": \"inDateRange\", \"values\": [\"last 3 months\"] }],",
|
|
107
|
+
" \"order\": { \"Productivity.totalPullRequests\": \"desc\" },",
|
|
108
|
+
" \"limit\": 5",
|
|
109
|
+
"}",
|
|
110
|
+
"```",
|
|
111
|
+
"Result: 5 rows total, one per employee, with SUMMED pull requests.",
|
|
112
|
+
"",
|
|
113
|
+
"### For TIME SERIES (grouped by period)",
|
|
114
|
+
"Use `timeDimensions` WITH `granularity`.",
|
|
115
|
+
"",
|
|
116
|
+
"```json",
|
|
117
|
+
"{",
|
|
118
|
+
" \"measures\": [\"Productivity.totalPullRequests\"],",
|
|
119
|
+
" \"timeDimensions\": [{ \"dimension\": \"Productivity.date\", \"dateRange\": \"last 3 months\", \"granularity\": \"month\" }]",
|
|
120
|
+
"}",
|
|
121
|
+
"```",
|
|
122
|
+
"Result: 3 rows (one per month) with pull request totals.",
|
|
123
|
+
"",
|
|
124
|
+
"### WRONG: timeDimensions without granularity",
|
|
125
|
+
"```json",
|
|
126
|
+
"// DON'T DO THIS - groups by DAY, returns ~90 rows!",
|
|
127
|
+
"{ \"timeDimensions\": [{ \"dimension\": \"X.date\", \"dateRange\": \"last 3 months\" }] }",
|
|
128
|
+
"```",
|
|
129
|
+
"",
|
|
130
|
+
"---",
|
|
131
|
+
"",
|
|
132
|
+
"## Regular Query Structure",
|
|
133
|
+
"",
|
|
134
|
+
"```json",
|
|
135
|
+
"{",
|
|
136
|
+
" \"measures\": [\"Cube.measure1\", \"Cube.measure2\"],",
|
|
137
|
+
" \"dimensions\": [\"Cube.dimension1\", \"RelatedCube.dimension\"],",
|
|
138
|
+
" \"filters\": [",
|
|
139
|
+
" { \"member\": \"Cube.field\", \"operator\": \"equals\", \"values\": [\"value\"] },",
|
|
140
|
+
" { \"member\": \"Cube.date\", \"operator\": \"inDateRange\", \"values\": [\"last 30 days\"] }",
|
|
141
|
+
" ],",
|
|
142
|
+
" \"timeDimensions\": [],",
|
|
143
|
+
" \"order\": { \"Cube.measure1\": \"desc\" },",
|
|
144
|
+
" \"limit\": 100,",
|
|
145
|
+
" \"offset\": 0",
|
|
146
|
+
"}",
|
|
147
|
+
"```",
|
|
148
|
+
"",
|
|
149
|
+
"### Filter Operators",
|
|
150
|
+
"- String: equals, notEquals, contains, notContains, startsWith, endsWith",
|
|
151
|
+
"- Numeric: gt, gte, lt, lte",
|
|
152
|
+
"- Null: set, notSet",
|
|
153
|
+
"- Date: inDateRange, beforeDate, afterDate",
|
|
154
|
+
"",
|
|
155
|
+
"### Date Range Values",
|
|
156
|
+
"- Relative: \"last 7 days\", \"last 3 months\", \"last year\", \"this week\", \"this month\"",
|
|
157
|
+
"- Absolute: [\"2024-01-01\", \"2024-03-31\"]",
|
|
158
|
+
"",
|
|
159
|
+
"---",
|
|
160
|
+
"",
|
|
161
|
+
"## Funnel Query Structure",
|
|
162
|
+
"",
|
|
163
|
+
"Use when: conversion analysis, user journeys, step-by-step analysis",
|
|
164
|
+
"Requires: Cube with eventStream metadata",
|
|
165
|
+
"",
|
|
166
|
+
"```json",
|
|
167
|
+
"{",
|
|
168
|
+
" \"funnel\": {",
|
|
169
|
+
" \"bindingKey\": \"Events.userId\",",
|
|
170
|
+
" \"timeDimension\": \"Events.timestamp\",",
|
|
171
|
+
" \"steps\": [",
|
|
172
|
+
" {",
|
|
173
|
+
" \"name\": \"Step 1\",",
|
|
174
|
+
" \"filter\": [",
|
|
175
|
+
" { \"member\": \"Events.eventType\", \"operator\": \"equals\", \"values\": [\"signup\"] },",
|
|
176
|
+
" { \"member\": \"Events.timestamp\", \"operator\": \"inDateRange\", \"values\": [\"last 6 months\"] }",
|
|
177
|
+
" ]",
|
|
178
|
+
" },",
|
|
179
|
+
" {",
|
|
180
|
+
" \"name\": \"Step 2\",",
|
|
181
|
+
" \"filter\": [",
|
|
182
|
+
" { \"member\": \"Events.eventType\", \"operator\": \"equals\", \"values\": [\"purchase\"] }",
|
|
183
|
+
" ],",
|
|
184
|
+
" \"timeToConvert\": { \"value\": 7, \"unit\": \"day\" }",
|
|
185
|
+
" }",
|
|
186
|
+
" ],",
|
|
187
|
+
" \"includeTimeMetrics\": true",
|
|
188
|
+
" }",
|
|
189
|
+
"}",
|
|
190
|
+
"```",
|
|
191
|
+
"",
|
|
192
|
+
"IMPORTANT: Put time filter (inDateRange) ONLY on step 0!",
|
|
193
|
+
"",
|
|
194
|
+
"---",
|
|
195
|
+
"",
|
|
196
|
+
"## Flow Query Structure",
|
|
197
|
+
"",
|
|
198
|
+
"Use when: analyzing event sequences, path analysis",
|
|
199
|
+
"",
|
|
200
|
+
"```json",
|
|
201
|
+
"{",
|
|
202
|
+
" \"flow\": {",
|
|
203
|
+
" \"bindingKey\": \"Events.sessionId\",",
|
|
204
|
+
" \"eventDimension\": \"Events.eventType\",",
|
|
205
|
+
" \"timeDimension\": \"Events.timestamp\",",
|
|
206
|
+
" \"stepsBefore\": 2,",
|
|
207
|
+
" \"stepsAfter\": 2,",
|
|
208
|
+
" \"startingStep\": \"checkout\"",
|
|
209
|
+
" }",
|
|
210
|
+
"}",
|
|
211
|
+
"```",
|
|
212
|
+
"",
|
|
213
|
+
"---",
|
|
214
|
+
"",
|
|
215
|
+
"## Retention Query Structure",
|
|
216
|
+
"",
|
|
217
|
+
"Use when: cohort analysis, user retention tracking",
|
|
218
|
+
"",
|
|
219
|
+
"```json",
|
|
220
|
+
"{",
|
|
221
|
+
" \"retention\": {",
|
|
222
|
+
" \"bindingKey\": \"Users.id\",",
|
|
223
|
+
" \"timeDimension\": \"Events.timestamp\",",
|
|
224
|
+
" \"periods\": 8,",
|
|
225
|
+
" \"granularity\": \"week\",",
|
|
226
|
+
" \"retentionType\": \"rolling\",",
|
|
227
|
+
" \"breakdownDimensions\": [\"Events.country\"]",
|
|
228
|
+
" }",
|
|
229
|
+
"}",
|
|
230
|
+
"```",
|
|
231
|
+
"",
|
|
232
|
+
"---",
|
|
233
|
+
"",
|
|
234
|
+
"## Common Mistakes to Avoid",
|
|
235
|
+
"",
|
|
236
|
+
"1. Using timeDimensions when you want aggregated totals → Use filters with inDateRange instead",
|
|
237
|
+
"2. Omitting granularity in timeDimensions → Results in day-level grouping",
|
|
238
|
+
"3. Guessing field names → Always use discover first to get actual schema",
|
|
239
|
+
"4. Nested filter arrays → Filters must be flat: [{ member, operator, values }]",
|
|
240
|
+
"5. Missing date filter for \"last N\" queries → Always add inDateRange filter"
|
|
241
|
+
].join("\n")
|
|
242
|
+
}
|
|
243
|
+
}]
|
|
244
|
+
}, r = {
|
|
245
|
+
name: "drizzle-cube-date-filtering",
|
|
246
|
+
description: "CRITICAL: How to correctly filter by date vs group by time period - the #1 source of query mistakes",
|
|
247
|
+
messages: [{
|
|
248
|
+
role: "user",
|
|
249
|
+
content: {
|
|
250
|
+
type: "text",
|
|
251
|
+
text: [
|
|
252
|
+
"# Date Filtering vs Time Grouping - CRITICAL GUIDE",
|
|
253
|
+
"",
|
|
254
|
+
"This is the most common mistake when building queries. These are TWO DIFFERENT operations.",
|
|
255
|
+
"",
|
|
256
|
+
"## Quick Decision Tree",
|
|
257
|
+
"",
|
|
258
|
+
"```",
|
|
259
|
+
"User wants data over a time period?",
|
|
260
|
+
"├── Wants AGGREGATED TOTALS (e.g., \"total sales last month\")",
|
|
261
|
+
"│ └── Use: filters with inDateRange operator",
|
|
262
|
+
"│",
|
|
263
|
+
"└── Wants TIME SERIES breakdown (e.g., \"daily sales last month\")",
|
|
264
|
+
" └── Use: timeDimensions with granularity",
|
|
265
|
+
"```",
|
|
266
|
+
"",
|
|
267
|
+
"## For Aggregated Totals (MOST COMMON)",
|
|
268
|
+
"",
|
|
269
|
+
"When user says: \"last 3 months\", \"over the past year\", \"in Q1\", \"since January\"",
|
|
270
|
+
"",
|
|
271
|
+
"```json",
|
|
272
|
+
"{",
|
|
273
|
+
" \"measures\": [\"Sales.totalRevenue\"],",
|
|
274
|
+
" \"dimensions\": [\"Products.category\"],",
|
|
275
|
+
" \"filters\": [",
|
|
276
|
+
" { \"member\": \"Sales.date\", \"operator\": \"inDateRange\", \"values\": [\"last 3 months\"] }",
|
|
277
|
+
" ]",
|
|
278
|
+
"}",
|
|
279
|
+
"```",
|
|
280
|
+
"",
|
|
281
|
+
"Result: One row per category with TOTAL revenue over the 3-month period.",
|
|
282
|
+
"",
|
|
283
|
+
"## For Time Series (Trend Analysis)",
|
|
284
|
+
"",
|
|
285
|
+
"When user says: \"by month\", \"per week\", \"daily trend\", \"over time\"",
|
|
286
|
+
"",
|
|
287
|
+
"```json",
|
|
288
|
+
"{",
|
|
289
|
+
" \"measures\": [\"Sales.totalRevenue\"],",
|
|
290
|
+
" \"timeDimensions\": [",
|
|
291
|
+
" { \"dimension\": \"Sales.date\", \"dateRange\": \"last 3 months\", \"granularity\": \"month\" }",
|
|
292
|
+
" ]",
|
|
293
|
+
"}",
|
|
294
|
+
"```",
|
|
295
|
+
"",
|
|
296
|
+
"Result: Multiple rows, one per month.",
|
|
297
|
+
"",
|
|
298
|
+
"## WRONG: timeDimensions Without Granularity",
|
|
299
|
+
"",
|
|
300
|
+
"```json",
|
|
301
|
+
"// This returns ~90 rows (daily) instead of aggregates!",
|
|
302
|
+
"{",
|
|
303
|
+
" \"timeDimensions\": [{ \"dimension\": \"Sales.date\", \"dateRange\": \"last 3 months\" }]",
|
|
304
|
+
"}",
|
|
305
|
+
"```",
|
|
306
|
+
"",
|
|
307
|
+
"## Both: Filter AND Group",
|
|
308
|
+
"",
|
|
309
|
+
"When user wants: \"monthly breakdown for last quarter\"",
|
|
310
|
+
"",
|
|
311
|
+
"```json",
|
|
312
|
+
"{",
|
|
313
|
+
" \"measures\": [\"Sales.totalRevenue\"],",
|
|
314
|
+
" \"filters\": [",
|
|
315
|
+
" { \"member\": \"Sales.date\", \"operator\": \"inDateRange\", \"values\": [\"last quarter\"] }",
|
|
316
|
+
" ],",
|
|
317
|
+
" \"timeDimensions\": [",
|
|
318
|
+
" { \"dimension\": \"Sales.date\", \"granularity\": \"month\" }",
|
|
319
|
+
" ]",
|
|
320
|
+
"}",
|
|
321
|
+
"```",
|
|
322
|
+
"",
|
|
323
|
+
"## Summary Table",
|
|
324
|
+
"",
|
|
325
|
+
"| User Request | Use | Example |",
|
|
326
|
+
"|-------------|-----|---------|",
|
|
327
|
+
"| \"total for last 3 months\" | filters + inDateRange | { filters: [{ operator: \"inDateRange\", values: [\"last 3 months\"] }] } |",
|
|
328
|
+
"| \"top 5 last quarter\" | filters + inDateRange | Same as above + order + limit |",
|
|
329
|
+
"| \"monthly trend\" | timeDimensions + granularity | { timeDimensions: [{ granularity: \"month\" }] } |",
|
|
330
|
+
"| \"daily breakdown last week\" | timeDimensions | { timeDimensions: [{ dateRange: \"last week\", granularity: \"day\" }] } |"
|
|
331
|
+
].join("\n")
|
|
332
|
+
}
|
|
333
|
+
}]
|
|
334
|
+
}, i = [
|
|
335
|
+
e,
|
|
336
|
+
t,
|
|
337
|
+
n,
|
|
338
|
+
r
|
|
339
|
+
];
|
|
340
|
+
function a() {
|
|
341
|
+
return i;
|
|
342
|
+
}
|
|
343
|
+
//#endregion
|
|
344
|
+
export { a, t as i, e as n, n as r, r as t };
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
var e={name:`drizzle-cube-mcp-guide`,description:`How to use drizzle-cube MCP tools to generate and run queries`,messages:[{role:`user`,content:{type:`text`,text:[`You are an analyst agent using drizzle-cube MCP.`,``,`Workflow:`,`1) tools/call name=discover {topic|intent} - Find cubes and understand schema`,`2) Construct your query using the schema from discover (see cross-cube joins below)`,`3) tools/call name=validate {query} - Optional: fix schema issues`,`4) tools/call name=load {query} - Execute and get results`,``,`CRITICAL - CROSS-CUBE JOINS:`,`The "joins" property in discover results shows relationships between cubes.`,`You can include dimensions from ANY related cube in your query!`,`Example: If Productivity joins to Employees, query:`,`{ "measures": ["Productivity.totalPullRequests"], "dimensions": ["Employees.name"] }`,`The system automatically joins the cubes for you.`,``,`Query shapes:`,`- Regular: { measures, dimensions, filters[], timeDimensions[], order, limit, offset }`,`- Funnel: { funnel: { bindingKey, timeDimension, steps[], includeTimeMetrics? } }`,`- Flow: { flow: { bindingKey, eventDimension, steps?, window? } }`,`- Retention: { retention: { bindingKey, timeDimension, periods, granularity, retentionType, breakdownDimensions } }`,``,`Time handling:`,`- For AGGREGATED TOTALS (e.g., "last 3 months"): use filters with inDateRange, NOT timeDimensions`,`- For TIME SERIES (e.g., "by month"): use timeDimensions with granularity`,`- You can combine both when needed`,``,`Filters: flat arrays of { member, operator, values }. Do not nest arrays.`,`Do NOT hallucinate cube/field names—always use discover first.`].join(`
|
|
2
|
+
`)}}]},t={name:`drizzle-cube-query-rules`,description:`Key generation rules aligned with Gemini single-step prompt`,messages:[{role:`user`,content:{type:`text`,text:[`Rules (keep JSON only):`,"- Use only measures/dimensions/timeDimensions from schema. Fields are always `CubeName.fieldName` — never use just the cube name (e.g. `PullRequests.count` not `PullRequests`).",`- timeDimensions: include granularity when grouping; use inDateRange filter for relative windows; combine when both requested.`,`- Funnel detection keywords: funnel, conversion, journey, drop off, step by step; use funnel format only if eventStream metadata exists.`,`- Funnel rules: bindingKey/timeDimension from cube metadata; include time filter on step 0 (default last 6 months) using inDateRange; steps ordered; flat filters.`,`- Chart selection: line/area for time trends; bar for categories; scatter for 2-measure correlations; bubble for 3-measure correlations; funnel for funnels.`,`- Correlation keywords (correlation/relationship/vs/compare) -> scatter/bubble, never line.`,`- Prefer .name fields over .id; avoid Id dimensions unless requested.`,`- Filters: flat array of {member, operator, values}; operators equals, notEquals, contains, notContains, gt, gte, lt, lte, inDateRange, set, notSet.`].join(`
|
|
3
|
+
`)}}]},n={name:`drizzle-cube-query-building`,description:`CRITICAL: Complete guide for building valid queries of all types with examples`,messages:[{role:`user`,content:{type:`text`,text:[`# Drizzle Cube Query Building Guide`,``,`## CRITICAL: Cross-Cube Joins`,``,`You can combine measures from one cube with dimensions from RELATED cubes!`,`Check the "joins" property in discover results to see relationships.`,``,`Example: "Top 5 employees by pull requests last 3 months"`,`- Productivity cube has: measures (totalPullRequests), dimensions (date)`,`- Productivity joins to Employees (via employeeId)`,`- Employees cube has: dimensions (name, department)`,``,`Query combining BOTH cubes:`,"```json",`{`,` "measures": ["Productivity.totalPullRequests"],`,` "dimensions": ["Employees.name"],`,` "filters": [`,` { "member": "Productivity.date", "operator": "inDateRange", "values": ["last 3 months"] }`,` ],`,` "order": { "Productivity.totalPullRequests": "desc" },`,` "limit": 5`,`}`,"```",`The system AUTOMATICALLY joins Productivity to Employees for you!`,``,`---`,``,`## Date Filtering vs Time Grouping`,``,`### For AGGREGATED TOTALS (no time breakdown)`,"Use `filters` with `inDateRange` operator. Do NOT use timeDimensions.",``,"```json",`{`,` "measures": ["Productivity.totalPullRequests"],`,` "dimensions": ["Employees.name"],`,` "filters": [{ "member": "Productivity.date", "operator": "inDateRange", "values": ["last 3 months"] }],`,` "order": { "Productivity.totalPullRequests": "desc" },`,` "limit": 5`,`}`,"```",`Result: 5 rows total, one per employee, with SUMMED pull requests.`,``,`### For TIME SERIES (grouped by period)`,"Use `timeDimensions` WITH `granularity`.",``,"```json",`{`,` "measures": ["Productivity.totalPullRequests"],`,` "timeDimensions": [{ "dimension": "Productivity.date", "dateRange": "last 3 months", "granularity": "month" }]`,`}`,"```",`Result: 3 rows (one per month) with pull request totals.`,``,`### WRONG: timeDimensions without granularity`,"```json",`// DON'T DO THIS - groups by DAY, returns ~90 rows!`,`{ "timeDimensions": [{ "dimension": "X.date", "dateRange": "last 3 months" }] }`,"```",``,`---`,``,`## Regular Query Structure`,``,"```json",`{`,` "measures": ["Cube.measure1", "Cube.measure2"],`,` "dimensions": ["Cube.dimension1", "RelatedCube.dimension"],`,` "filters": [`,` { "member": "Cube.field", "operator": "equals", "values": ["value"] },`,` { "member": "Cube.date", "operator": "inDateRange", "values": ["last 30 days"] }`,` ],`,` "timeDimensions": [],`,` "order": { "Cube.measure1": "desc" },`,` "limit": 100,`,` "offset": 0`,`}`,"```",``,`### Filter Operators`,`- String: equals, notEquals, contains, notContains, startsWith, endsWith`,`- Numeric: gt, gte, lt, lte`,`- Null: set, notSet`,`- Date: inDateRange, beforeDate, afterDate`,``,`### Date Range Values`,`- Relative: "last 7 days", "last 3 months", "last year", "this week", "this month"`,`- Absolute: ["2024-01-01", "2024-03-31"]`,``,`---`,``,`## Funnel Query Structure`,``,`Use when: conversion analysis, user journeys, step-by-step analysis`,`Requires: Cube with eventStream metadata`,``,"```json",`{`,` "funnel": {`,` "bindingKey": "Events.userId",`,` "timeDimension": "Events.timestamp",`,` "steps": [`,` {`,` "name": "Step 1",`,` "filter": [`,` { "member": "Events.eventType", "operator": "equals", "values": ["signup"] },`,` { "member": "Events.timestamp", "operator": "inDateRange", "values": ["last 6 months"] }`,` ]`,` },`,` {`,` "name": "Step 2",`,` "filter": [`,` { "member": "Events.eventType", "operator": "equals", "values": ["purchase"] }`,` ],`,` "timeToConvert": { "value": 7, "unit": "day" }`,` }`,` ],`,` "includeTimeMetrics": true`,` }`,`}`,"```",``,`IMPORTANT: Put time filter (inDateRange) ONLY on step 0!`,``,`---`,``,`## Flow Query Structure`,``,`Use when: analyzing event sequences, path analysis`,``,"```json",`{`,` "flow": {`,` "bindingKey": "Events.sessionId",`,` "eventDimension": "Events.eventType",`,` "timeDimension": "Events.timestamp",`,` "stepsBefore": 2,`,` "stepsAfter": 2,`,` "startingStep": "checkout"`,` }`,`}`,"```",``,`---`,``,`## Retention Query Structure`,``,`Use when: cohort analysis, user retention tracking`,``,"```json",`{`,` "retention": {`,` "bindingKey": "Users.id",`,` "timeDimension": "Events.timestamp",`,` "periods": 8,`,` "granularity": "week",`,` "retentionType": "rolling",`,` "breakdownDimensions": ["Events.country"]`,` }`,`}`,"```",``,`---`,``,`## Common Mistakes to Avoid`,``,`1. Using timeDimensions when you want aggregated totals → Use filters with inDateRange instead`,`2. Omitting granularity in timeDimensions → Results in day-level grouping`,`3. Guessing field names → Always use discover first to get actual schema`,`4. Nested filter arrays → Filters must be flat: [{ member, operator, values }]`,`5. Missing date filter for "last N" queries → Always add inDateRange filter`].join(`
|
|
4
|
+
`)}}]},r={name:`drizzle-cube-date-filtering`,description:`CRITICAL: How to correctly filter by date vs group by time period - the #1 source of query mistakes`,messages:[{role:`user`,content:{type:`text`,text:[`# Date Filtering vs Time Grouping - CRITICAL GUIDE`,``,`This is the most common mistake when building queries. These are TWO DIFFERENT operations.`,``,`## Quick Decision Tree`,``,"```",`User wants data over a time period?`,`├── Wants AGGREGATED TOTALS (e.g., "total sales last month")`,`│ └── Use: filters with inDateRange operator`,`│`,`└── Wants TIME SERIES breakdown (e.g., "daily sales last month")`,` └── Use: timeDimensions with granularity`,"```",``,`## For Aggregated Totals (MOST COMMON)`,``,`When user says: "last 3 months", "over the past year", "in Q1", "since January"`,``,"```json",`{`,` "measures": ["Sales.totalRevenue"],`,` "dimensions": ["Products.category"],`,` "filters": [`,` { "member": "Sales.date", "operator": "inDateRange", "values": ["last 3 months"] }`,` ]`,`}`,"```",``,`Result: One row per category with TOTAL revenue over the 3-month period.`,``,`## For Time Series (Trend Analysis)`,``,`When user says: "by month", "per week", "daily trend", "over time"`,``,"```json",`{`,` "measures": ["Sales.totalRevenue"],`,` "timeDimensions": [`,` { "dimension": "Sales.date", "dateRange": "last 3 months", "granularity": "month" }`,` ]`,`}`,"```",``,`Result: Multiple rows, one per month.`,``,`## WRONG: timeDimensions Without Granularity`,``,"```json",`// This returns ~90 rows (daily) instead of aggregates!`,`{`,` "timeDimensions": [{ "dimension": "Sales.date", "dateRange": "last 3 months" }]`,`}`,"```",``,`## Both: Filter AND Group`,``,`When user wants: "monthly breakdown for last quarter"`,``,"```json",`{`,` "measures": ["Sales.totalRevenue"],`,` "filters": [`,` { "member": "Sales.date", "operator": "inDateRange", "values": ["last quarter"] }`,` ],`,` "timeDimensions": [`,` { "dimension": "Sales.date", "granularity": "month" }`,` ]`,`}`,"```",``,`## Summary Table`,``,`| User Request | Use | Example |`,`|-------------|-----|---------|`,`| "total for last 3 months" | filters + inDateRange | { filters: [{ operator: "inDateRange", values: ["last 3 months"] }] } |`,`| "top 5 last quarter" | filters + inDateRange | Same as above + order + limit |`,`| "monthly trend" | timeDimensions + granularity | { timeDimensions: [{ granularity: "month" }] } |`,`| "daily breakdown last week" | timeDimensions | { timeDimensions: [{ dateRange: "last week", granularity: "day" }] } |`].join(`
|
|
5
|
+
`)}}]},i=[e,t,n,r];function a(){return i}Object.defineProperty(exports,`a`,{enumerable:!0,get:function(){return a}}),Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return t}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return e}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return n}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return r}});
|