@lightdash-tools/mcp 0.14.0 → 0.17.0
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 +43 -14
- package/dist/auth/oauth-broker/as-metadata.d.ts +6 -2
- package/dist/auth/oauth-broker/as-metadata.js +8 -4
- package/dist/auth/oauth-broker/invoke-origins.d.ts +16 -0
- package/dist/auth/oauth-broker/invoke-origins.js +112 -0
- package/dist/auth/oauth-broker/invoke-origins.test.d.ts +1 -0
- package/dist/auth/oauth-broker/invoke-origins.test.js +82 -0
- 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 +124 -48
- package/dist/auth/oauth-broker/routes.test.js +191 -16
- package/dist/auth/resource-server/lightdash-oauth-middleware.d.ts +3 -1
- package/dist/auth/resource-server/lightdash-oauth-middleware.js +65 -41
- package/dist/auth/resource-server/lightdash-oauth-middleware.test.js +95 -59
- package/dist/auth/resource-server/oauth-protected-resource.d.ts +2 -2
- package/dist/auth/resource-server/oauth-protected-resource.js +8 -11
- package/dist/auth/resource-server/www-authenticate.test.js +3 -3
- package/dist/bin.js +33 -7
- package/dist/config/env.d.ts +10 -0
- package/dist/config/env.js +11 -1
- package/dist/config/load-mcp-config.d.ts +14 -1
- package/dist/config/load-mcp-config.js +35 -8
- package/dist/config/load-mcp-config.test.js +49 -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 +1 -1
- package/dist/governance/mcp-post-factory-context.d.ts +2 -0
- package/dist/http.d.ts +7 -1
- package/dist/http.integration.helpers.d.ts +50 -0
- package/dist/http.integration.helpers.js +190 -0
- package/dist/http.integration.test.js +81 -187
- package/dist/http.invoke-origin.integration.test.d.ts +1 -0
- package/dist/http.invoke-origin.integration.test.js +108 -0
- package/dist/http.js +10 -1
- package/dist/index.d.ts +6 -1
- 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/core.md +1 -0
- 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.d.ts +3 -2
- package/dist/profiles/content-developer/v1/resources/playbooks.js +35 -22
- 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/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 -76
- 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/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/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/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 +13 -4
- package/dist/transports/streamable-http.test.js +8 -3
- package/package.json +3 -3
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Recovery: PREVIEW_STALE
|
|
2
|
+
|
|
3
|
+
URI: `lightdash://playbooks/content-developer/recovery/preview-stale`
|
|
4
|
+
|
|
5
|
+
## When
|
|
6
|
+
|
|
7
|
+
Tool error `PREVIEW_STALE` — content hash mismatch, baseline `updatedAt` drift, create race, or resourceKey/kind mismatch.
|
|
8
|
+
|
|
9
|
+
## Recover
|
|
10
|
+
|
|
11
|
+
1. Stop applying. Do **not** retry the same validated token with a tweaked body.
|
|
12
|
+
2. Re-`preview_*` with the **intended full proposed payload** (same nested `chart`/`dashboard`/`changes` you will apply).
|
|
13
|
+
3. `confirm_preview` with the new draft token + exact `resourceKind` / `resourceKey` + `projectUuid` (required without HTTP pin).
|
|
14
|
+
4. Apply using the **returned** validated token and the **identical** proposed body — no description/name/SQL/tiles tidy between confirm and apply.
|
|
15
|
+
5. Cap retries at **≤2** per resource after `PREVIEW_STALE`.
|
|
16
|
+
|
|
17
|
+
## Common causes
|
|
18
|
+
|
|
19
|
+
- Edited proposed fields after preview (hash mismatch).
|
|
20
|
+
- Resource changed under you (`updatedAt` / create appeared).
|
|
21
|
+
- Create-chart preview omitted top-level `slug` → `resourceKey` mismatch at apply.
|
|
@@ -2,9 +2,10 @@
|
|
|
2
2
|
* Content-developer multi-playbook resources (core + topics + index).
|
|
3
3
|
*/
|
|
4
4
|
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
|
-
export type ContentDeveloperPlaybookTopic = 'chart-types' | 'content-move' | 'dashboard-design' | 'dashboards' | 'table-calculations';
|
|
6
|
-
export
|
|
5
|
+
export type ContentDeveloperPlaybookTopic = 'chart-types' | 'content-move' | 'dashboard-design' | 'dashboards' | 'recovery/dashboard-diff' | 'recovery/preview-required' | 'recovery/preview-stale' | 'table-calculations';
|
|
6
|
+
export { CONTENT_DEVELOPER_HARD_BANS } from '../invariants.js';
|
|
7
7
|
export declare const getAllPlaybookMarkdown: () => string;
|
|
8
8
|
export declare const CONTENT_DEVELOPER_CORE_PLAYBOOK: import("../../../lib/playbook-resources.js").EmbeddedPlaybook;
|
|
9
9
|
export declare const CONTENT_DEVELOPER_TOPIC_PLAYBOOKS: Readonly<Record<ContentDeveloperPlaybookTopic, import("../../../lib/playbook-resources.js").EmbeddedPlaybook>>;
|
|
10
|
+
export declare const CONTENT_DEVELOPER_TOPIC_META: Readonly<Record<ContentDeveloperPlaybookTopic, import("../../../lib/playbook-resources.js").PromptTopicMeta>>;
|
|
10
11
|
export declare function registerContentDeveloperPlaybook(server: McpServer): void;
|
|
@@ -3,32 +3,12 @@
|
|
|
3
3
|
* Content-developer multi-playbook resources (core + topics + index).
|
|
4
4
|
*/
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.CONTENT_DEVELOPER_TOPIC_PLAYBOOKS = exports.CONTENT_DEVELOPER_CORE_PLAYBOOK = exports.getAllPlaybookMarkdown = exports.CONTENT_DEVELOPER_HARD_BANS = void 0;
|
|
6
|
+
exports.CONTENT_DEVELOPER_TOPIC_META = exports.CONTENT_DEVELOPER_TOPIC_PLAYBOOKS = exports.CONTENT_DEVELOPER_CORE_PLAYBOOK = exports.getAllPlaybookMarkdown = exports.CONTENT_DEVELOPER_HARD_BANS = void 0;
|
|
7
7
|
exports.registerContentDeveloperPlaybook = registerContentDeveloperPlaybook;
|
|
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-developer',
|
|
11
11
|
moduleDir: __dirname,
|
|
12
|
-
hardBans: `Do not execute arbitrary metric queries, raw SQL, warehouse runs, or saved-chart execution.
|
|
13
|
-
Do not author or upsert SQL charts.
|
|
14
|
-
Do not hard-delete, rollback, or promote content (use content-governance for promote).
|
|
15
|
-
Do not perform organization administration or list org-wide projects.
|
|
16
|
-
Do not create or update spaces — spaces are Terraform / out-of-band; use existing spaces only.
|
|
17
|
-
Do not create space-only charts for dashboard work — set dashboardSlug to the dashboard shell already created.
|
|
18
|
-
Do not call preview_* or write tools for a new dashboard or a material dashboard redesign until a Design Spec (with settled Objective) was presented and the user approved or amended it in-thread.
|
|
19
|
-
Do not start writes from a viz-type or all-chart-types checklist alone — settle Objective and insight questions first (an explicit user all-types ask may be the Objective after a one-line restatement).
|
|
20
|
-
Do not call confirm_preview without projectUuid when there is no HTTP X-Lightdash-Project pin (PROJECT_SCOPE_REQUIRED).
|
|
21
|
-
Do not attach dashboard filters whose target.tableName is absent from a tile explore without excluding that tile (or remapping) via tileTargets.
|
|
22
|
-
Do not treat chart create as done without a dashboard shell and tiles.
|
|
23
|
-
Do not invent fieldIds — clone via get_chart_as_code / get_chart or use semantic-layer.
|
|
24
|
-
Do not invent skinny chartConfig — clone a working as-code body and keep series/layout/encode.
|
|
25
|
-
Do not set chart verified or dashboard preserveVerification unless the user explicitly asks (verify permission required).
|
|
26
|
-
Do not apply a write tool without a confirmed, unexpired HMAC previewToken from the matching preview_* tool (confirm_preview unlocks every write; use the new validated token).
|
|
27
|
-
Do not mutate the proposed payload after preview_* (description/name/SQL/metrics/tiles) — apply must reuse the identical proposed body or PREVIEW_STALE (content hash mismatch); any edit requires a new preview_*.
|
|
28
|
-
Do not treat validate_chart / validate_dashboard as a preview unlock — they are saved-UUID health checks only (validate_chart needs chartUuid).
|
|
29
|
-
Do not reuse a draft previewToken after confirm; re-run preview if the resource drifts (PREVIEW_STALE).
|
|
30
|
-
Do not use subagent-driven-development or multi-task writing-plans solely to click MCP preview/confirm/apply for lab boards (e.g. experiments) — after Design Spec approval, run Batch SOP inline in the same session.
|
|
31
|
-
Do not reveal secrets, warehouse credentials, or saved SQL chart bodies.`,
|
|
32
12
|
coreDescription: 'Hard bans, tools, project scope, preview gate, and apply pitfalls',
|
|
33
13
|
topics: [
|
|
34
14
|
{
|
|
@@ -36,37 +16,70 @@ Do not reveal secrets, warehouse credentials, or saved SQL chart bodies.`,
|
|
|
36
16
|
title: 'Content-developer dashboards playbook',
|
|
37
17
|
description: 'Dashboard shell first, then dashboardSlug-scoped charts as tiles',
|
|
38
18
|
file: 'dashboards.md',
|
|
19
|
+
useWhen: 'Creating or updating dashboard shells, tiles, or dashboardSlug-scoped charts',
|
|
20
|
+
priority: 0.8,
|
|
39
21
|
},
|
|
40
22
|
{
|
|
41
23
|
id: 'dashboard-design',
|
|
42
24
|
title: 'Content-developer dashboard-design playbook',
|
|
43
25
|
description: 'Objective-first Design Spec, explore↔filter / tileTargets, layout, markdown, filters, tabs',
|
|
44
26
|
file: 'dashboard-design.md',
|
|
27
|
+
useWhen: 'Design Spec, layout, markdown tiles, filters, or tileTargets planning',
|
|
28
|
+
priority: 0.8,
|
|
45
29
|
},
|
|
46
30
|
{
|
|
47
31
|
id: 'chart-types',
|
|
48
32
|
title: 'Content-developer chart-types playbook',
|
|
49
33
|
description: 'Insight-first viz pick; cartesian encode checklist; UI intent → as-code map',
|
|
50
34
|
file: 'chart-types.md',
|
|
35
|
+
useWhen: 'Choosing or cloning chart types / cartesian encode',
|
|
36
|
+
priority: 0.75,
|
|
51
37
|
},
|
|
52
38
|
{
|
|
53
39
|
id: 'table-calculations',
|
|
54
40
|
title: 'Content-developer table-calculations playbook',
|
|
55
41
|
description: 'metricQuery.tableCalculations: template → formula → sql; PoP, % of total, rank, windows',
|
|
56
42
|
file: 'table-calculations.md',
|
|
43
|
+
useWhen: 'Authoring table calculations, PoP, or window helpers',
|
|
44
|
+
priority: 0.7,
|
|
57
45
|
},
|
|
58
46
|
{
|
|
59
47
|
id: 'content-move',
|
|
60
48
|
title: 'Content-developer content-move playbook',
|
|
61
49
|
description: 'Move content into existing spaces (no space CRUD)',
|
|
62
50
|
file: 'content-move.md',
|
|
51
|
+
useWhen: 'Moving charts/dashboards into existing spaces',
|
|
52
|
+
priority: 0.7,
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
id: 'recovery/preview-stale',
|
|
56
|
+
title: 'Content-developer PREVIEW_STALE recovery',
|
|
57
|
+
description: 'Recover from PREVIEW_STALE (hash mismatch or baseline drift)',
|
|
58
|
+
file: 'recovery/preview-stale.md',
|
|
59
|
+
useWhen: 'After PREVIEW_STALE (hash mismatch or baseline drift)',
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
id: 'recovery/preview-required',
|
|
63
|
+
title: 'Content-developer PREVIEW_REQUIRED recovery',
|
|
64
|
+
description: 'Recover when preview token is missing, invalid, or expired',
|
|
65
|
+
file: 'recovery/preview-required.md',
|
|
66
|
+
useWhen: 'After PREVIEW_REQUIRED (missing, invalid, or expired token)',
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
id: 'recovery/dashboard-diff',
|
|
70
|
+
title: 'Content-developer dashboard diff recovery',
|
|
71
|
+
description: 'Interpret dashboard preview diff.removed noise vs real omissions',
|
|
72
|
+
file: 'recovery/dashboard-diff.md',
|
|
73
|
+
useWhen: 'When interpreting dashboard preview diff.removed noise vs omissions',
|
|
63
74
|
},
|
|
64
75
|
],
|
|
65
76
|
});
|
|
66
|
-
|
|
77
|
+
var invariants_js_1 = require("../invariants.js");
|
|
78
|
+
Object.defineProperty(exports, "CONTENT_DEVELOPER_HARD_BANS", { enumerable: true, get: function () { return invariants_js_1.CONTENT_DEVELOPER_HARD_BANS; } });
|
|
67
79
|
exports.getAllPlaybookMarkdown = playbooks.getAllPlaybookMarkdown;
|
|
68
80
|
exports.CONTENT_DEVELOPER_CORE_PLAYBOOK = playbooks.CORE_PLAYBOOK;
|
|
69
81
|
exports.CONTENT_DEVELOPER_TOPIC_PLAYBOOKS = playbooks.TOPIC_PLAYBOOKS;
|
|
82
|
+
exports.CONTENT_DEVELOPER_TOPIC_META = playbooks.TOPIC_META;
|
|
70
83
|
function registerContentDeveloperPlaybook(server) {
|
|
71
84
|
playbooks.registerPlaybooks(server);
|
|
72
85
|
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Content-governance structured prompt invariants (SSOT for capsules + HARD_BANS projection).
|
|
3
|
+
*/
|
|
4
|
+
export declare const CONTENT_GOVERNANCE_INVARIANTS: readonly [{
|
|
5
|
+
readonly id: "no-permanent-purge";
|
|
6
|
+
readonly short: "Do not permanently purge soft-deleted content.";
|
|
7
|
+
}, {
|
|
8
|
+
readonly id: "no-space-or-bulk-delete";
|
|
9
|
+
readonly short: "Do not delete spaces or perform bulk delete.";
|
|
10
|
+
}, {
|
|
11
|
+
readonly id: "elicitation-required";
|
|
12
|
+
readonly short: "Do not soft-delete or promote without form elicitation (never invent confirmed: true or chat-only approval).";
|
|
13
|
+
}, {
|
|
14
|
+
readonly id: "no-bypass-elicitation";
|
|
15
|
+
readonly short: "Do not expose deletes/promote on other profiles or bypass the elicitation gate.";
|
|
16
|
+
}, {
|
|
17
|
+
readonly id: "dashboard-first-promote";
|
|
18
|
+
readonly short: "Do not promote charts or SQL charts via MCP (dashboard-first only).";
|
|
19
|
+
}, {
|
|
20
|
+
readonly id: "no-restore-or-query";
|
|
21
|
+
readonly short: "Do not restore, author, or execute warehouse queries from this profile.";
|
|
22
|
+
}, {
|
|
23
|
+
readonly id: "no-secrets";
|
|
24
|
+
readonly short: "Do not reveal secrets, warehouse credentials, or hidden SQL.";
|
|
25
|
+
}];
|
|
26
|
+
export declare const CONTENT_GOVERNANCE_HARD_BANS: string;
|
|
27
|
+
export declare const CONTENT_GOVERNANCE_DEFAULT_INVARIANT_IDS: readonly ("no-secrets" | "no-permanent-purge" | "no-space-or-bulk-delete" | "elicitation-required" | "no-bypass-elicitation" | "dashboard-first-promote" | "no-restore-or-query")[];
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Content-governance structured prompt invariants (SSOT for capsules + HARD_BANS projection).
|
|
4
|
+
*/
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.CONTENT_GOVERNANCE_DEFAULT_INVARIANT_IDS = exports.CONTENT_GOVERNANCE_HARD_BANS = exports.CONTENT_GOVERNANCE_INVARIANTS = void 0;
|
|
7
|
+
const prompt_invariants_js_1 = require("../../lib/prompt-invariants.js");
|
|
8
|
+
exports.CONTENT_GOVERNANCE_INVARIANTS = [
|
|
9
|
+
{
|
|
10
|
+
id: 'no-permanent-purge',
|
|
11
|
+
short: 'Do not permanently purge soft-deleted content.',
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
id: 'no-space-or-bulk-delete',
|
|
15
|
+
short: 'Do not delete spaces or perform bulk delete.',
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
id: 'elicitation-required',
|
|
19
|
+
short: 'Do not soft-delete or promote without form elicitation (never invent confirmed: true or chat-only approval).',
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
id: 'no-bypass-elicitation',
|
|
23
|
+
short: 'Do not expose deletes/promote on other profiles or bypass the elicitation gate.',
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
id: 'dashboard-first-promote',
|
|
27
|
+
short: 'Do not promote charts or SQL charts via MCP (dashboard-first only).',
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
id: 'no-restore-or-query',
|
|
31
|
+
short: 'Do not restore, author, or execute warehouse queries from this profile.',
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
id: 'no-secrets',
|
|
35
|
+
short: 'Do not reveal secrets, warehouse credentials, or hidden SQL.',
|
|
36
|
+
},
|
|
37
|
+
];
|
|
38
|
+
exports.CONTENT_GOVERNANCE_HARD_BANS = (0, prompt_invariants_js_1.formatHardBansProjection)(exports.CONTENT_GOVERNANCE_INVARIANTS);
|
|
39
|
+
exports.CONTENT_GOVERNANCE_DEFAULT_INVARIANT_IDS = (0, prompt_invariants_js_1.allInvariantIds)(exports.CONTENT_GOVERNANCE_INVARIANTS);
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* MCP prompts for content-governance soft-delete and dashboard promote workflows
|
|
2
|
+
* MCP prompts for content-governance soft-delete and dashboard promote workflows
|
|
3
|
+
* (progressive-disclosure context).
|
|
3
4
|
*/
|
|
5
|
+
import type { RegisterPromptsOptions } from '../../types.js';
|
|
4
6
|
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
|
-
export declare function registerContentGovernancePrompts(server: McpServer): void;
|
|
7
|
+
export declare function registerContentGovernancePrompts(server: McpServer, options?: RegisterPromptsOptions): void;
|
|
@@ -1,17 +1,15 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
/**
|
|
3
|
-
* MCP prompts for content-governance soft-delete and dashboard promote workflows
|
|
3
|
+
* MCP prompts for content-governance soft-delete and dashboard promote workflows
|
|
4
|
+
* (progressive-disclosure context).
|
|
4
5
|
*/
|
|
5
6
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
7
|
exports.registerContentGovernancePrompts = registerContentGovernancePrompts;
|
|
7
8
|
/* eslint-disable @typescript-eslint/no-deprecated -- matches content-reader prompt registration pattern */
|
|
8
9
|
const zod_1 = require("zod");
|
|
9
|
-
const
|
|
10
|
+
const prompt_context_js_1 = require("../../lib/prompt-context.js");
|
|
11
|
+
const invariants_js_1 = require("./invariants.js");
|
|
10
12
|
const playbooks_js_1 = require("./resources/playbooks.js");
|
|
11
|
-
const userMessages = (0, playbook_resources_js_1.createPromptPlaybookEmbedder)({
|
|
12
|
-
core: playbooks_js_1.CONTENT_GOVERNANCE_CORE_PLAYBOOK,
|
|
13
|
-
topics: playbooks_js_1.CONTENT_GOVERNANCE_TOPIC_PLAYBOOKS,
|
|
14
|
-
});
|
|
15
13
|
const TOPIC_CHARTS = 'charts';
|
|
16
14
|
const TOPIC_DASHBOARDS = 'dashboards';
|
|
17
15
|
const REASON_NONE = '(none provided)';
|
|
@@ -25,7 +23,15 @@ first, then lightdash_promote_dashboard. The human must accept a form with decis
|
|
|
25
23
|
and confirmationText equal to the exact dashboard name. Never invent confirmation flags.
|
|
26
24
|
If the client lacks form elicitation, expect ELICITATION_REQUIRED and stop.
|
|
27
25
|
If the dashboard or promoteDiff drifts after binding, expect RESOURCE_CHANGED and re-invoke.`;
|
|
28
|
-
|
|
26
|
+
const bindPromptContext = (0, prompt_context_js_1.bindProfilePromptContext)({
|
|
27
|
+
invariants: invariants_js_1.CONTENT_GOVERNANCE_INVARIANTS,
|
|
28
|
+
core: playbooks_js_1.CONTENT_GOVERNANCE_CORE_PLAYBOOK,
|
|
29
|
+
topics: playbooks_js_1.CONTENT_GOVERNANCE_TOPIC_PLAYBOOKS,
|
|
30
|
+
topicMeta: playbooks_js_1.CONTENT_GOVERNANCE_TOPIC_META,
|
|
31
|
+
});
|
|
32
|
+
function registerContentGovernancePrompts(server, options) {
|
|
33
|
+
const promptContext = bindPromptContext(options === null || options === void 0 ? void 0 : options.promptContextPolicy);
|
|
34
|
+
const invariantIds = invariants_js_1.CONTENT_GOVERNANCE_DEFAULT_INVARIANT_IDS;
|
|
29
35
|
server.registerPrompt('delete_chart', {
|
|
30
36
|
title: 'Soft-delete chart',
|
|
31
37
|
description: 'Soft-delete a saved chart after form elicitation (restorable from trash; no permanent purge)',
|
|
@@ -33,9 +39,8 @@ function registerContentGovernancePrompts(server) {
|
|
|
33
39
|
chartUuidOrSlug: zod_1.z.string(),
|
|
34
40
|
reason: zod_1.z.string().optional(),
|
|
35
41
|
},
|
|
36
|
-
}, ({ chartUuidOrSlug, reason }) =>
|
|
37
|
-
|
|
38
|
-
${playbooks_js_1.CONTENT_GOVERNANCE_HARD_BANS}
|
|
42
|
+
}, ({ chartUuidOrSlug, reason }) => promptContext({
|
|
43
|
+
task: `Soft-delete the Lightdash chart ${chartUuidOrSlug}.
|
|
39
44
|
|
|
40
45
|
${DELETE_ELICITATION_RULES}
|
|
41
46
|
|
|
@@ -44,7 +49,10 @@ Resolve project scope (X-Lightdash-Project pin or projectUuid), then call
|
|
|
44
49
|
lightdash_delete_chart with chartUuidOrSlug.
|
|
45
50
|
Complete human form fields: decision (confirm_delete | do_not_delete) and confirmationText
|
|
46
51
|
(exact chart name). Report the deletion receipt or that nothing was deleted if declined/cancelled.
|
|
47
|
-
Do not permanently purge.`,
|
|
52
|
+
Do not permanently purge.`,
|
|
53
|
+
invariantIds,
|
|
54
|
+
requiredTopics: [TOPIC_CHARTS],
|
|
55
|
+
}));
|
|
48
56
|
server.registerPrompt('delete_dashboard', {
|
|
49
57
|
title: 'Soft-delete dashboard',
|
|
50
58
|
description: 'Soft-delete a dashboard after form elicitation (restorable from trash; no permanent purge)',
|
|
@@ -52,9 +60,8 @@ Do not permanently purge.`, TOPIC_CHARTS));
|
|
|
52
60
|
dashboardUuidOrSlug: zod_1.z.string(),
|
|
53
61
|
reason: zod_1.z.string().optional(),
|
|
54
62
|
},
|
|
55
|
-
}, ({ dashboardUuidOrSlug, reason }) =>
|
|
56
|
-
|
|
57
|
-
${playbooks_js_1.CONTENT_GOVERNANCE_HARD_BANS}
|
|
63
|
+
}, ({ dashboardUuidOrSlug, reason }) => promptContext({
|
|
64
|
+
task: `Soft-delete the Lightdash dashboard ${dashboardUuidOrSlug}.
|
|
58
65
|
|
|
59
66
|
${DELETE_ELICITATION_RULES}
|
|
60
67
|
|
|
@@ -63,7 +70,10 @@ Resolve project scope (X-Lightdash-Project pin or projectUuid), then call
|
|
|
63
70
|
lightdash_delete_dashboard with dashboardUuidOrSlug.
|
|
64
71
|
Complete human form fields: decision (confirm_delete | do_not_delete) and confirmationText
|
|
65
72
|
(exact dashboard name). Report the deletion receipt or that nothing was deleted if declined/cancelled.
|
|
66
|
-
Do not permanently purge, delete spaces, or bulk-delete.`,
|
|
73
|
+
Do not permanently purge, delete spaces, or bulk-delete.`,
|
|
74
|
+
invariantIds,
|
|
75
|
+
requiredTopics: [TOPIC_DASHBOARDS],
|
|
76
|
+
}));
|
|
67
77
|
server.registerPrompt('promote_dashboard', {
|
|
68
78
|
title: 'Promote dashboard',
|
|
69
79
|
description: 'Promote a dashboard to its configured upstream project after form elicitation (dashboard-first release)',
|
|
@@ -71,9 +81,8 @@ Do not permanently purge, delete spaces, or bulk-delete.`, TOPIC_DASHBOARDS));
|
|
|
71
81
|
dashboardUuidOrSlug: zod_1.z.string(),
|
|
72
82
|
reason: zod_1.z.string().optional(),
|
|
73
83
|
},
|
|
74
|
-
}, ({ dashboardUuidOrSlug, reason }) =>
|
|
75
|
-
|
|
76
|
-
${playbooks_js_1.CONTENT_GOVERNANCE_HARD_BANS}
|
|
84
|
+
}, ({ dashboardUuidOrSlug, reason }) => promptContext({
|
|
85
|
+
task: `Promote the Lightdash dashboard ${dashboardUuidOrSlug} to its configured upstream project.
|
|
77
86
|
|
|
78
87
|
${PROMOTE_ELICITATION_RULES}
|
|
79
88
|
|
|
@@ -82,6 +91,9 @@ Resolve project scope, optionally call lightdash_get_dashboard_promote_diff, the
|
|
|
82
91
|
lightdash_promote_dashboard with dashboardUuidOrSlug.
|
|
83
92
|
Complete human form fields: decision (confirm_promote | do_not_promote) and confirmationText
|
|
84
93
|
(exact dashboard name). Report the promotion receipt or that nothing was promoted if declined/cancelled.
|
|
85
|
-
Do not promote charts or SQL charts via MCP.`,
|
|
94
|
+
Do not promote charts or SQL charts via MCP.`,
|
|
95
|
+
invariantIds,
|
|
96
|
+
requiredTopics: [TOPIC_DASHBOARDS],
|
|
97
|
+
}));
|
|
86
98
|
}
|
|
87
99
|
/* eslint-enable @typescript-eslint/no-deprecated */
|
|
@@ -3,8 +3,9 @@
|
|
|
3
3
|
*/
|
|
4
4
|
import type { McpServer } from '@modelcontextprotocol/server';
|
|
5
5
|
export type ContentGovernancePlaybookTopic = 'charts' | 'dashboards';
|
|
6
|
-
export
|
|
6
|
+
export { CONTENT_GOVERNANCE_HARD_BANS } from '../invariants.js';
|
|
7
7
|
export declare const getAllPlaybookMarkdown: () => string;
|
|
8
8
|
export declare const CONTENT_GOVERNANCE_CORE_PLAYBOOK: import("../../../lib/playbook-resources.js").EmbeddedPlaybook;
|
|
9
9
|
export declare const CONTENT_GOVERNANCE_TOPIC_PLAYBOOKS: Readonly<Record<ContentGovernancePlaybookTopic, import("../../../lib/playbook-resources.js").EmbeddedPlaybook>>;
|
|
10
|
+
export declare const CONTENT_GOVERNANCE_TOPIC_META: Readonly<Record<ContentGovernancePlaybookTopic, import("../../../lib/playbook-resources.js").PromptTopicMeta>>;
|
|
10
11
|
export declare function registerContentGovernancePlaybook(server: McpServer): void;
|
|
@@ -3,19 +3,12 @@
|
|
|
3
3
|
* Content-governance multi-playbook resources (core + topics + index).
|
|
4
4
|
*/
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.CONTENT_GOVERNANCE_TOPIC_PLAYBOOKS = exports.CONTENT_GOVERNANCE_CORE_PLAYBOOK = exports.getAllPlaybookMarkdown = exports.CONTENT_GOVERNANCE_HARD_BANS = void 0;
|
|
6
|
+
exports.CONTENT_GOVERNANCE_TOPIC_META = exports.CONTENT_GOVERNANCE_TOPIC_PLAYBOOKS = exports.CONTENT_GOVERNANCE_CORE_PLAYBOOK = exports.getAllPlaybookMarkdown = exports.CONTENT_GOVERNANCE_HARD_BANS = void 0;
|
|
7
7
|
exports.registerContentGovernancePlaybook = registerContentGovernancePlaybook;
|
|
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-governance',
|
|
11
11
|
moduleDir: __dirname,
|
|
12
|
-
hardBans: `Do not permanently purge soft-deleted content.
|
|
13
|
-
Do not delete spaces or perform bulk delete.
|
|
14
|
-
Do not soft-delete or promote without form elicitation (never invent confirmed: true or chat-only approval).
|
|
15
|
-
Do not expose deletes/promote on other profiles or bypass the elicitation gate.
|
|
16
|
-
Do not promote charts or SQL charts via MCP (dashboard-first only).
|
|
17
|
-
Do not restore, author, or execute warehouse queries from this profile.
|
|
18
|
-
Do not reveal secrets, warehouse credentials, or hidden SQL.`,
|
|
19
12
|
coreDescription: 'Hard bans, elicitation SOP, tools, and project scope',
|
|
20
13
|
topics: [
|
|
21
14
|
{
|
|
@@ -23,19 +16,25 @@ Do not reveal secrets, warehouse credentials, or hidden SQL.`,
|
|
|
23
16
|
title: 'Content-governance charts playbook',
|
|
24
17
|
description: 'Soft-delete a saved chart with form elicitation',
|
|
25
18
|
file: 'charts.md',
|
|
19
|
+
useWhen: 'Soft-deleting a saved chart with form elicitation',
|
|
20
|
+
priority: 0.8,
|
|
26
21
|
},
|
|
27
22
|
{
|
|
28
23
|
id: 'dashboards',
|
|
29
24
|
title: 'Content-governance dashboards playbook',
|
|
30
25
|
description: 'Soft-delete or promote a dashboard with form elicitation',
|
|
31
26
|
file: 'dashboards.md',
|
|
27
|
+
useWhen: 'Soft-deleting or promoting a dashboard with form elicitation',
|
|
28
|
+
priority: 0.75,
|
|
32
29
|
},
|
|
33
30
|
],
|
|
34
31
|
});
|
|
35
|
-
|
|
32
|
+
var invariants_js_1 = require("../invariants.js");
|
|
33
|
+
Object.defineProperty(exports, "CONTENT_GOVERNANCE_HARD_BANS", { enumerable: true, get: function () { return invariants_js_1.CONTENT_GOVERNANCE_HARD_BANS; } });
|
|
36
34
|
exports.getAllPlaybookMarkdown = playbooks.getAllPlaybookMarkdown;
|
|
37
35
|
exports.CONTENT_GOVERNANCE_CORE_PLAYBOOK = playbooks.CORE_PLAYBOOK;
|
|
38
36
|
exports.CONTENT_GOVERNANCE_TOPIC_PLAYBOOKS = playbooks.TOPIC_PLAYBOOKS;
|
|
37
|
+
exports.CONTENT_GOVERNANCE_TOPIC_META = playbooks.TOPIC_META;
|
|
39
38
|
function registerContentGovernancePlaybook(server) {
|
|
40
39
|
playbooks.registerPlaybooks(server);
|
|
41
40
|
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Content-reader structured prompt invariants (SSOT for capsules + HARD_BANS projection).
|
|
3
|
+
*/
|
|
4
|
+
export declare const CONTENT_READER_INVARIANTS: readonly [{
|
|
5
|
+
readonly id: "no-mutation";
|
|
6
|
+
readonly short: "Do not mutate Lightdash resources.";
|
|
7
|
+
}, {
|
|
8
|
+
readonly id: "no-arbitrary-query";
|
|
9
|
+
readonly short: "Do not execute arbitrary metric queries, raw SQL, or underlying-data queries.";
|
|
10
|
+
}, {
|
|
11
|
+
readonly id: "no-bulk-export";
|
|
12
|
+
readonly short: "Do not download or bulk-export results.";
|
|
13
|
+
}, {
|
|
14
|
+
readonly id: "no-sql-chart-execution";
|
|
15
|
+
readonly short: "Do not execute saved SQL charts (disabled by default on content-reader).";
|
|
16
|
+
}, {
|
|
17
|
+
readonly id: "no-override-semantics";
|
|
18
|
+
readonly short: "Do not override filter targets, operators, required-filter behavior, fields, metrics, dimensions, SQL, table calculations, or sorts.";
|
|
19
|
+
}, {
|
|
20
|
+
readonly id: "project-scope";
|
|
21
|
+
readonly short: "Do not execute content outside the resolved project (pass projectUuid or HTTP pin).";
|
|
22
|
+
}, {
|
|
23
|
+
readonly id: "no-overstate-coverage";
|
|
24
|
+
readonly short: "Do not present truncated results as complete.";
|
|
25
|
+
}, {
|
|
26
|
+
readonly id: "no-label-equivalence";
|
|
27
|
+
readonly short: "Do not claim metric equivalence from matching labels alone.";
|
|
28
|
+
}, {
|
|
29
|
+
readonly id: "no-secrets";
|
|
30
|
+
readonly short: "Do not reveal secrets, warehouse credentials, hidden SQL, or inaccessible content.";
|
|
31
|
+
}];
|
|
32
|
+
export declare const CONTENT_READER_HARD_BANS: string;
|
|
33
|
+
export declare const CONTENT_READER_DEFAULT_INVARIANT_IDS: readonly ("project-scope" | "no-secrets" | "no-mutation" | "no-arbitrary-query" | "no-bulk-export" | "no-sql-chart-execution" | "no-override-semantics" | "no-overstate-coverage" | "no-label-equivalence")[];
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Content-reader structured prompt invariants (SSOT for capsules + HARD_BANS projection).
|
|
4
|
+
*/
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.CONTENT_READER_DEFAULT_INVARIANT_IDS = exports.CONTENT_READER_HARD_BANS = exports.CONTENT_READER_INVARIANTS = void 0;
|
|
7
|
+
const prompt_invariants_js_1 = require("../../lib/prompt-invariants.js");
|
|
8
|
+
exports.CONTENT_READER_INVARIANTS = [
|
|
9
|
+
{
|
|
10
|
+
id: 'no-mutation',
|
|
11
|
+
short: 'Do not mutate Lightdash resources.',
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
id: 'no-arbitrary-query',
|
|
15
|
+
short: 'Do not execute arbitrary metric queries, raw SQL, or underlying-data queries.',
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
id: 'no-bulk-export',
|
|
19
|
+
short: 'Do not download or bulk-export results.',
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
id: 'no-sql-chart-execution',
|
|
23
|
+
short: 'Do not execute saved SQL charts (disabled by default on content-reader).',
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
id: 'no-override-semantics',
|
|
27
|
+
short: 'Do not override filter targets, operators, required-filter behavior, fields, metrics, dimensions, SQL, table calculations, or sorts.',
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
id: 'project-scope',
|
|
31
|
+
short: 'Do not execute content outside the resolved project (pass projectUuid or HTTP pin).',
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
id: 'no-overstate-coverage',
|
|
35
|
+
short: 'Do not present truncated results as complete.',
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
id: 'no-label-equivalence',
|
|
39
|
+
short: 'Do not claim metric equivalence from matching labels alone.',
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
id: 'no-secrets',
|
|
43
|
+
short: 'Do not reveal secrets, warehouse credentials, hidden SQL, or inaccessible content.',
|
|
44
|
+
},
|
|
45
|
+
];
|
|
46
|
+
exports.CONTENT_READER_HARD_BANS = (0, prompt_invariants_js_1.formatHardBansProjection)(exports.CONTENT_READER_INVARIANTS);
|
|
47
|
+
exports.CONTENT_READER_DEFAULT_INVARIANT_IDS = (0, prompt_invariants_js_1.allInvariantIds)(exports.CONTENT_READER_INVARIANTS);
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Pure PromptContextSpec builders for content-reader prompts.
|
|
3
|
+
* Shared by registerContentReaderPrompts and budget gates.
|
|
4
|
+
*/
|
|
5
|
+
import type { ContentReaderPlaybookTopic } from './resources/playbooks.js';
|
|
6
|
+
import type { PromptContextSpec } from '../../lib/prompt-context.js';
|
|
7
|
+
export declare const TOPIC_DISCOVER: "discover";
|
|
8
|
+
export type FindContentPromptArgs = {
|
|
9
|
+
question: string;
|
|
10
|
+
projectUuid?: string;
|
|
11
|
+
contentTypes?: string;
|
|
12
|
+
verifiedOnly?: boolean;
|
|
13
|
+
spaceUuid?: string;
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* Production PromptContextSpec for `find_content` (task + discover topic).
|
|
17
|
+
*/
|
|
18
|
+
export declare function buildFindContentPromptSpec(args: FindContentPromptArgs): PromptContextSpec<ContentReaderPlaybookTopic>;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Pure PromptContextSpec builders for content-reader prompts.
|
|
4
|
+
* Shared by registerContentReaderPrompts and budget gates.
|
|
5
|
+
*/
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.TOPIC_DISCOVER = void 0;
|
|
8
|
+
exports.buildFindContentPromptSpec = buildFindContentPromptSpec;
|
|
9
|
+
const schema_fields_js_1 = require("../../../tools/lib/schema-fields.js");
|
|
10
|
+
const invariants_js_1 = require("./invariants.js");
|
|
11
|
+
exports.TOPIC_DISCOVER = 'discover';
|
|
12
|
+
/**
|
|
13
|
+
* Production PromptContextSpec for `find_content` (task + discover topic).
|
|
14
|
+
*/
|
|
15
|
+
function buildFindContentPromptSpec(args) {
|
|
16
|
+
const { projectUuid, question, contentTypes, verifiedOnly, spaceUuid } = args;
|
|
17
|
+
return {
|
|
18
|
+
task: `Find the most relevant Lightdash content for:
|
|
19
|
+
|
|
20
|
+
${question}
|
|
21
|
+
|
|
22
|
+
${(0, schema_fields_js_1.formatPromptProjectUuidLine)(projectUuid)}
|
|
23
|
+
Content types hint: ${contentTypes !== null && contentTypes !== void 0 ? contentTypes : '(any)'}.
|
|
24
|
+
Verified preference: ${verifiedOnly !== null && verifiedOnly !== void 0 ? verifiedOnly : false} (when true, call list_verified_content first — search_content does not filter by verification).
|
|
25
|
+
Space filter: ${spaceUuid !== null && spaceUuid !== void 0 ? spaceUuid : '(none)'}.
|
|
26
|
+
|
|
27
|
+
Workflow:
|
|
28
|
+
resolve project → verified-first when requested → search → rank → return ≤5 candidates.
|
|
29
|
+
Do not execute unless values were requested.`,
|
|
30
|
+
invariantIds: invariants_js_1.CONTENT_READER_DEFAULT_INVARIANT_IDS,
|
|
31
|
+
requiredTopics: [exports.TOPIC_DISCOVER],
|
|
32
|
+
};
|
|
33
|
+
}
|
|
@@ -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;
|