mrvn-cli 0.3.5 → 0.3.7
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.d.ts +1 -1
- package/dist/index.js +332 -207
- package/dist/index.js.map +1 -1
- package/dist/marvin-serve.js +59 -8
- package/dist/marvin-serve.js.map +1 -1
- package/dist/marvin.js +337 -214
- package/dist/marvin.js.map +1 -1
- package/package.json +1 -1
package/dist/marvin-serve.js
CHANGED
|
@@ -14295,7 +14295,8 @@ function createDecisionTools(store) {
|
|
|
14295
14295
|
title: external_exports.string().optional().describe("New title"),
|
|
14296
14296
|
status: external_exports.string().optional().describe("New status"),
|
|
14297
14297
|
content: external_exports.string().optional().describe("New content"),
|
|
14298
|
-
owner: external_exports.string().optional().describe("New owner")
|
|
14298
|
+
owner: external_exports.string().optional().describe("New owner"),
|
|
14299
|
+
tags: external_exports.array(external_exports.string()).optional().describe("Replace tags (e.g. remove 'risk', add 'risk-mitigated')")
|
|
14299
14300
|
},
|
|
14300
14301
|
async (args) => {
|
|
14301
14302
|
const { id, content, ...updates } = args;
|
|
@@ -14446,11 +14447,21 @@ function createActionTools(store) {
|
|
|
14446
14447
|
owner: external_exports.string().optional().describe("New owner"),
|
|
14447
14448
|
priority: external_exports.string().optional().describe("New priority"),
|
|
14448
14449
|
dueDate: external_exports.string().optional().describe("Due date in ISO format (e.g. '2026-03-15')"),
|
|
14450
|
+
tags: external_exports.array(external_exports.string()).optional().describe("Replace all tags. When provided with sprints, sprint tags are merged into this array."),
|
|
14449
14451
|
sprints: external_exports.array(external_exports.string()).optional().describe("Sprint IDs to assign (replaces existing sprint tags). E.g. ['SP-001'].")
|
|
14450
14452
|
},
|
|
14451
14453
|
async (args) => {
|
|
14452
|
-
const { id, content, sprints, ...updates } = args;
|
|
14453
|
-
if (
|
|
14454
|
+
const { id, content, sprints, tags, ...updates } = args;
|
|
14455
|
+
if (tags !== void 0) {
|
|
14456
|
+
const merged = [...tags];
|
|
14457
|
+
if (sprints) {
|
|
14458
|
+
for (const s of sprints) {
|
|
14459
|
+
const tag = `sprint:${s}`;
|
|
14460
|
+
if (!merged.includes(tag)) merged.push(tag);
|
|
14461
|
+
}
|
|
14462
|
+
}
|
|
14463
|
+
updates.tags = merged;
|
|
14464
|
+
} else if (sprints !== void 0) {
|
|
14454
14465
|
const existing = store.get(id);
|
|
14455
14466
|
if (!existing) {
|
|
14456
14467
|
return {
|
|
@@ -14597,7 +14608,8 @@ function createQuestionTools(store) {
|
|
|
14597
14608
|
title: external_exports.string().optional().describe("New title"),
|
|
14598
14609
|
status: external_exports.string().optional().describe("New status (e.g. 'answered')"),
|
|
14599
14610
|
content: external_exports.string().optional().describe("Updated content / answer"),
|
|
14600
|
-
owner: external_exports.string().optional().describe("New owner")
|
|
14611
|
+
owner: external_exports.string().optional().describe("New owner"),
|
|
14612
|
+
tags: external_exports.array(external_exports.string()).optional().describe("Replace tags (e.g. remove 'risk', add 'risk-mitigated')")
|
|
14601
14613
|
},
|
|
14602
14614
|
async (args) => {
|
|
14603
14615
|
const { id, content, ...updates } = args;
|
|
@@ -15099,7 +15111,7 @@ function collectGarMetrics(store) {
|
|
|
15099
15111
|
);
|
|
15100
15112
|
const openQuestions = store.list({ type: "question", status: "open" });
|
|
15101
15113
|
const riskItems = allDocs.filter(
|
|
15102
|
-
(d) => d.frontmatter.tags?.includes("risk")
|
|
15114
|
+
(d) => d.frontmatter.tags?.includes("risk") && d.frontmatter.status !== "done" && d.frontmatter.status !== "closed"
|
|
15103
15115
|
);
|
|
15104
15116
|
const unownedActions = openActions.filter((d) => !d.frontmatter.owner);
|
|
15105
15117
|
const total = allActions.length;
|
|
@@ -15500,7 +15512,7 @@ function createReportTools(store) {
|
|
|
15500
15512
|
async () => {
|
|
15501
15513
|
const allDocs = store.list();
|
|
15502
15514
|
const taggedRisks = allDocs.filter(
|
|
15503
|
-
(d) => d.frontmatter.tags?.includes("risk")
|
|
15515
|
+
(d) => d.frontmatter.tags?.includes("risk") && d.frontmatter.status !== "done" && d.frontmatter.status !== "closed"
|
|
15504
15516
|
);
|
|
15505
15517
|
const highPriorityActions = store.list({ type: "action", status: "open" }).filter((d) => d.frontmatter.priority === "high");
|
|
15506
15518
|
const unresolvedQuestions = store.list({ type: "question", status: "open" });
|
|
@@ -15871,7 +15883,8 @@ function createFeatureTools(store) {
|
|
|
15871
15883
|
status: external_exports.enum(["draft", "approved", "deferred", "done"]).optional().describe("New status"),
|
|
15872
15884
|
content: external_exports.string().optional().describe("New content"),
|
|
15873
15885
|
owner: external_exports.string().optional().describe("New owner"),
|
|
15874
|
-
priority: external_exports.enum(["critical", "high", "medium", "low"]).optional().describe("New priority")
|
|
15886
|
+
priority: external_exports.enum(["critical", "high", "medium", "low"]).optional().describe("New priority"),
|
|
15887
|
+
tags: external_exports.array(external_exports.string()).optional().describe("Replace tags (e.g. remove 'risk', add 'risk-mitigated')")
|
|
15875
15888
|
},
|
|
15876
15889
|
async (args) => {
|
|
15877
15890
|
const { id, content, ...updates } = args;
|
|
@@ -16028,7 +16041,8 @@ function createEpicTools(store) {
|
|
|
16028
16041
|
content: external_exports.string().optional().describe("New content"),
|
|
16029
16042
|
owner: external_exports.string().optional().describe("New owner"),
|
|
16030
16043
|
targetDate: external_exports.string().optional().describe("New target date"),
|
|
16031
|
-
estimatedEffort: external_exports.string().optional().describe("New estimated effort")
|
|
16044
|
+
estimatedEffort: external_exports.string().optional().describe("New estimated effort"),
|
|
16045
|
+
tags: external_exports.array(external_exports.string()).optional().describe("Replace tags (e.g. remove 'risk', add 'risk-mitigated')")
|
|
16032
16046
|
},
|
|
16033
16047
|
async (args) => {
|
|
16034
16048
|
const { id, content, ...updates } = args;
|
|
@@ -18261,6 +18275,16 @@ function resolveSkillsForPersona(personaId, skillsConfig, allSkills) {
|
|
|
18261
18275
|
}
|
|
18262
18276
|
return result;
|
|
18263
18277
|
}
|
|
18278
|
+
function collectSkillRegistrations(skillIds, allSkills) {
|
|
18279
|
+
const registrations = [];
|
|
18280
|
+
for (const id of skillIds) {
|
|
18281
|
+
const skill = allSkills.get(id);
|
|
18282
|
+
if (skill?.documentTypeRegistrations) {
|
|
18283
|
+
registrations.push(...skill.documentTypeRegistrations);
|
|
18284
|
+
}
|
|
18285
|
+
}
|
|
18286
|
+
return registrations;
|
|
18287
|
+
}
|
|
18264
18288
|
function getSkillTools(skillIds, allSkills, store) {
|
|
18265
18289
|
const tools = [];
|
|
18266
18290
|
for (const id of skillIds) {
|
|
@@ -19702,6 +19726,26 @@ function notFound(res, projectName, navGroups, activePath) {
|
|
|
19702
19726
|
// src/web/server.ts
|
|
19703
19727
|
import * as http from "http";
|
|
19704
19728
|
import { exec } from "child_process";
|
|
19729
|
+
var CORE_TYPES = ["decision", "action", "question"];
|
|
19730
|
+
function buildNavGroups(input) {
|
|
19731
|
+
const commonTypes = new Set(COMMON_REGISTRATIONS.map((r) => r.type));
|
|
19732
|
+
const pluginOnlyTypes = input.pluginRegs.map((r) => r.type).filter((t) => !commonTypes.has(t));
|
|
19733
|
+
const skillTypes = input.skillRegs.map((r) => r.type);
|
|
19734
|
+
const navGroups = [
|
|
19735
|
+
{ label: "Governance", types: CORE_TYPES },
|
|
19736
|
+
{ label: "Project", types: [...commonTypes] }
|
|
19737
|
+
];
|
|
19738
|
+
if (pluginOnlyTypes.length > 0) {
|
|
19739
|
+
navGroups.push({
|
|
19740
|
+
label: input.pluginName ?? "Plugin",
|
|
19741
|
+
types: pluginOnlyTypes
|
|
19742
|
+
});
|
|
19743
|
+
}
|
|
19744
|
+
if (skillTypes.length > 0) {
|
|
19745
|
+
navGroups.push({ label: "Skills", types: skillTypes });
|
|
19746
|
+
}
|
|
19747
|
+
return navGroups;
|
|
19748
|
+
}
|
|
19705
19749
|
function openBrowser(url2) {
|
|
19706
19750
|
const platform = process.platform;
|
|
19707
19751
|
const cmd = platform === "darwin" ? `open "${url2}"` : platform === "win32" ? `start "${url2}"` : `xdg-open "${url2}"`;
|
|
@@ -20316,6 +20360,12 @@ function collectTools(marvinDir) {
|
|
|
20316
20360
|
const skillsWithActions = allSkillIds.map((id) => allSkills.get(id)).filter((s) => s.actions && s.actions.length > 0);
|
|
20317
20361
|
const projectRoot = path8.dirname(marvinDir);
|
|
20318
20362
|
const actionTools = createSkillActionTools(skillsWithActions, { store, marvinDir, projectRoot });
|
|
20363
|
+
const allSkillRegs = collectSkillRegistrations(allSkillIds, allSkills);
|
|
20364
|
+
const navGroups = buildNavGroups({
|
|
20365
|
+
pluginRegs: registrations,
|
|
20366
|
+
skillRegs: allSkillRegs,
|
|
20367
|
+
pluginName: plugin?.name
|
|
20368
|
+
});
|
|
20319
20369
|
return [
|
|
20320
20370
|
...createDecisionTools(store),
|
|
20321
20371
|
...createActionTools(store),
|
|
@@ -20323,6 +20373,7 @@ function collectTools(marvinDir) {
|
|
|
20323
20373
|
...createDocumentTools(store),
|
|
20324
20374
|
...manifest ? createSourceTools(manifest) : [],
|
|
20325
20375
|
...createSessionTools(sessionStore),
|
|
20376
|
+
...createWebTools(store, config2.name, navGroups),
|
|
20326
20377
|
...pluginTools,
|
|
20327
20378
|
...codeSkillTools,
|
|
20328
20379
|
...actionTools
|