@meltstudio/meltctl 4.150.1 → 4.151.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/dist/index.js +32 -68
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -14,7 +14,7 @@ var CLI_VERSION;
|
|
|
14
14
|
var init_version = __esm({
|
|
15
15
|
"src/utils/version.ts"() {
|
|
16
16
|
"use strict";
|
|
17
|
-
CLI_VERSION = "4.
|
|
17
|
+
CLI_VERSION = "4.151.0";
|
|
18
18
|
}
|
|
19
19
|
});
|
|
20
20
|
|
|
@@ -1014,23 +1014,15 @@ function createPmResource(config) {
|
|
|
1014
1014
|
const res = await apiFetch(config, `/pm/project-settings/${projectId}`, { method: "PATCH", body: JSON.stringify(input3) });
|
|
1015
1015
|
return unwrap("update project settings", res);
|
|
1016
1016
|
},
|
|
1017
|
-
// ─── Audit flags ──────────────────────────────────────────────────────
|
|
1018
|
-
async listAuditFlags(projectId, status = "open") {
|
|
1019
|
-
const res = await apiFetch(config, `/pm/project-audit-flags?projectId=${projectId}&status=${status}`);
|
|
1020
|
-
return unwrap("list audit flags", res);
|
|
1021
|
-
},
|
|
1022
1017
|
/**
|
|
1023
|
-
*
|
|
1024
|
-
*
|
|
1025
|
-
*
|
|
1018
|
+
* Read-only project context for the audit skill + other dev-callable
|
|
1019
|
+
* tools (#464). Auth-only (no manager check) so devs can call it from
|
|
1020
|
+
* their own MCP session. Returns project identity + canonical stage
|
|
1021
|
+
* without paying for the full health composition.
|
|
1026
1022
|
*/
|
|
1027
|
-
async
|
|
1028
|
-
const res = await apiFetch(config, `/pm/project-
|
|
1029
|
-
return unwrap("
|
|
1030
|
-
},
|
|
1031
|
-
async getAuditCatalog() {
|
|
1032
|
-
const res = await apiFetch(config, `/pm/project-audit-catalog`);
|
|
1033
|
-
return unwrap("get audit catalog", res);
|
|
1023
|
+
async getProjectContext(projectId) {
|
|
1024
|
+
const res = await apiFetch(config, `/pm/project-context/${projectId}`);
|
|
1025
|
+
return unwrap("get project context", res);
|
|
1034
1026
|
},
|
|
1035
1027
|
// ─── Risk-board mappings ──────────────────────────────────────────────
|
|
1036
1028
|
/**
|
|
@@ -3852,23 +3844,15 @@ function createPmResource2(config) {
|
|
|
3852
3844
|
const res = await apiFetch2(config, `/pm/project-settings/${projectId}`, { method: "PATCH", body: JSON.stringify(input3) });
|
|
3853
3845
|
return unwrap2("update project settings", res);
|
|
3854
3846
|
},
|
|
3855
|
-
// ─── Audit flags ──────────────────────────────────────────────────────
|
|
3856
|
-
async listAuditFlags(projectId, status = "open") {
|
|
3857
|
-
const res = await apiFetch2(config, `/pm/project-audit-flags?projectId=${projectId}&status=${status}`);
|
|
3858
|
-
return unwrap2("list audit flags", res);
|
|
3859
|
-
},
|
|
3860
3847
|
/**
|
|
3861
|
-
*
|
|
3862
|
-
*
|
|
3863
|
-
*
|
|
3848
|
+
* Read-only project context for the audit skill + other dev-callable
|
|
3849
|
+
* tools (#464). Auth-only (no manager check) so devs can call it from
|
|
3850
|
+
* their own MCP session. Returns project identity + canonical stage
|
|
3851
|
+
* without paying for the full health composition.
|
|
3864
3852
|
*/
|
|
3865
|
-
async
|
|
3866
|
-
const res = await apiFetch2(config, `/pm/project-
|
|
3867
|
-
return unwrap2("
|
|
3868
|
-
},
|
|
3869
|
-
async getAuditCatalog() {
|
|
3870
|
-
const res = await apiFetch2(config, `/pm/project-audit-catalog`);
|
|
3871
|
-
return unwrap2("get audit catalog", res);
|
|
3853
|
+
async getProjectContext(projectId) {
|
|
3854
|
+
const res = await apiFetch2(config, `/pm/project-context/${projectId}`);
|
|
3855
|
+
return unwrap2("get project context", res);
|
|
3872
3856
|
},
|
|
3873
3857
|
// ─── Risk-board mappings ──────────────────────────────────────────────
|
|
3874
3858
|
/**
|
|
@@ -4525,6 +4509,9 @@ async function listProjects(client) {
|
|
|
4525
4509
|
async function getProjectSettings(client, input3) {
|
|
4526
4510
|
return safe(() => client.pm.getProjectSettings(input3.projectId));
|
|
4527
4511
|
}
|
|
4512
|
+
async function getProjectContext(client, input3) {
|
|
4513
|
+
return safe(() => client.pm.getProjectContext(input3.projectId));
|
|
4514
|
+
}
|
|
4528
4515
|
function registerProjectTools(server, getClient2) {
|
|
4529
4516
|
server.registerTool(
|
|
4530
4517
|
"list_projects",
|
|
@@ -4546,6 +4533,17 @@ function registerProjectTools(server, getClient2) {
|
|
|
4546
4533
|
},
|
|
4547
4534
|
withClientArgs(getClient2, getProjectSettings)
|
|
4548
4535
|
);
|
|
4536
|
+
server.registerTool(
|
|
4537
|
+
"get_project_context",
|
|
4538
|
+
{
|
|
4539
|
+
title: "Get project context",
|
|
4540
|
+
description: "Read-only project identity + the PM-owned canonical project stage. Returns: projectId, projectName, client, pmEmail, repos[], projectStage (prototype | early_revenue | growth | scale | null), projectStageSetBy, projectStageSetAt. Call this at the start of an audit run instead of trusting AGENTS.md self-declaration \u2014 the stage drives audit calibration. Auth-only (no manager check), so devs running the audit skill from their own machine can call it directly.",
|
|
4541
|
+
inputSchema: {
|
|
4542
|
+
projectId: z22.number().int().positive().describe("Strapi project id from list_projects.")
|
|
4543
|
+
}
|
|
4544
|
+
},
|
|
4545
|
+
withClientArgs(getClient2, getProjectContext)
|
|
4546
|
+
);
|
|
4549
4547
|
}
|
|
4550
4548
|
var SHAPE_DESC = "crawling | walking | running. Target shape is intent (PM sets when creating); current shape is computed from feature stages.";
|
|
4551
4549
|
async function listPhases(client, input3) {
|
|
@@ -4717,49 +4715,15 @@ function registerFeatureTools(server, getClient2) {
|
|
|
4717
4715
|
withClientArgs(getClient2, updateFeature)
|
|
4718
4716
|
);
|
|
4719
4717
|
}
|
|
4720
|
-
var FLAG_STATUS_VALUES = ["open", "resolved", "all"];
|
|
4721
|
-
async function listAuditFlags(client, input3) {
|
|
4722
|
-
return safe(() => client.pm.listAuditFlags(input3.projectId, input3.status ?? "open"));
|
|
4723
|
-
}
|
|
4724
|
-
async function getAuditCatalog(client) {
|
|
4725
|
-
return safe(() => client.pm.getAuditCatalog());
|
|
4726
|
-
}
|
|
4727
4718
|
async function runProjectAudit(client, input3) {
|
|
4728
4719
|
return safe(() => client.pm.runProjectAudit(input3.projectId));
|
|
4729
4720
|
}
|
|
4730
|
-
var listAuditFlagsInputSchema = z5.object({
|
|
4731
|
-
projectId: z5.number().int().positive(),
|
|
4732
|
-
status: z5.enum(FLAG_STATUS_VALUES).optional()
|
|
4733
|
-
});
|
|
4734
4721
|
function registerAuditTools(server, getClient2) {
|
|
4735
|
-
server.registerTool(
|
|
4736
|
-
"list_audit_flags",
|
|
4737
|
-
{
|
|
4738
|
-
title: "List project audit flags",
|
|
4739
|
-
description: "Lists audit flags the nightly cron has raised for a project. Each entry pairs the flag (id, severity, evidence, entity it points at, first/last seen, occurrence count) with its catalog entry (human-readable title + description + rule type). Default status='open'; pass 'all' to include resolved flags for context.",
|
|
4740
|
-
inputSchema: {
|
|
4741
|
-
projectId: z5.number().int().positive(),
|
|
4742
|
-
status: z5.enum(FLAG_STATUS_VALUES).optional().describe(
|
|
4743
|
-
"Default 'open'. 'resolved' = fixed (flag no longer tripping on latest run). 'all' = every flag ever raised on this project."
|
|
4744
|
-
)
|
|
4745
|
-
}
|
|
4746
|
-
},
|
|
4747
|
-
withClientArgs(getClient2, listAuditFlags)
|
|
4748
|
-
);
|
|
4749
|
-
server.registerTool(
|
|
4750
|
-
"get_audit_catalog",
|
|
4751
|
-
{
|
|
4752
|
-
title: "Get audit catalog",
|
|
4753
|
-
description: "Returns every audit rule the system knows about (code, category, title, description, severity, rubric version). Use this to explain to a PM what a specific flag means, or to enumerate what kinds of things we audit for. Catalog is read-only \u2014 new entries land via migration.",
|
|
4754
|
-
inputSchema: {}
|
|
4755
|
-
},
|
|
4756
|
-
withClient(getClient2, getAuditCatalog)
|
|
4757
|
-
);
|
|
4758
4722
|
server.registerTool(
|
|
4759
4723
|
"run_project_audit",
|
|
4760
4724
|
{
|
|
4761
4725
|
title: "Run project audit now",
|
|
4762
|
-
description: "Triggers an immediate audit run for a single project
|
|
4726
|
+
description: "Triggers an immediate audit run for a single project. Refreshes the cache tables that drive the SDK rule engine (in-progress staleness, PM comment presence) and runs the inactive-codes sweep over any legacy open flag rows. Returns {fired, resolved, checkErrors}. Useful after a PM fixes something and wants the next dashboard load to reflect it without waiting for tomorrow's nightly cron.",
|
|
4763
4727
|
inputSchema: {
|
|
4764
4728
|
projectId: z5.number().int().positive()
|
|
4765
4729
|
}
|
|
@@ -4865,7 +4829,7 @@ function registerBoardAuditTools(server, getClient2) {
|
|
|
4865
4829
|
"get_board_audit_catalog",
|
|
4866
4830
|
{
|
|
4867
4831
|
title: "Get board-audit catalog",
|
|
4868
|
-
description: "Returns every board-audit rule the system knows about (code, category, title, description, severity).
|
|
4832
|
+
description: "Returns every board-audit rule the system knows about (code, category, title, description, severity). Covers ticket-tracker hygiene checks (story quality, workflow correctness); project-level health rules live in the SDK rule engine and surface via `get_project_health`.",
|
|
4869
4833
|
inputSchema: {}
|
|
4870
4834
|
},
|
|
4871
4835
|
withClient(getClient2, getBoardAuditCatalog)
|
|
@@ -4902,7 +4866,7 @@ function registerPortfolioStatusTools(server, getClient2) {
|
|
|
4902
4866
|
"get_my_portfolio_status",
|
|
4903
4867
|
{
|
|
4904
4868
|
title: "Get my portfolio status",
|
|
4905
|
-
description: "Cross-project ranked answer to 'where do I focus next?'. Returns one entry per project the caller can see, sorted by urgency desc. Each entry includes: 0\u2013100 health score (same formula as the dashboard cards), open
|
|
4869
|
+
description: "Cross-project ranked answer to 'where do I focus next?'. Returns one entry per project the caller can see, sorted by urgency desc. Each entry includes: 0\u2013100 health score (same formula as the dashboard cards), open-issue counts grouped by severity (critical/high/medium/low) from the SDK rule engine, up to 3 short topAttentionReasons derived from the highest-severity open issues, latest plan score across the project's repos, and the most recent audit timestamp. Default scope is the caller's own projects; managers can pass `pmEmail` to view another PM's portfolio or omit it to see the org-wide top `limit` projects (default 10). Use this for 'how is my portfolio doing?' and 'which project of <person>'s needs help?' questions \u2014 it pulls in one tool call what would otherwise be `list_projects` + N \xD7 `get_project_health`.",
|
|
4906
4870
|
inputSchema: {
|
|
4907
4871
|
pmEmail: z9.string().email().optional().describe(
|
|
4908
4872
|
"Manager-only override. When set, scopes the response to that PM's projects. Non-managers may only set this to their own email; any other value returns 403."
|
package/package.json
CHANGED