@lightdash-tools/mcp 0.13.2 → 0.16.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +54 -18
- package/dist/auth/oauth-broker/lightdash-token.d.ts +6 -5
- package/dist/auth/oauth-broker/lightdash-token.js +6 -10
- package/dist/auth/oauth-broker/mcp-access-token.d.ts +31 -0
- package/dist/auth/oauth-broker/mcp-access-token.js +109 -0
- package/dist/auth/oauth-broker/mcp-access-token.test.d.ts +1 -0
- package/dist/auth/oauth-broker/mcp-access-token.test.js +61 -0
- package/dist/auth/oauth-broker/pending-store.d.ts +9 -3
- package/dist/auth/oauth-broker/pending-store.js +5 -3
- package/dist/auth/oauth-broker/pending-store.test.js +28 -44
- package/dist/auth/oauth-broker/routes.d.ts +2 -1
- package/dist/auth/oauth-broker/routes.js +97 -45
- package/dist/auth/oauth-broker/routes.test.js +81 -13
- package/dist/auth/request-state-key.d.ts +1 -1
- package/dist/auth/request-state-key.js +1 -1
- package/dist/auth/resource-server/lightdash-oauth-middleware.d.ts +2 -0
- package/dist/auth/resource-server/lightdash-oauth-middleware.js +58 -37
- package/dist/auth/resource-server/lightdash-oauth-middleware.test.js +59 -57
- package/dist/auth/resource-server/oauth-protected-resource.d.ts +2 -2
- package/dist/auth/resource-server/oauth-protected-resource.js +10 -9
- package/dist/bin.js +34 -8
- package/dist/config/enabled-profiles.d.ts +23 -0
- package/dist/config/enabled-profiles.js +57 -0
- package/dist/config/enabled-profiles.test.d.ts +1 -0
- package/dist/config/enabled-profiles.test.js +62 -0
- package/dist/config/env.d.ts +7 -0
- package/dist/config/env.js +8 -1
- package/dist/config/load-mcp-config.d.ts +15 -1
- package/dist/config/load-mcp-config.js +21 -9
- package/dist/config/load-mcp-config.test.js +61 -0
- package/dist/config/prompt-context-policy.d.ts +18 -0
- package/dist/config/prompt-context-policy.js +40 -0
- package/dist/config/prompt-context-policy.test.d.ts +4 -0
- package/dist/config/prompt-context-policy.test.js +35 -0
- package/dist/config/test-mcp-http-config.js +4 -1
- package/dist/governance/mcp-post-factory-context.d.ts +2 -0
- package/dist/http.d.ts +7 -1
- package/dist/http.integration.test.js +102 -44
- package/dist/http.js +10 -1
- package/dist/index.d.ts +6 -1
- package/dist/index.integration.test.js +3 -12
- package/dist/index.js +6 -3
- package/dist/policy/content-developer.d.ts +5 -0
- package/dist/policy/content-developer.js +25 -1
- package/dist/policy/content-developer.test.js +29 -0
- package/dist/profiles/ai-agent-ops/v1/invariants.d.ts +27 -0
- package/dist/profiles/ai-agent-ops/v1/invariants.js +39 -0
- package/dist/profiles/ai-agent-ops/v1/prompts.d.ts +3 -2
- package/dist/profiles/ai-agent-ops/v1/prompts.js +67 -41
- package/dist/profiles/ai-agent-ops/v1/resources/playbooks.d.ts +2 -1
- package/dist/profiles/ai-agent-ops/v1/resources/playbooks.js +10 -3
- package/dist/profiles/content-developer/v1/invariants.d.ts +69 -0
- package/dist/profiles/content-developer/v1/invariants.js +95 -0
- package/dist/profiles/content-developer/v1/prompt-specs.d.ts +32 -0
- package/dist/profiles/content-developer/v1/prompt-specs.js +56 -0
- package/dist/profiles/content-developer/v1/prompts.d.ts +4 -3
- package/dist/profiles/content-developer/v1/prompts.js +65 -71
- package/dist/profiles/content-developer/v1/prompts.test.js +61 -7
- package/dist/profiles/content-developer/v1/resources/playbooks/chart-types.md +2 -1
- package/dist/profiles/content-developer/v1/resources/playbooks/core.md +3 -1
- package/dist/profiles/content-developer/v1/resources/playbooks/dashboard-design.md +11 -1
- package/dist/profiles/content-developer/v1/resources/playbooks/dashboards.md +1 -1
- package/dist/profiles/content-developer/v1/resources/playbooks/index.md +11 -8
- package/dist/profiles/content-developer/v1/resources/playbooks/recovery/dashboard-diff.md +15 -0
- package/dist/profiles/content-developer/v1/resources/playbooks/recovery/preview-required.md +14 -0
- package/dist/profiles/content-developer/v1/resources/playbooks/recovery/preview-stale.md +21 -0
- package/dist/profiles/content-developer/v1/resources/playbooks/table-calculations.md +15 -3
- package/dist/profiles/content-developer/v1/resources/playbooks.d.ts +3 -2
- package/dist/profiles/content-developer/v1/resources/playbooks.js +35 -21
- package/dist/profiles/content-governance/v1/invariants.d.ts +27 -0
- package/dist/profiles/content-governance/v1/invariants.js +39 -0
- package/dist/profiles/content-governance/v1/prompts.d.ts +4 -2
- package/dist/profiles/content-governance/v1/prompts.js +31 -19
- package/dist/profiles/content-governance/v1/resources/playbooks.d.ts +2 -1
- package/dist/profiles/content-governance/v1/resources/playbooks.js +8 -9
- package/dist/profiles/content-reader/v1/index.js +1 -0
- package/dist/profiles/content-reader/v1/invariants.d.ts +33 -0
- package/dist/profiles/content-reader/v1/invariants.js +47 -0
- package/dist/profiles/content-reader/v1/prompt-specs.d.ts +18 -0
- package/dist/profiles/content-reader/v1/prompt-specs.js +33 -0
- package/dist/profiles/content-reader/v1/prompts.d.ts +3 -2
- package/dist/profiles/content-reader/v1/prompts.js +69 -75
- package/dist/profiles/content-reader/v1/resources/playbooks/compare.md +1 -1
- package/dist/profiles/content-reader/v1/resources/playbooks/core.md +1 -0
- package/dist/profiles/content-reader/v1/resources/playbooks/discover.md +12 -3
- package/dist/profiles/content-reader/v1/resources/playbooks/explain-run.md +2 -1
- package/dist/profiles/content-reader/v1/resources/playbooks.d.ts +2 -1
- package/dist/profiles/content-reader/v1/resources/playbooks.js +10 -11
- package/dist/profiles/data-analyst/v1/invariants.d.ts +21 -0
- package/dist/profiles/data-analyst/v1/invariants.js +31 -0
- package/dist/profiles/data-analyst/v1/prompts.d.ts +3 -2
- package/dist/profiles/data-analyst/v1/prompts.js +17 -9
- package/dist/profiles/data-analyst/v1/resources/playbooks.d.ts +2 -1
- package/dist/profiles/data-analyst/v1/resources/playbooks.js +6 -7
- package/dist/profiles/index.d.ts +2 -1
- package/dist/profiles/index.js +2 -1
- package/dist/profiles/index.test.js +2 -1
- package/dist/profiles/lib/playbook-resources.d.ts +16 -34
- package/dist/profiles/lib/playbook-resources.js +55 -76
- package/dist/profiles/lib/prompt-context.d.ts +71 -0
- package/dist/profiles/lib/prompt-context.js +205 -0
- package/dist/profiles/lib/prompt-context.test.d.ts +4 -0
- package/dist/profiles/lib/prompt-context.test.js +154 -0
- package/dist/profiles/lib/prompt-invariants.d.ts +20 -0
- package/dist/profiles/lib/prompt-invariants.js +54 -0
- package/dist/profiles/organization-audit/v1/invariants.d.ts +24 -0
- package/dist/profiles/organization-audit/v1/invariants.js +35 -0
- package/dist/profiles/organization-audit/v1/prompts.d.ts +3 -2
- package/dist/profiles/organization-audit/v1/prompts.js +44 -28
- package/dist/profiles/organization-audit/v1/resources/playbooks.d.ts +2 -1
- package/dist/profiles/organization-audit/v1/resources/playbooks.js +10 -3
- package/dist/profiles/semantic-layer/v1/invariants.d.ts +27 -0
- package/dist/profiles/semantic-layer/v1/invariants.js +39 -0
- package/dist/profiles/semantic-layer/v1/prompts.d.ts +3 -2
- package/dist/profiles/semantic-layer/v1/prompts.js +37 -26
- package/dist/profiles/semantic-layer/v1/resources/playbooks.d.ts +2 -4
- package/dist/profiles/semantic-layer/v1/resources/playbooks.js +8 -7
- package/dist/profiles/test-support/prompt-context-budget.test.d.ts +5 -0
- package/dist/profiles/test-support/prompt-context-budget.test.js +72 -0
- package/dist/profiles/types.d.ts +6 -1
- package/dist/server/capabilities.d.ts +3 -0
- package/dist/server/capabilities.js +4 -2
- package/dist/stdio.process.test.js +2 -1
- package/dist/tools/lib/schema-fields.d.ts +4 -0
- package/dist/tools/lib/schema-fields.js +8 -1
- package/dist/tools/project/developer-content-preview.js +1 -1
- package/dist/tools/project/developer-content.js +2 -2
- package/dist/tools/project/reader-content.d.ts +2 -0
- package/dist/tools/project/reader-content.js +28 -1
- package/dist/tools/query/reader-tool-helpers.d.ts +2 -2
- package/dist/tools/query/reader-tool-helpers.js +2 -2
- package/dist/tools/query/reader-tool-helpers.test.js +1 -0
- package/dist/tools/shared.d.ts +6 -1
- package/dist/tools/shared.js +12 -2
- package/dist/transports/streamable-http.js +16 -6
- package/dist/transports/streamable-http.test.js +16 -0
- package/package.json +3 -3
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* MCP prompts for content-reader workflows.
|
|
2
|
+
* MCP prompts for content-reader workflows (progressive-disclosure context).
|
|
3
3
|
*/
|
|
4
|
+
import type { RegisterPromptsOptions } from '../../types.js';
|
|
4
5
|
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
|
-
export declare function registerContentReaderPrompts(server: McpServer): void;
|
|
6
|
+
export declare function registerContentReaderPrompts(server: McpServer, options?: RegisterPromptsOptions): void;
|
|
@@ -1,162 +1,156 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
/**
|
|
3
|
-
* MCP prompts for content-reader workflows.
|
|
3
|
+
* MCP prompts for content-reader workflows (progressive-disclosure context).
|
|
4
4
|
*/
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.registerContentReaderPrompts = registerContentReaderPrompts;
|
|
7
7
|
/* eslint-disable @typescript-eslint/no-deprecated -- matches organization-audit prompt registration pattern */
|
|
8
8
|
const zod_1 = require("zod");
|
|
9
9
|
const schema_fields_js_1 = require("../../../tools/lib/schema-fields.js");
|
|
10
|
-
const
|
|
10
|
+
const prompt_context_js_1 = require("../../lib/prompt-context.js");
|
|
11
|
+
const invariants_js_1 = require("./invariants.js");
|
|
12
|
+
const prompt_specs_js_1 = require("./prompt-specs.js");
|
|
11
13
|
const playbooks_js_1 = require("./resources/playbooks.js");
|
|
12
|
-
const
|
|
14
|
+
const TOPIC_COMPARE = 'compare';
|
|
15
|
+
const TOPIC_EXPLAIN_RUN = 'explain-run';
|
|
16
|
+
const bindPromptContext = (0, prompt_context_js_1.bindProfilePromptContext)({
|
|
17
|
+
invariants: invariants_js_1.CONTENT_READER_INVARIANTS,
|
|
13
18
|
core: playbooks_js_1.CONTENT_READER_CORE_PLAYBOOK,
|
|
14
19
|
topics: playbooks_js_1.CONTENT_READER_TOPIC_PLAYBOOKS,
|
|
20
|
+
topicMeta: playbooks_js_1.CONTENT_READER_TOPIC_META,
|
|
15
21
|
});
|
|
16
|
-
|
|
17
|
-
const
|
|
18
|
-
const
|
|
19
|
-
function registerContentReaderPrompts(server) {
|
|
22
|
+
function registerContentReaderPrompts(server, options) {
|
|
23
|
+
const promptContext = bindPromptContext(options === null || options === void 0 ? void 0 : options.promptContextPolicy);
|
|
24
|
+
const invariantIds = invariants_js_1.CONTENT_READER_DEFAULT_INVARIANT_IDS;
|
|
20
25
|
server.registerPrompt('find_content', {
|
|
21
26
|
title: 'Find content',
|
|
22
27
|
description: 'Find the most relevant saved Lightdash content in the current project',
|
|
23
28
|
argsSchema: {
|
|
24
|
-
projectUuid:
|
|
29
|
+
projectUuid: (0, schema_fields_js_1.optionalProjectUuidField)(),
|
|
25
30
|
question: zod_1.z.string(),
|
|
26
31
|
contentTypes: zod_1.z.string().optional(),
|
|
27
32
|
verifiedOnly: zod_1.z.boolean().optional(),
|
|
28
33
|
spaceUuid: zod_1.z.string().optional(),
|
|
29
34
|
},
|
|
30
|
-
}, ({ projectUuid, question, contentTypes, verifiedOnly, spaceUuid }) =>
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
Content types hint: ${contentTypes !== null && contentTypes !== void 0 ? contentTypes : '(any)'}.
|
|
38
|
-
Verified only: ${verifiedOnly !== null && verifiedOnly !== void 0 ? verifiedOnly : false} (verification is often null — fall back to pinned + views + description).
|
|
39
|
-
Space filter: ${spaceUuid !== null && spaceUuid !== void 0 ? spaceUuid : '(none)'}.
|
|
40
|
-
|
|
41
|
-
Procedure:
|
|
42
|
-
1. get_project with projectUuid/pin; record readerCapabilities.
|
|
43
|
-
2. search_content with short tokens (retry Japanese/single keyword / sortBy=views if empty). Use spaceUuids when given. pageSize≤25; ≤2 pages.
|
|
44
|
-
3. Prefer semantic charts (source≠sql). Rank by relevance, views, pinnedList; verification is optional.
|
|
45
|
-
4. Optionally list_spaces / get_space (≤3) to confirm path.
|
|
46
|
-
5. Return ≤5 candidates (name/type/uuid/space/views/source/why). Do not execute unless values were requested.`, 'discover'));
|
|
35
|
+
}, ({ projectUuid, question, contentTypes, verifiedOnly, spaceUuid }) => promptContext((0, prompt_specs_js_1.buildFindContentPromptSpec)({
|
|
36
|
+
projectUuid,
|
|
37
|
+
question,
|
|
38
|
+
contentTypes,
|
|
39
|
+
verifiedOnly,
|
|
40
|
+
spaceUuid,
|
|
41
|
+
})));
|
|
47
42
|
server.registerPrompt('explain_chart', {
|
|
48
43
|
title: 'Explain chart',
|
|
49
44
|
description: 'Explain a saved chart from metadata (optional bounded execution)',
|
|
50
45
|
argsSchema: {
|
|
51
|
-
projectUuid:
|
|
46
|
+
projectUuid: (0, schema_fields_js_1.optionalProjectUuidField)(),
|
|
52
47
|
chartUuidOrSlug: zod_1.z.string(),
|
|
53
48
|
includeLatestValues: zod_1.z.boolean().optional(),
|
|
54
49
|
},
|
|
55
|
-
}, ({ projectUuid, chartUuidOrSlug, includeLatestValues }) =>
|
|
56
|
-
|
|
57
|
-
${playbooks_js_1.CONTENT_READER_HARD_BANS}
|
|
50
|
+
}, ({ projectUuid, chartUuidOrSlug, includeLatestValues }) => promptContext({
|
|
51
|
+
task: `Explain the saved chart ${chartUuidOrSlug}.
|
|
58
52
|
|
|
59
|
-
|
|
53
|
+
${(0, schema_fields_js_1.formatPromptProjectUuidLine)(projectUuid)}
|
|
60
54
|
includeLatestValues=${includeLatestValues !== null && includeLatestValues !== void 0 ? includeLatestValues : false}.
|
|
61
55
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
6. Do not construct a new query or retrieve underlying data.`, TOPIC_EXPLAIN_RUN));
|
|
56
|
+
Workflow:
|
|
57
|
+
get_project → get_chart / explain_content → optional bounded run_chart / export_chart_image.
|
|
58
|
+
Skip SQL charts for execution. Separate explicit metadata from inference.`,
|
|
59
|
+
invariantIds,
|
|
60
|
+
requiredTopics: [TOPIC_EXPLAIN_RUN],
|
|
61
|
+
}));
|
|
69
62
|
server.registerPrompt('summarize_dashboard', {
|
|
70
63
|
title: 'Summarize dashboard',
|
|
71
64
|
description: 'Summarize a dashboard with optional bounded tile execution',
|
|
72
65
|
argsSchema: {
|
|
73
|
-
projectUuid:
|
|
66
|
+
projectUuid: (0, schema_fields_js_1.optionalProjectUuidField)(),
|
|
74
67
|
dashboardUuidOrSlug: zod_1.z.string(),
|
|
75
68
|
executeTiles: zod_1.z.boolean().optional(),
|
|
76
69
|
maximumTiles: zod_1.z.number().optional(),
|
|
77
70
|
focus: zod_1.z.string().optional(),
|
|
78
71
|
},
|
|
79
|
-
}, ({ projectUuid, dashboardUuidOrSlug, executeTiles, maximumTiles, focus }) =>
|
|
80
|
-
|
|
81
|
-
${playbooks_js_1.CONTENT_READER_HARD_BANS}
|
|
72
|
+
}, ({ projectUuid, dashboardUuidOrSlug, executeTiles, maximumTiles, focus }) => promptContext({
|
|
73
|
+
task: `Summarize dashboard ${dashboardUuidOrSlug}.
|
|
82
74
|
|
|
83
|
-
|
|
75
|
+
${(0, schema_fields_js_1.formatPromptProjectUuidLine)(projectUuid)}
|
|
84
76
|
Focus: ${focus !== null && focus !== void 0 ? focus : '(general summary)'}.
|
|
85
77
|
Execute tiles: ${executeTiles !== null && executeTiles !== void 0 ? executeTiles : false}; max tiles: ${maximumTiles !== null && maximumTiles !== void 0 ? maximumTiles : 5}.
|
|
86
78
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
79
|
+
Workflow:
|
|
80
|
+
get_dashboard → summarize structure → optional bounded run_dashboard_tile.
|
|
81
|
+
Unexecuted tiles must not support conclusions.`,
|
|
82
|
+
invariantIds,
|
|
83
|
+
requiredTopics: [TOPIC_EXPLAIN_RUN],
|
|
84
|
+
}));
|
|
92
85
|
server.registerPrompt('answer_from_content', {
|
|
93
86
|
title: 'Answer from content',
|
|
94
87
|
description: 'Answer a question using existing saved Lightdash content only',
|
|
95
88
|
argsSchema: {
|
|
96
|
-
projectUuid:
|
|
89
|
+
projectUuid: (0, schema_fields_js_1.optionalProjectUuidField)(),
|
|
97
90
|
question: zod_1.z.string(),
|
|
98
91
|
verifiedOnly: zod_1.z.boolean().optional(),
|
|
99
92
|
maximumExecutions: zod_1.z.number().optional(),
|
|
100
93
|
},
|
|
101
|
-
}, ({ projectUuid, question, verifiedOnly, maximumExecutions }) =>
|
|
94
|
+
}, ({ projectUuid, question, verifiedOnly, maximumExecutions }) => promptContext({
|
|
95
|
+
task: `Answer this question using existing Lightdash content only:
|
|
102
96
|
|
|
103
97
|
${question}
|
|
104
98
|
|
|
105
|
-
${
|
|
106
|
-
|
|
107
|
-
Project: ${projectUuid !== null && projectUuid !== void 0 ? projectUuid : PROJECT_UUID_HINT}.
|
|
108
|
-
Prefer verified=${verifiedOnly !== null && verifiedOnly !== void 0 ? verifiedOnly : false} when present; else pinned + views + description.
|
|
99
|
+
${(0, schema_fields_js_1.formatPromptProjectUuidLine)(projectUuid)}
|
|
100
|
+
Prefer verified=${verifiedOnly !== null && verifiedOnly !== void 0 ? verifiedOnly : false} when set — call list_verified_content first; else search_content.
|
|
109
101
|
Max executions: ${maximumExecutions !== null && maximumExecutions !== void 0 ? maximumExecutions : 3}.
|
|
110
102
|
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
103
|
+
Workflow:
|
|
104
|
+
discover → inspect → minimal bounded execution → answer with coverage/limitations.`,
|
|
105
|
+
invariantIds,
|
|
106
|
+
requiredTopics: [prompt_specs_js_1.TOPIC_DISCOVER, TOPIC_EXPLAIN_RUN],
|
|
107
|
+
}));
|
|
116
108
|
server.registerPrompt('compare_content', {
|
|
117
109
|
title: 'Compare content',
|
|
118
110
|
description: 'Compare saved content definitions and optionally values',
|
|
119
111
|
argsSchema: {
|
|
120
|
-
projectUuid:
|
|
112
|
+
projectUuid: (0, schema_fields_js_1.optionalProjectUuidField)(),
|
|
121
113
|
contentReferences: zod_1.z.string(),
|
|
122
114
|
comparisonQuestion: zod_1.z.string(),
|
|
123
115
|
},
|
|
124
|
-
}, ({ projectUuid, contentReferences, comparisonQuestion }) =>
|
|
116
|
+
}, ({ projectUuid, contentReferences, comparisonQuestion }) => promptContext({
|
|
117
|
+
task: `Compare these Lightdash content items:
|
|
125
118
|
|
|
126
119
|
${contentReferences}
|
|
127
120
|
|
|
128
121
|
Question:
|
|
129
122
|
${comparisonQuestion}
|
|
130
123
|
|
|
131
|
-
${
|
|
132
|
-
|
|
133
|
-
Project: ${projectUuid !== null && projectUuid !== void 0 ? projectUuid : PROJECT_UUID_HINT}.
|
|
124
|
+
${(0, schema_fields_js_1.formatPromptProjectUuidLine)(projectUuid)}
|
|
134
125
|
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
126
|
+
Workflow:
|
|
127
|
+
resolve both sides → diff definitions before values → execute only when needed (≤2).`,
|
|
128
|
+
invariantIds,
|
|
129
|
+
requiredTopics: [TOPIC_COMPARE],
|
|
130
|
+
}));
|
|
140
131
|
server.registerPrompt('investigate_result_difference', {
|
|
141
132
|
title: 'Investigate result difference',
|
|
142
133
|
description: 'Investigate why two content resources differ',
|
|
143
134
|
argsSchema: {
|
|
144
|
-
projectUuid:
|
|
135
|
+
projectUuid: (0, schema_fields_js_1.optionalProjectUuidField)(),
|
|
145
136
|
firstContent: zod_1.z.string(),
|
|
146
137
|
secondContent: zod_1.z.string(),
|
|
147
138
|
observedDifference: zod_1.z.string(),
|
|
148
139
|
},
|
|
149
|
-
}, ({ projectUuid, firstContent, secondContent, observedDifference }) =>
|
|
140
|
+
}, ({ projectUuid, firstContent, secondContent, observedDifference }) => promptContext({
|
|
141
|
+
task: `Investigate why these Lightdash resources differ:
|
|
150
142
|
|
|
151
143
|
First: ${firstContent}
|
|
152
144
|
Second: ${secondContent}
|
|
153
145
|
Difference: ${observedDifference}
|
|
154
146
|
|
|
155
|
-
${
|
|
156
|
-
|
|
157
|
-
Project: ${projectUuid !== null && projectUuid !== void 0 ? projectUuid : PROJECT_UUID_HINT}.
|
|
147
|
+
${(0, schema_fields_js_1.formatPromptProjectUuidLine)(projectUuid)}
|
|
158
148
|
|
|
159
|
-
|
|
160
|
-
|
|
149
|
+
Workflow:
|
|
150
|
+
checklist definitions (metrics, filters, grains, parameters, cache) → execute only when needed.
|
|
151
|
+
Separate confirmed, plausible, ruled-out, and unresolved causes.`,
|
|
152
|
+
invariantIds,
|
|
153
|
+
requiredTopics: [TOPIC_COMPARE],
|
|
154
|
+
}));
|
|
161
155
|
}
|
|
162
156
|
/* eslint-enable @typescript-eslint/no-deprecated */
|
|
@@ -11,7 +11,7 @@ Compare **definitions before values**. Matching titles/labels ≠ same metric, g
|
|
|
11
11
|
3. Diff checklist:
|
|
12
12
|
- Explore / `tableName`
|
|
13
13
|
- Metrics & dimensions (`fieldId`s)
|
|
14
|
-
- Filters (targets, operators, windows — e.g. `inThePast` days)
|
|
14
|
+
- Filters (targets, operators, windows — e.g. `inThePast` days; `in the last` vs completed periods vs `in the current` — [filters reference](https://docs.lightdash.com/guides/filters))
|
|
15
15
|
- Time grain / timezone fields
|
|
16
16
|
- Parameters, sorts, limits, pivots, table calculations
|
|
17
17
|
- Chart `source` / `chartType` (semantic vs SQL)
|
|
@@ -45,6 +45,7 @@ Record budget / pagination / truncation stops in the answer.
|
|
|
45
45
|
| ---------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- |
|
|
46
46
|
| `get_project` | Resolve project; read `readerCapabilities` + pin context |
|
|
47
47
|
| `search_content` | Find charts/dashboards/spaces/data apps |
|
|
48
|
+
| `list_verified_content` | List admin-verified charts/dashboards (prefer as trusted seeds) |
|
|
48
49
|
| `list_spaces` / `get_space` | Space hierarchy + immediate content |
|
|
49
50
|
| `get_dashboard` / `get_chart` | Structure / definition (saved SQL **chart** bodies hidden; semantic `tableCalculations` may appear when query is included) |
|
|
50
51
|
| `list_project_parameters` / `get_project_parameters` | Parameter defs / values |
|
|
@@ -6,17 +6,26 @@ URI: `lightdash://playbooks/content-reader/discover`
|
|
|
6
6
|
|
|
7
7
|
Map the user request to: find / explain / retrieve values / summarize dashboard / compare / investigate. Discovery-only intents **must not** execute.
|
|
8
8
|
|
|
9
|
+
## Verified content first
|
|
10
|
+
|
|
11
|
+
When the user asks for trusted / canonical / verified content, or the prompt sets `verifiedOnly=true`:
|
|
12
|
+
|
|
13
|
+
1. Call `list_verified_content` **before** keyword `search_content`.
|
|
14
|
+
2. Prefer verified matches as an absolute trump ([verified content](https://docs.lightdash.com/guides/verified-content)).
|
|
15
|
+
3. If the list is empty, fall back to search — verification is often absent in real orgs; do not stall.
|
|
16
|
+
|
|
9
17
|
## Search strategy
|
|
10
18
|
|
|
11
19
|
1. Prefer **short, high-signal tokens** that appear in titles (product names, Japanese KPI words). Multi-word English phrases often return **zero** hits even when related content exists.
|
|
12
20
|
2. If the first query is empty, try: alternate language tokens, a single keyword, `spaceUuids` / `parentSpaceUuid`, or browse with `sortBy=views` + `sortDirection=desc` (optional empty/`query` omitted) and then refine.
|
|
13
21
|
3. Always set `pageSize` (≤25). Prefer `contentTypes` when the user asked for charts vs dashboards.
|
|
14
22
|
4. Read `source` on chart hits: `dbt_explore` (or similar semantic) vs `sql`. Treat `sql` as **not executable** on this profile.
|
|
15
|
-
5. Ranking heuristics when relevance ties:
|
|
23
|
+
5. Ranking heuristics when relevance ties (after verified preference above):
|
|
16
24
|
- Higher `views` / pinned (`pinnedList` non-null)
|
|
17
25
|
- Richer description / clearer name match
|
|
18
26
|
- Prefer non-deleted / non-sandbox space names when obvious
|
|
19
|
-
|
|
27
|
+
|
|
28
|
+
`search_content` does **not** filter by verification — use `list_verified_content` for that.
|
|
20
29
|
|
|
21
30
|
## Spaces
|
|
22
31
|
|
|
@@ -29,7 +38,7 @@ Map the user request to: find / explain / retrieve values / summarize dashboard
|
|
|
29
38
|
Return **≤5** candidates:
|
|
30
39
|
|
|
31
40
|
```text
|
|
32
|
-
- name (type) — uuid/slug — space — views/pinned — source(if chart) — why relevant — warnings
|
|
41
|
+
- name (type) — uuid/slug — space — views/pinned — verified? — source(if chart) — why relevant — warnings
|
|
33
42
|
```
|
|
34
43
|
|
|
35
44
|
Do not execute unless the user asked for values or analysis.
|
|
@@ -36,7 +36,8 @@ Defaults: `useCache=true`, modest `limit` (≤100; summarize ≤20 rows in the a
|
|
|
36
36
|
1. Pick tiles with `executable=true` and a `chartUuid` (skip markdown / non-chart tiles).
|
|
37
37
|
2. Call `run_dashboard_tile` with dashboard UUID/slug + **`tileUuid`** from `get_dashboard`.
|
|
38
38
|
3. Preserve dashboard context; only pass `filterOverrides` / `parameterOverrides` for **existing** filter ids / known parameter names with **values** (never retarget filters).
|
|
39
|
-
4.
|
|
39
|
+
4. Optional **date zoom**: pass `dateZoom: { granularity?, xAxisFieldId? }` when the user asks to simulate a zoom ([date zoom](https://docs.lightdash.com/guides/date-zoom)). Otherwise execution uses the dashboard’s saved default granularity. Cite `appliedDateZoom` in the report when present.
|
|
40
|
+
5. Cap tiles per summary (`maximumTiles` / budget ≤5). Unexecuted tiles must not support conclusions.
|
|
40
41
|
|
|
41
42
|
## Async handles
|
|
42
43
|
|
|
@@ -3,8 +3,9 @@
|
|
|
3
3
|
*/
|
|
4
4
|
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
5
|
export type ContentReaderPlaybookTopic = 'compare' | 'discover' | 'explain-run';
|
|
6
|
-
export
|
|
6
|
+
export { CONTENT_READER_HARD_BANS } from '../invariants.js';
|
|
7
7
|
export declare const getAllPlaybookMarkdown: () => string;
|
|
8
8
|
export declare const CONTENT_READER_CORE_PLAYBOOK: import("../../../lib/playbook-resources.js").EmbeddedPlaybook;
|
|
9
9
|
export declare const CONTENT_READER_TOPIC_PLAYBOOKS: Readonly<Record<ContentReaderPlaybookTopic, import("../../../lib/playbook-resources.js").EmbeddedPlaybook>>;
|
|
10
|
+
export declare const CONTENT_READER_TOPIC_META: Readonly<Record<ContentReaderPlaybookTopic, import("../../../lib/playbook-resources.js").PromptTopicMeta>>;
|
|
10
11
|
export declare function registerContentReaderPlaybook(server: McpServer): void;
|
|
@@ -3,21 +3,12 @@
|
|
|
3
3
|
* Content-reader multi-playbook resources (core + topics + index).
|
|
4
4
|
*/
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.CONTENT_READER_TOPIC_PLAYBOOKS = exports.CONTENT_READER_CORE_PLAYBOOK = exports.getAllPlaybookMarkdown = exports.CONTENT_READER_HARD_BANS = void 0;
|
|
6
|
+
exports.CONTENT_READER_TOPIC_META = exports.CONTENT_READER_TOPIC_PLAYBOOKS = exports.CONTENT_READER_CORE_PLAYBOOK = exports.getAllPlaybookMarkdown = exports.CONTENT_READER_HARD_BANS = void 0;
|
|
7
7
|
exports.registerContentReaderPlaybook = registerContentReaderPlaybook;
|
|
8
8
|
const playbook_resources_js_1 = require("../../../lib/playbook-resources.js");
|
|
9
9
|
const playbooks = (0, playbook_resources_js_1.defineProfilePlaybooks)({
|
|
10
10
|
profileId: 'content-reader',
|
|
11
11
|
moduleDir: __dirname,
|
|
12
|
-
hardBans: `Do not mutate Lightdash resources.
|
|
13
|
-
Do not execute arbitrary metric queries, raw SQL, or underlying-data queries.
|
|
14
|
-
Do not download or bulk-export results.
|
|
15
|
-
Do not execute saved SQL charts (disabled by default on content-reader).
|
|
16
|
-
Do not override filter targets, operators, required-filter behavior, fields, metrics, dimensions, SQL, table calculations, or sorts.
|
|
17
|
-
Do not execute content outside the resolved project (pass projectUuid or HTTP pin).
|
|
18
|
-
Do not present truncated results as complete.
|
|
19
|
-
Do not claim metric equivalence from matching labels alone.
|
|
20
|
-
Do not reveal secrets, warehouse credentials, hidden SQL, or inaccessible content.`,
|
|
21
12
|
coreDescription: 'Hard bans, budgets, tools, project scope, and coverage semantics',
|
|
22
13
|
topics: [
|
|
23
14
|
{
|
|
@@ -25,25 +16,33 @@ Do not reveal secrets, warehouse credentials, hidden SQL, or inaccessible conten
|
|
|
25
16
|
title: 'Content-reader discover playbook',
|
|
26
17
|
description: 'Intent classification and content discovery',
|
|
27
18
|
file: 'discover.md',
|
|
19
|
+
useWhen: 'Search results are weak, verified-only behavior matters, or discovery needs fallback',
|
|
20
|
+
priority: 0.8,
|
|
28
21
|
},
|
|
29
22
|
{
|
|
30
23
|
id: 'explain-run',
|
|
31
24
|
title: 'Content-reader explain/run playbook',
|
|
32
25
|
description: 'Inspect metadata and execute bounded saved content',
|
|
33
26
|
file: 'explain-run.md',
|
|
27
|
+
useWhen: 'Explaining or optionally executing a saved chart/dashboard',
|
|
28
|
+
priority: 0.75,
|
|
34
29
|
},
|
|
35
30
|
{
|
|
36
31
|
id: 'compare',
|
|
37
32
|
title: 'Content-reader compare playbook',
|
|
38
33
|
description: 'Compare and investigate differences between saved content',
|
|
39
34
|
file: 'compare.md',
|
|
35
|
+
useWhen: 'Comparing definitions or investigating result differences',
|
|
36
|
+
priority: 0.7,
|
|
40
37
|
},
|
|
41
38
|
],
|
|
42
39
|
});
|
|
43
|
-
|
|
40
|
+
var invariants_js_1 = require("../invariants.js");
|
|
41
|
+
Object.defineProperty(exports, "CONTENT_READER_HARD_BANS", { enumerable: true, get: function () { return invariants_js_1.CONTENT_READER_HARD_BANS; } });
|
|
44
42
|
exports.getAllPlaybookMarkdown = playbooks.getAllPlaybookMarkdown;
|
|
45
43
|
exports.CONTENT_READER_CORE_PLAYBOOK = playbooks.CORE_PLAYBOOK;
|
|
46
44
|
exports.CONTENT_READER_TOPIC_PLAYBOOKS = playbooks.TOPIC_PLAYBOOKS;
|
|
45
|
+
exports.CONTENT_READER_TOPIC_META = playbooks.TOPIC_META;
|
|
47
46
|
function registerContentReaderPlaybook(server) {
|
|
48
47
|
playbooks.registerPlaybooks(server);
|
|
49
48
|
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Data-analyst structured prompt invariants (SSOT for capsules + HARD_BANS projection).
|
|
3
|
+
*/
|
|
4
|
+
export declare const DATA_ANALYST_INVARIANTS: readonly [{
|
|
5
|
+
readonly id: "no-mutation";
|
|
6
|
+
readonly short: "Do not mutate Lightdash resources (create/update/delete/move charts or dashboards).";
|
|
7
|
+
}, {
|
|
8
|
+
readonly id: "no-raw-sql-or-drills";
|
|
9
|
+
readonly short: "Do not run raw SQL, tableCalculations, underlying-data drills, or result downloads.";
|
|
10
|
+
}, {
|
|
11
|
+
readonly id: "no-saved-chart-execution";
|
|
12
|
+
readonly short: "Do not execute saved charts (use content-reader) or invent fieldIds.";
|
|
13
|
+
}, {
|
|
14
|
+
readonly id: "no-overstate-coverage";
|
|
15
|
+
readonly short: "Do not present truncated results as complete.";
|
|
16
|
+
}, {
|
|
17
|
+
readonly id: "project-scope";
|
|
18
|
+
readonly short: "Do not run queries outside the resolved project (pass projectUuid or HTTP pin).";
|
|
19
|
+
}];
|
|
20
|
+
export declare const DATA_ANALYST_HARD_BANS: string;
|
|
21
|
+
export declare const DATA_ANALYST_DEFAULT_INVARIANT_IDS: readonly ("project-scope" | "no-mutation" | "no-overstate-coverage" | "no-raw-sql-or-drills" | "no-saved-chart-execution")[];
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Data-analyst structured prompt invariants (SSOT for capsules + HARD_BANS projection).
|
|
4
|
+
*/
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.DATA_ANALYST_DEFAULT_INVARIANT_IDS = exports.DATA_ANALYST_HARD_BANS = exports.DATA_ANALYST_INVARIANTS = void 0;
|
|
7
|
+
const prompt_invariants_js_1 = require("../../lib/prompt-invariants.js");
|
|
8
|
+
exports.DATA_ANALYST_INVARIANTS = [
|
|
9
|
+
{
|
|
10
|
+
id: 'no-mutation',
|
|
11
|
+
short: 'Do not mutate Lightdash resources (create/update/delete/move charts or dashboards).',
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
id: 'no-raw-sql-or-drills',
|
|
15
|
+
short: 'Do not run raw SQL, tableCalculations, underlying-data drills, or result downloads.',
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
id: 'no-saved-chart-execution',
|
|
19
|
+
short: 'Do not execute saved charts (use content-reader) or invent fieldIds.',
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
id: 'no-overstate-coverage',
|
|
23
|
+
short: 'Do not present truncated results as complete.',
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
id: 'project-scope',
|
|
27
|
+
short: 'Do not run queries outside the resolved project (pass projectUuid or HTTP pin).',
|
|
28
|
+
},
|
|
29
|
+
];
|
|
30
|
+
exports.DATA_ANALYST_HARD_BANS = (0, prompt_invariants_js_1.formatHardBansProjection)(exports.DATA_ANALYST_INVARIANTS);
|
|
31
|
+
exports.DATA_ANALYST_DEFAULT_INVARIANT_IDS = (0, prompt_invariants_js_1.allInvariantIds)(exports.DATA_ANALYST_INVARIANTS);
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* MCP prompts for data-analyst workflows.
|
|
2
|
+
* MCP prompts for data-analyst workflows (progressive-disclosure context).
|
|
3
3
|
*/
|
|
4
|
+
import type { RegisterPromptsOptions } from '../../types.js';
|
|
4
5
|
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
|
-
export declare function registerDataAnalystPrompts(server: McpServer): void;
|
|
6
|
+
export declare function registerDataAnalystPrompts(server: McpServer, options?: RegisterPromptsOptions): void;
|
|
@@ -1,19 +1,25 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
/**
|
|
3
|
-
* MCP prompts for data-analyst workflows.
|
|
3
|
+
* MCP prompts for data-analyst workflows (progressive-disclosure context).
|
|
4
4
|
*/
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.registerDataAnalystPrompts = registerDataAnalystPrompts;
|
|
7
7
|
/* eslint-disable @typescript-eslint/no-deprecated -- matches other profile prompt registration pattern */
|
|
8
8
|
const zod_1 = require("zod");
|
|
9
9
|
const schema_fields_js_1 = require("../../../tools/lib/schema-fields.js");
|
|
10
|
-
const
|
|
10
|
+
const prompt_context_js_1 = require("../../lib/prompt-context.js");
|
|
11
|
+
const invariants_js_1 = require("./invariants.js");
|
|
11
12
|
const playbooks_js_1 = require("./resources/playbooks.js");
|
|
12
|
-
const
|
|
13
|
+
const TOPIC_EXPLORE = 'explore';
|
|
14
|
+
const bindPromptContext = (0, prompt_context_js_1.bindProfilePromptContext)({
|
|
15
|
+
invariants: invariants_js_1.DATA_ANALYST_INVARIANTS,
|
|
13
16
|
core: playbooks_js_1.DATA_ANALYST_CORE_PLAYBOOK,
|
|
14
17
|
topics: playbooks_js_1.DATA_ANALYST_TOPIC_PLAYBOOKS,
|
|
18
|
+
topicMeta: playbooks_js_1.DATA_ANALYST_TOPIC_META,
|
|
15
19
|
});
|
|
16
|
-
function registerDataAnalystPrompts(server) {
|
|
20
|
+
function registerDataAnalystPrompts(server, options) {
|
|
21
|
+
const promptContext = bindPromptContext(options === null || options === void 0 ? void 0 : options.promptContextPolicy);
|
|
22
|
+
const invariantIds = invariants_js_1.DATA_ANALYST_DEFAULT_INVARIANT_IDS;
|
|
17
23
|
server.registerPrompt('explore_data', {
|
|
18
24
|
title: 'Explore data',
|
|
19
25
|
description: 'Explore a Lightdash project with unsaved metric queries (dimensions, metrics, filters) — do not save charts',
|
|
@@ -22,13 +28,12 @@ function registerDataAnalystPrompts(server) {
|
|
|
22
28
|
question: zod_1.z.string(),
|
|
23
29
|
exploreHint: zod_1.z.string().optional(),
|
|
24
30
|
},
|
|
25
|
-
}, ({ projectUuid, question, exploreHint }) =>
|
|
31
|
+
}, ({ projectUuid, question, exploreHint }) => promptContext({
|
|
32
|
+
task: `Answer this data question by exploring the semantic layer and running unsaved metric queries:
|
|
26
33
|
|
|
27
34
|
${question}
|
|
28
35
|
|
|
29
|
-
${
|
|
30
|
-
|
|
31
|
-
Project: ${projectUuid !== null && projectUuid !== void 0 ? projectUuid : '(use HTTP pin or ask for projectUuid — PROJECT_SCOPE_REQUIRED otherwise)'}.
|
|
36
|
+
${(0, schema_fields_js_1.formatPromptProjectUuidLine)(projectUuid)}
|
|
32
37
|
Explore hint: ${exploreHint !== null && exploreHint !== void 0 ? exploreHint : '(discover with list_explores search+limit)'}.
|
|
33
38
|
|
|
34
39
|
Procedure:
|
|
@@ -36,6 +41,9 @@ Procedure:
|
|
|
36
41
|
2. list_explores (search+limit≤15) → get_explore → lock exploreName.
|
|
37
42
|
3. Copy fieldIds from list_dimensions / list_metrics (or get_explore base-table metrics). Never invent fieldIds.
|
|
38
43
|
4. Optional compile_query; then run_metric_query with small limit. Poll get_query_result if needed.
|
|
39
|
-
5. Iterate filters/fields. Do not save charts unless the user asks.`,
|
|
44
|
+
5. Iterate filters/fields. Do not save charts unless the user asks.`,
|
|
45
|
+
invariantIds,
|
|
46
|
+
requiredTopics: [TOPIC_EXPLORE],
|
|
47
|
+
}));
|
|
40
48
|
}
|
|
41
49
|
/* eslint-enable @typescript-eslint/no-deprecated */
|
|
@@ -3,8 +3,9 @@
|
|
|
3
3
|
*/
|
|
4
4
|
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
5
|
export type DataAnalystPlaybookTopic = 'explore';
|
|
6
|
-
export
|
|
6
|
+
export { DATA_ANALYST_HARD_BANS } from '../invariants.js';
|
|
7
7
|
export declare const getAllPlaybookMarkdown: () => string;
|
|
8
8
|
export declare const DATA_ANALYST_CORE_PLAYBOOK: import("../../../lib/playbook-resources.js").EmbeddedPlaybook;
|
|
9
9
|
export declare const DATA_ANALYST_TOPIC_PLAYBOOKS: Readonly<Record<"explore", import("../../../lib/playbook-resources.js").EmbeddedPlaybook>>;
|
|
10
|
+
export declare const DATA_ANALYST_TOPIC_META: Readonly<Record<"explore", import("../../../lib/playbook-resources.js").PromptTopicMeta>>;
|
|
10
11
|
export declare function registerDataAnalystPlaybook(server: McpServer): void;
|
|
@@ -3,17 +3,12 @@
|
|
|
3
3
|
* Data-analyst multi-playbook resources (core + explore topic).
|
|
4
4
|
*/
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.DATA_ANALYST_TOPIC_PLAYBOOKS = exports.DATA_ANALYST_CORE_PLAYBOOK = exports.getAllPlaybookMarkdown = exports.DATA_ANALYST_HARD_BANS = void 0;
|
|
6
|
+
exports.DATA_ANALYST_TOPIC_META = exports.DATA_ANALYST_TOPIC_PLAYBOOKS = exports.DATA_ANALYST_CORE_PLAYBOOK = exports.getAllPlaybookMarkdown = exports.DATA_ANALYST_HARD_BANS = void 0;
|
|
7
7
|
exports.registerDataAnalystPlaybook = registerDataAnalystPlaybook;
|
|
8
8
|
const playbook_resources_js_1 = require("../../../lib/playbook-resources.js");
|
|
9
9
|
const playbooks = (0, playbook_resources_js_1.defineProfilePlaybooks)({
|
|
10
10
|
profileId: 'data-analyst',
|
|
11
11
|
moduleDir: __dirname,
|
|
12
|
-
hardBans: `Do not mutate Lightdash resources (create/update/delete/move charts or dashboards).
|
|
13
|
-
Do not run raw SQL, tableCalculations, underlying-data drills, or result downloads.
|
|
14
|
-
Do not execute saved charts (use content-reader) or invent fieldIds.
|
|
15
|
-
Do not present truncated results as complete.
|
|
16
|
-
Do not run queries outside the resolved project (pass projectUuid or HTTP pin).`,
|
|
17
12
|
coreDescription: 'Hard bans, budgets, tools, and project scope',
|
|
18
13
|
topics: [
|
|
19
14
|
{
|
|
@@ -21,13 +16,17 @@ Do not run queries outside the resolved project (pass projectUuid or HTTP pin).`
|
|
|
21
16
|
title: 'Data-analyst explore playbook',
|
|
22
17
|
description: 'Compose and run unsaved metric queries (UI Explore loop)',
|
|
23
18
|
file: 'explore.md',
|
|
19
|
+
useWhen: 'Composing and running unsaved metric queries',
|
|
20
|
+
priority: 0.8,
|
|
24
21
|
},
|
|
25
22
|
],
|
|
26
23
|
});
|
|
27
|
-
|
|
24
|
+
var invariants_js_1 = require("../invariants.js");
|
|
25
|
+
Object.defineProperty(exports, "DATA_ANALYST_HARD_BANS", { enumerable: true, get: function () { return invariants_js_1.DATA_ANALYST_HARD_BANS; } });
|
|
28
26
|
exports.getAllPlaybookMarkdown = playbooks.getAllPlaybookMarkdown;
|
|
29
27
|
exports.DATA_ANALYST_CORE_PLAYBOOK = playbooks.CORE_PLAYBOOK;
|
|
30
28
|
exports.DATA_ANALYST_TOPIC_PLAYBOOKS = playbooks.TOPIC_PLAYBOOKS;
|
|
29
|
+
exports.DATA_ANALYST_TOPIC_META = playbooks.TOPIC_META;
|
|
31
30
|
function registerDataAnalystPlaybook(server) {
|
|
32
31
|
playbooks.registerPlaybooks(server);
|
|
33
32
|
}
|
package/dist/profiles/index.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Shipped MCP profiles (path → definition). No
|
|
2
|
+
* Shipped MCP profiles (path → definition). No free-form PATH env (ADR-0006).
|
|
3
|
+
* HTTP may filter mounts via LIGHTDASH_TOOLS_MCP_PROFILES (ADR-0024); catalog stays complete.
|
|
3
4
|
*/
|
|
4
5
|
import type { ProfileDefinition, ProfileId } from './types.js';
|
|
5
6
|
export type { ProfileDefinition, ProfileId } from './types.js';
|
package/dist/profiles/index.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
/**
|
|
3
|
-
* Shipped MCP profiles (path → definition). No
|
|
3
|
+
* Shipped MCP profiles (path → definition). No free-form PATH env (ADR-0006).
|
|
4
|
+
* HTTP may filter mounts via LIGHTDASH_TOOLS_MCP_PROFILES (ADR-0024); catalog stays complete.
|
|
4
5
|
*/
|
|
5
6
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
7
|
exports.PROFILES = exports.DEFAULT_PROFILE_ID = exports.DATA_ANALYST_PROFILE_PATH = exports.CONTENT_GOVERNANCE_PROFILE_PATH = exports.CONTENT_DEVELOPER_PROFILE_PATH = exports.CONTENT_READER_PROFILE_PATH = exports.ORGANIZATION_AUDIT_PROFILE_PATH = exports.SEMANTIC_LAYER_PROFILE_PATH = exports.AI_AGENT_OPS_PROFILE_PATH = void 0;
|
|
@@ -55,8 +55,9 @@ const index_js_1 = require("./index.js");
|
|
|
55
55
|
});
|
|
56
56
|
(0, vitest_1.it)('content-reader membership and server name', () => {
|
|
57
57
|
const profile = (0, index_js_1.getProfile)('content-reader');
|
|
58
|
-
(0, vitest_1.expect)((0, index_js_1.listToolIds)(profile)).toHaveLength(
|
|
58
|
+
(0, vitest_1.expect)((0, index_js_1.listToolIds)(profile)).toHaveLength(15);
|
|
59
59
|
(0, vitest_1.expect)((0, index_js_1.listToolIds)(profile)).toContain('export_chart_image');
|
|
60
|
+
(0, vitest_1.expect)((0, index_js_1.listToolIds)(profile)).toContain('list_verified_content');
|
|
60
61
|
(0, vitest_1.expect)((0, index_js_1.getProfileServerName)(profile)).toBe('lightdash-mcp-content');
|
|
61
62
|
});
|
|
62
63
|
(0, vitest_1.it)('content-developer membership and short server name', () => {
|