dominds 1.5.2 → 1.6.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/apps/configuration-file.js +21 -0
- package/dist/apps/enabled-apps.js +3 -53
- package/dist/apps/local-package-root.js +41 -0
- package/dist/apps/runtime.js +10 -0
- package/dist/apps-host/client.js +124 -1
- package/dist/apps-host/host.js +53 -0
- package/dist/apps-host/ipc-types.js +61 -1
- package/dist/cli/install.js +41 -8
- package/dist/docs/app-constitution.md +22 -0
- package/dist/docs/app-constitution.zh.md +22 -0
- package/dist/llm/kernel-driver/runtime.js +112 -22
- package/dist/minds/load.js +20 -2
- package/dist/minds/system-prompt.js +4 -0
- package/dist/priming.js +2 -26
- package/dist/server/websocket-handler.js +5 -0
- package/dist/server.js +5 -2
- package/dist/shared/markdown-frontmatter.js +44 -0
- package/dist/shared/team_mgmt-manual.js +9 -0
- package/dist/skills/load.js +281 -0
- package/dist/static/assets/{_basePickBy-B-A5XrWM.js → _basePickBy-CFicLWwx.js} +3 -3
- package/dist/static/assets/{_basePickBy-B-A5XrWM.js.map → _basePickBy-CFicLWwx.js.map} +1 -1
- package/dist/static/assets/{_baseUniq-BANLb0cu.js → _baseUniq-DQTl8GFk.js} +2 -2
- package/dist/static/assets/{_baseUniq-BANLb0cu.js.map → _baseUniq-DQTl8GFk.js.map} +1 -1
- package/dist/static/assets/{arc-CYZYnojf.js → arc-Bc5lgJ6S.js} +2 -2
- package/dist/static/assets/{arc-CYZYnojf.js.map → arc-Bc5lgJ6S.js.map} +1 -1
- package/dist/static/assets/{architectureDiagram-VXUJARFQ-Cxf4pmYG.js → architectureDiagram-VXUJARFQ-DygUo6iw.js} +7 -7
- package/dist/static/assets/{architectureDiagram-VXUJARFQ-Cxf4pmYG.js.map → architectureDiagram-VXUJARFQ-DygUo6iw.js.map} +1 -1
- package/dist/static/assets/{blockDiagram-VD42YOAC-wvs0G30c.js → blockDiagram-VD42YOAC-0r3VY3gz.js} +7 -7
- package/dist/static/assets/{blockDiagram-VD42YOAC-wvs0G30c.js.map → blockDiagram-VD42YOAC-0r3VY3gz.js.map} +1 -1
- package/dist/static/assets/{c4Diagram-YG6GDRKO-BKFNexn4.js → c4Diagram-YG6GDRKO-pQD_vC1A.js} +3 -3
- package/dist/static/assets/{c4Diagram-YG6GDRKO-BKFNexn4.js.map → c4Diagram-YG6GDRKO-pQD_vC1A.js.map} +1 -1
- package/dist/static/assets/{channel-_1qpxJWy.js → channel-CHWYhNRt.js} +2 -2
- package/dist/static/assets/{channel-_1qpxJWy.js.map → channel-CHWYhNRt.js.map} +1 -1
- package/dist/static/assets/{chunk-4BX2VUAB-BIdC0phm.js → chunk-4BX2VUAB-K89xP4ET.js} +2 -2
- package/dist/static/assets/{chunk-4BX2VUAB-BIdC0phm.js.map → chunk-4BX2VUAB-K89xP4ET.js.map} +1 -1
- package/dist/static/assets/{chunk-55IACEB6-BNvGenQ9.js → chunk-55IACEB6-DHAy4AJ-.js} +2 -2
- package/dist/static/assets/{chunk-55IACEB6-BNvGenQ9.js.map → chunk-55IACEB6-DHAy4AJ-.js.map} +1 -1
- package/dist/static/assets/{chunk-B4BG7PRW-jmf-1Wv7.js → chunk-B4BG7PRW-BrImUg93.js} +5 -5
- package/dist/static/assets/{chunk-B4BG7PRW-jmf-1Wv7.js.map → chunk-B4BG7PRW-BrImUg93.js.map} +1 -1
- package/dist/static/assets/{chunk-DI55MBZ5-nmEmcikR.js → chunk-DI55MBZ5-_jVBMKQY.js} +4 -4
- package/dist/static/assets/{chunk-DI55MBZ5-nmEmcikR.js.map → chunk-DI55MBZ5-_jVBMKQY.js.map} +1 -1
- package/dist/static/assets/{chunk-FMBD7UC4-kGysaq_j.js → chunk-FMBD7UC4-BmGs24Z_.js} +2 -2
- package/dist/static/assets/{chunk-FMBD7UC4-kGysaq_j.js.map → chunk-FMBD7UC4-BmGs24Z_.js.map} +1 -1
- package/dist/static/assets/{chunk-QN33PNHL-8JwMLFIJ.js → chunk-QN33PNHL-Bu8ZzYdl.js} +2 -2
- package/dist/static/assets/{chunk-QN33PNHL-8JwMLFIJ.js.map → chunk-QN33PNHL-Bu8ZzYdl.js.map} +1 -1
- package/dist/static/assets/{chunk-QZHKN3VN-DZleEj00.js → chunk-QZHKN3VN-D4fM_-kX.js} +2 -2
- package/dist/static/assets/{chunk-QZHKN3VN-DZleEj00.js.map → chunk-QZHKN3VN-D4fM_-kX.js.map} +1 -1
- package/dist/static/assets/{chunk-TZMSLE5B-CXxl_uqH.js → chunk-TZMSLE5B-xK6Lo8h6.js} +2 -2
- package/dist/static/assets/{chunk-TZMSLE5B-CXxl_uqH.js.map → chunk-TZMSLE5B-xK6Lo8h6.js.map} +1 -1
- package/dist/static/assets/{classDiagram-2ON5EDUG-C-7R0QB6.js → classDiagram-2ON5EDUG-Bn36uVsZ.js} +6 -6
- package/dist/static/assets/{classDiagram-2ON5EDUG-C-7R0QB6.js.map → classDiagram-2ON5EDUG-Bn36uVsZ.js.map} +1 -1
- package/dist/static/assets/{classDiagram-v2-WZHVMYZB-C-7R0QB6.js → classDiagram-v2-WZHVMYZB-Bn36uVsZ.js} +6 -6
- package/dist/static/assets/{classDiagram-v2-WZHVMYZB-C-7R0QB6.js.map → classDiagram-v2-WZHVMYZB-Bn36uVsZ.js.map} +1 -1
- package/dist/static/assets/{clone-BwOKYSj8.js → clone-BUW9sxY1.js} +2 -2
- package/dist/static/assets/{clone-BwOKYSj8.js.map → clone-BUW9sxY1.js.map} +1 -1
- package/dist/static/assets/{cose-bilkent-S5V4N54A-BCBalM7p.js → cose-bilkent-S5V4N54A-BMTYUmA4.js} +2 -2
- package/dist/static/assets/{cose-bilkent-S5V4N54A-BCBalM7p.js.map → cose-bilkent-S5V4N54A-BMTYUmA4.js.map} +1 -1
- package/dist/static/assets/{dagre-6UL2VRFP-uV2ekQoj.js → dagre-6UL2VRFP-p-0HOF0Q.js} +7 -7
- package/dist/static/assets/{dagre-6UL2VRFP-uV2ekQoj.js.map → dagre-6UL2VRFP-p-0HOF0Q.js.map} +1 -1
- package/dist/static/assets/{diagram-PSM6KHXK-D-ZMog1-.js → diagram-PSM6KHXK-CfpXvSJR.js} +8 -8
- package/dist/static/assets/{diagram-PSM6KHXK-D-ZMog1-.js.map → diagram-PSM6KHXK-CfpXvSJR.js.map} +1 -1
- package/dist/static/assets/{diagram-QEK2KX5R-BThSELUH.js → diagram-QEK2KX5R-3T4XwT5a.js} +7 -7
- package/dist/static/assets/{diagram-QEK2KX5R-BThSELUH.js.map → diagram-QEK2KX5R-3T4XwT5a.js.map} +1 -1
- package/dist/static/assets/{diagram-S2PKOQOG-Di-YN5cd.js → diagram-S2PKOQOG-CPHGTwGV.js} +7 -7
- package/dist/static/assets/{diagram-S2PKOQOG-Di-YN5cd.js.map → diagram-S2PKOQOG-CPHGTwGV.js.map} +1 -1
- package/dist/static/assets/{erDiagram-Q2GNP2WA-lBZ9DITn.js → erDiagram-Q2GNP2WA-Bj7OGj2H.js} +5 -5
- package/dist/static/assets/{erDiagram-Q2GNP2WA-lBZ9DITn.js.map → erDiagram-Q2GNP2WA-Bj7OGj2H.js.map} +1 -1
- package/dist/static/assets/{flowDiagram-NV44I4VS-C_60PNQR.js → flowDiagram-NV44I4VS-DOGilHpN.js} +6 -6
- package/dist/static/assets/{flowDiagram-NV44I4VS-C_60PNQR.js.map → flowDiagram-NV44I4VS-DOGilHpN.js.map} +1 -1
- package/dist/static/assets/{ganttDiagram-JELNMOA3-Dvqq-VHJ.js → ganttDiagram-JELNMOA3-585cSoqi.js} +3 -3
- package/dist/static/assets/{ganttDiagram-JELNMOA3-Dvqq-VHJ.js.map → ganttDiagram-JELNMOA3-585cSoqi.js.map} +1 -1
- package/dist/static/assets/{gitGraphDiagram-V2S2FVAM-BTj8orRe.js → gitGraphDiagram-V2S2FVAM-gmTvHjpH.js} +8 -8
- package/dist/static/assets/{gitGraphDiagram-V2S2FVAM-BTj8orRe.js.map → gitGraphDiagram-V2S2FVAM-gmTvHjpH.js.map} +1 -1
- package/dist/static/assets/{graph-BqCzR2Nl.js → graph-Dtj8yklH.js} +3 -3
- package/dist/static/assets/{graph-BqCzR2Nl.js.map → graph-Dtj8yklH.js.map} +1 -1
- package/dist/static/assets/{index-DrTqAfFy.js → index-BvNwR1gS.js} +442 -246
- package/dist/static/assets/index-BvNwR1gS.js.map +1 -0
- package/dist/static/assets/{infoDiagram-HS3SLOUP-DlC6wsrv.js → infoDiagram-HS3SLOUP-BVq8aa78.js} +6 -6
- package/dist/static/assets/{infoDiagram-HS3SLOUP-DlC6wsrv.js.map → infoDiagram-HS3SLOUP-BVq8aa78.js.map} +1 -1
- package/dist/static/assets/{journeyDiagram-XKPGCS4Q-Dg_RgtQX.js → journeyDiagram-XKPGCS4Q-BY5Lcmin.js} +5 -5
- package/dist/static/assets/{journeyDiagram-XKPGCS4Q-Dg_RgtQX.js.map → journeyDiagram-XKPGCS4Q-BY5Lcmin.js.map} +1 -1
- package/dist/static/assets/{kanban-definition-3W4ZIXB7-DuGS3lId.js → kanban-definition-3W4ZIXB7-zEbpyocs.js} +3 -3
- package/dist/static/assets/{kanban-definition-3W4ZIXB7-DuGS3lId.js.map → kanban-definition-3W4ZIXB7-zEbpyocs.js.map} +1 -1
- package/dist/static/assets/{layout-FDz2bstZ.js → layout-Bst5DR3z.js} +5 -5
- package/dist/static/assets/{layout-FDz2bstZ.js.map → layout-Bst5DR3z.js.map} +1 -1
- package/dist/static/assets/{linear-CzsdvPGb.js → linear-TSyBw4eX.js} +2 -2
- package/dist/static/assets/{linear-CzsdvPGb.js.map → linear-TSyBw4eX.js.map} +1 -1
- package/dist/static/assets/{mindmap-definition-VGOIOE7T-WsAF5UNp.js → mindmap-definition-VGOIOE7T-I6ArhFTa.js} +4 -4
- package/dist/static/assets/{mindmap-definition-VGOIOE7T-WsAF5UNp.js.map → mindmap-definition-VGOIOE7T-I6ArhFTa.js.map} +1 -1
- package/dist/static/assets/{pieDiagram-ADFJNKIX-DJpRJ5ei.js → pieDiagram-ADFJNKIX-DdaOCLgH.js} +8 -8
- package/dist/static/assets/{pieDiagram-ADFJNKIX-DJpRJ5ei.js.map → pieDiagram-ADFJNKIX-DdaOCLgH.js.map} +1 -1
- package/dist/static/assets/{quadrantDiagram-AYHSOK5B-CMyIzTkY.js → quadrantDiagram-AYHSOK5B-Bp82x7cE.js} +3 -3
- package/dist/static/assets/{quadrantDiagram-AYHSOK5B-CMyIzTkY.js.map → quadrantDiagram-AYHSOK5B-Bp82x7cE.js.map} +1 -1
- package/dist/static/assets/{requirementDiagram-UZGBJVZJ-D_yqVXGu.js → requirementDiagram-UZGBJVZJ-eSQPrL7r.js} +4 -4
- package/dist/static/assets/{requirementDiagram-UZGBJVZJ-D_yqVXGu.js.map → requirementDiagram-UZGBJVZJ-eSQPrL7r.js.map} +1 -1
- package/dist/static/assets/{sankeyDiagram-TZEHDZUN-D4-cF724.js → sankeyDiagram-TZEHDZUN-DbMClHuR.js} +2 -2
- package/dist/static/assets/{sankeyDiagram-TZEHDZUN-D4-cF724.js.map → sankeyDiagram-TZEHDZUN-DbMClHuR.js.map} +1 -1
- package/dist/static/assets/{sequenceDiagram-WL72ISMW-B7J3gWYN.js → sequenceDiagram-WL72ISMW-CxQHJ2QR.js} +4 -4
- package/dist/static/assets/{sequenceDiagram-WL72ISMW-B7J3gWYN.js.map → sequenceDiagram-WL72ISMW-CxQHJ2QR.js.map} +1 -1
- package/dist/static/assets/{stateDiagram-FKZM4ZOC-DwEYYCcu.js → stateDiagram-FKZM4ZOC-BrJWwcfT.js} +9 -9
- package/dist/static/assets/{stateDiagram-FKZM4ZOC-DwEYYCcu.js.map → stateDiagram-FKZM4ZOC-BrJWwcfT.js.map} +1 -1
- package/dist/static/assets/{stateDiagram-v2-4FDKWEC3-D4LOOQV5.js → stateDiagram-v2-4FDKWEC3-AOoa1rfD.js} +5 -5
- package/dist/static/assets/{stateDiagram-v2-4FDKWEC3-D4LOOQV5.js.map → stateDiagram-v2-4FDKWEC3-AOoa1rfD.js.map} +1 -1
- package/dist/static/assets/{timeline-definition-IT6M3QCI-CyG-TJ_A.js → timeline-definition-IT6M3QCI-CGDQb8vq.js} +3 -3
- package/dist/static/assets/{timeline-definition-IT6M3QCI-CyG-TJ_A.js.map → timeline-definition-IT6M3QCI-CGDQb8vq.js.map} +1 -1
- package/dist/static/assets/{treemap-GDKQZRPO-yY4GiKmU.js → treemap-GDKQZRPO-DUkGxSl_.js} +5 -5
- package/dist/static/assets/{treemap-GDKQZRPO-yY4GiKmU.js.map → treemap-GDKQZRPO-DUkGxSl_.js.map} +1 -1
- package/dist/static/assets/{xychartDiagram-PRI3JC2R-5TYN_q15.js → xychartDiagram-PRI3JC2R-DhC3pydn.js} +3 -3
- package/dist/static/assets/{xychartDiagram-PRI3JC2R-5TYN_q15.js.map → xychartDiagram-PRI3JC2R-DhC3pydn.js.map} +1 -1
- package/dist/static/index.html +1 -1
- package/dist/team-config-updates.js +26 -0
- package/dist/team.js +23 -5
- package/dist/tools/team_mgmt.js +137 -0
- package/dist/tools/toolset-manual.js +12 -3
- package/package.json +1 -1
- package/dist/static/assets/index-DrTqAfFy.js.map +0 -1
package/dist/static/index.html
CHANGED
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
padding: 20px;
|
|
53
53
|
}
|
|
54
54
|
</style>
|
|
55
|
-
<script type="module" crossorigin src="/assets/index-
|
|
55
|
+
<script type="module" crossorigin src="/assets/index-BvNwR1gS.js"></script>
|
|
56
56
|
<link rel="stylesheet" crossorigin href="/assets/index-CD5wtC_i.css">
|
|
57
57
|
</head>
|
|
58
58
|
<body>
|
|
@@ -14,7 +14,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
14
14
|
};
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
16
|
exports.setTeamConfigBroadcaster = setTeamConfigBroadcaster;
|
|
17
|
+
exports.clearTeamConfigBroadcaster = clearTeamConfigBroadcaster;
|
|
17
18
|
exports.startTeamConfigWatcher = startTeamConfigWatcher;
|
|
19
|
+
exports.stopTeamConfigWatcher = stopTeamConfigWatcher;
|
|
18
20
|
exports.notifyTeamConfigUpdated = notifyTeamConfigUpdated;
|
|
19
21
|
const fs_1 = __importDefault(require("fs"));
|
|
20
22
|
const path_1 = __importDefault(require("path"));
|
|
@@ -50,6 +52,9 @@ let broadcastToClients;
|
|
|
50
52
|
function setTeamConfigBroadcaster(fn) {
|
|
51
53
|
broadcastToClients = fn;
|
|
52
54
|
}
|
|
55
|
+
function clearTeamConfigBroadcaster() {
|
|
56
|
+
broadcastToClients = undefined;
|
|
57
|
+
}
|
|
53
58
|
function broadcast(msg) {
|
|
54
59
|
const fn = broadcastToClients;
|
|
55
60
|
if (!fn)
|
|
@@ -161,6 +166,27 @@ function startTeamConfigWatcher() {
|
|
|
161
166
|
void ensureMindsDirWatcher('poll');
|
|
162
167
|
scheduleCheck('poll');
|
|
163
168
|
}, 1500);
|
|
169
|
+
pollTimer.unref();
|
|
170
|
+
}
|
|
171
|
+
function stopTeamConfigWatcher() {
|
|
172
|
+
if (mindsDirWatcher) {
|
|
173
|
+
mindsDirWatcher.close();
|
|
174
|
+
mindsDirWatcher = undefined;
|
|
175
|
+
}
|
|
176
|
+
if (workspaceWatcher) {
|
|
177
|
+
workspaceWatcher.close();
|
|
178
|
+
workspaceWatcher = undefined;
|
|
179
|
+
}
|
|
180
|
+
if (pollTimer) {
|
|
181
|
+
clearInterval(pollTimer);
|
|
182
|
+
pollTimer = undefined;
|
|
183
|
+
}
|
|
184
|
+
if (debounceTimer) {
|
|
185
|
+
clearTimeout(debounceTimer);
|
|
186
|
+
debounceTimer = undefined;
|
|
187
|
+
}
|
|
188
|
+
watcherStarted = false;
|
|
189
|
+
lastSeenSig = undefined;
|
|
164
190
|
}
|
|
165
191
|
/**
|
|
166
192
|
* Explicit notification hook for code paths that are known to mutate `.minds/team.yaml`.
|
package/dist/team.js
CHANGED
|
@@ -15,6 +15,7 @@ exports.Team = void 0;
|
|
|
15
15
|
const promises_1 = __importDefault(require("fs/promises"));
|
|
16
16
|
const yaml_1 = __importDefault(require("yaml"));
|
|
17
17
|
const enabled_apps_1 = require("./apps/enabled-apps");
|
|
18
|
+
const runtime_1 = require("./apps/runtime");
|
|
18
19
|
const teammates_1 = require("./apps/teammates");
|
|
19
20
|
const client_1 = require("./llm/client");
|
|
20
21
|
const log_1 = require("./log");
|
|
@@ -293,18 +294,20 @@ exports.Team = Team;
|
|
|
293
294
|
* that resolve to different Tool objects. Returns no duplicate tools per name.
|
|
294
295
|
*/
|
|
295
296
|
listResolvedToolsetNames(options) {
|
|
296
|
-
if (!this.toolsets)
|
|
297
|
-
return [];
|
|
298
297
|
const onMissing = options?.onMissing ?? 'warn';
|
|
298
|
+
const dynamicToolsetNames = options?.dynamicToolsetNames ?? [];
|
|
299
|
+
const staticToolsets = this.toolsets ?? [];
|
|
300
|
+
if (staticToolsets.length === 0 && dynamicToolsetNames.length === 0)
|
|
301
|
+
return [];
|
|
299
302
|
const excludedToolsets = new Set();
|
|
300
|
-
for (const entry of
|
|
303
|
+
for (const entry of staticToolsets) {
|
|
301
304
|
if (entry.startsWith('!') && entry.length > 1) {
|
|
302
305
|
excludedToolsets.add(entry.slice(1));
|
|
303
306
|
}
|
|
304
307
|
}
|
|
305
308
|
const resolved = [];
|
|
306
309
|
const seen = new Set();
|
|
307
|
-
for (const toolsetName of
|
|
310
|
+
for (const toolsetName of [...staticToolsets, ...dynamicToolsetNames]) {
|
|
308
311
|
if (toolsetName.startsWith('!'))
|
|
309
312
|
continue;
|
|
310
313
|
const toolsetNames = toolsetName === '*'
|
|
@@ -333,8 +336,12 @@ exports.Team = Team;
|
|
|
333
336
|
const seenNames = new Set();
|
|
334
337
|
const onMissingToolset = options?.onMissingToolset ?? 'warn';
|
|
335
338
|
const onMissingTool = options?.onMissingTool ?? 'warn';
|
|
339
|
+
const dynamicToolsetNames = options?.dynamicToolsetNames ?? [];
|
|
336
340
|
// Process toolsets (in declaration order)
|
|
337
|
-
for (const toolsetName of this.listResolvedToolsetNames({
|
|
341
|
+
for (const toolsetName of this.listResolvedToolsetNames({
|
|
342
|
+
onMissing: onMissingToolset,
|
|
343
|
+
dynamicToolsetNames,
|
|
344
|
+
})) {
|
|
338
345
|
const tools = (0, registry_1.getToolset)(toolsetName);
|
|
339
346
|
if (!tools)
|
|
340
347
|
continue;
|
|
@@ -375,6 +382,17 @@ exports.Team = Team;
|
|
|
375
382
|
}
|
|
376
383
|
}
|
|
377
384
|
Team.Member = Member;
|
|
385
|
+
async function listDynamicToolsetNamesForMember(params) {
|
|
386
|
+
if (params.taskDocPath === undefined || params.taskDocPath.trim() === '') {
|
|
387
|
+
return [];
|
|
388
|
+
}
|
|
389
|
+
return await (0, runtime_1.listDynamicAppToolsetsForMember)({
|
|
390
|
+
rtwsRootAbs: params.rtwsRootAbs ?? process.cwd(),
|
|
391
|
+
taskDocPath: params.taskDocPath,
|
|
392
|
+
memberId: params.member.id,
|
|
393
|
+
});
|
|
394
|
+
}
|
|
395
|
+
Team.listDynamicToolsetNamesForMember = listDynamicToolsetNamesForMember;
|
|
378
396
|
// Team config support: load .minds/team.yaml
|
|
379
397
|
async function load() {
|
|
380
398
|
const md = new Team.Member({
|
package/dist/tools/team_mgmt.js
CHANGED
|
@@ -3119,6 +3119,137 @@ function renderMindsManual(language) {
|
|
|
3119
3119
|
'- For high-risk changes, start with a minimal reviewable plan before expansion.',
|
|
3120
3120
|
]));
|
|
3121
3121
|
}
|
|
3122
|
+
function renderSkillsManual(language) {
|
|
3123
|
+
if (language === 'zh') {
|
|
3124
|
+
return (fmtHeader('.minds/skills/*(技能)') +
|
|
3125
|
+
fmtList([
|
|
3126
|
+
'推荐目录:团队共享技能放在 `.minds/skills/team_shared/<skill-id>/SKILL.cn.md`(英文对齐文件用 `SKILL.en.md`);个人技能放在 `.minds/skills/individual/<member-id>/<skill-id>/SKILL.cn.md`。',
|
|
3127
|
+
'语言选择:Dominds 当前工作语言是 `zh|en`,但 skill 文件后缀采用更通行的 `cn|en`。当工作语言为 `zh` 时优先读取 `SKILL.cn.md`,当工作语言为 `en` 时优先读取 `SKILL.en.md`,两者都可回退到无语言标识的 `SKILL.md`;不会跨语言兜底到另一种语言文件。',
|
|
3128
|
+
'可移植优先格式:遵循当前主流 Agent Skills 生态公共子集,使用 `SKILL.md + YAML frontmatter`。最小必备字段是 `name` 与 `description`,正文 markdown 即真正的技能提示词/工作流说明。',
|
|
3129
|
+
'Dominds 当前实现会把匹配到的 skill 内容直接注入 agent system prompt;因此这里的技能更接近“工作流知识包”。这与部分平台的“先只加载 name/description、命中后再延迟加载正文”不同,请控制体量,把长参考资料拆到同目录其它文件并在正文里按需引用。',
|
|
3130
|
+
'为兼容公开来源,可保留 `allowed-tools` / `user-invocable` / `disable-model-invocation` 字段;但在 Dominds 中:这些字段目前只用于迁移/文档语义,不会自动授予工具权限,也不会改变运行时调度逻辑。',
|
|
3131
|
+
'最重要的边界:skill 不是权限系统。真正的工具能力仍由 `.minds/team.yaml` 的 `toolsets` / `tools` 与已安装 Dominds apps 决定。',
|
|
3132
|
+
'团队管理职责的智能体可以联网搜索公开 skill 定义(优先官方文档/官方仓库/官方 marketplace 条目),也可以直接基于团队真实工作流自行总结编写。迁移前必须核对 license、适用场景、是否依赖脚本/外部工具、是否夹带与本团队冲突的人设/权限假设。',
|
|
3133
|
+
'对于网络公开来源、并且带脚本/工具调用约束的 skills:默认不要只把文案抄进 `.minds/skills/**` 就上线。推荐路径是把执行能力封装成 Dominds app(app-host tools / toolsets / teammates contract),再由 skill 只保留工作流提示与对 app/toolset 的引用说明。',
|
|
3134
|
+
]) +
|
|
3135
|
+
fmtHeader('建议采用的 SKILL 文件格式') +
|
|
3136
|
+
fmtCodeBlock('markdown', [
|
|
3137
|
+
'---',
|
|
3138
|
+
'name: repo-debugger',
|
|
3139
|
+
'description: >',
|
|
3140
|
+
' 调试仓库级构建/测试失败的工作流。适用于 CI 失败、依赖漂移、环境不一致等场景。',
|
|
3141
|
+
'allowed-tools:',
|
|
3142
|
+
' - read_file',
|
|
3143
|
+
' - readonly_shell',
|
|
3144
|
+
'user-invocable: true',
|
|
3145
|
+
'disable-model-invocation: false',
|
|
3146
|
+
'---',
|
|
3147
|
+
'',
|
|
3148
|
+
'# Repo Debugger',
|
|
3149
|
+
'',
|
|
3150
|
+
'## 入口',
|
|
3151
|
+
'- 先确认失败信号与复现入口。',
|
|
3152
|
+
'- 若需要 shell,必须使用当前团队已授权的 Dominds 工具/专员,不得把 `allowed-tools` 视为自动授权。',
|
|
3153
|
+
'',
|
|
3154
|
+
'## 工作流',
|
|
3155
|
+
'1. 收集报错与最近变更。',
|
|
3156
|
+
'2. 最小化复现。',
|
|
3157
|
+
'3. 定位根因并给出验证方案。',
|
|
3158
|
+
]) +
|
|
3159
|
+
fmtHeader('公开来源迁移到 Dominds 的字段映射') +
|
|
3160
|
+
fmtList([
|
|
3161
|
+
'`name` → 直接保留。建议继续使用短 hyphen-case 标识,并与目录名 `<skill-id>` 保持一致。',
|
|
3162
|
+
'`description` → 直接保留,但要补足“何时触发/何时不该触发”。这在 GitHub/Codex/skills.sh 生态中本来就是关键触发字段。',
|
|
3163
|
+
'SKILL 正文 → 直接作为 Dominds skill 正文;如果正文包含平台专有命令(如 `/skill-name`、`Bash(git add:*)`、Claude 的 `!command` 注入等),迁移时必须改写为 Dominds 可执行语义。',
|
|
3164
|
+
'`allowed-tools` → 仅保留为迁移提示。然后把真正需要的能力映射到 Dominds app/toolset 或 `.minds/team.yaml members.<id>.toolsets|tools`。不要把它当运行时授权。',
|
|
3165
|
+
'`user-invocable` / `disable-model-invocation` → 目前仅保留为兼容元数据,Dominds 尚未把这两个字段做成调度开关。',
|
|
3166
|
+
'Anthropic subagent 的 `tools` / `model` / 子代理身份字段 → 不应直接塞进 Dominds skill。可复用的“工作流正文”抽出来做 skill;工具能力改走 Dominds app / toolset;人设与职责边界改写到 `.minds/team/<id>/persona.*.md`。',
|
|
3167
|
+
'GitHub `copilot-instructions.md` / `*.instructions.md` / `AGENTS.md` / `.prompt.md` 这类“纯 markdown 指令文件” → 通常没有完整 skill frontmatter。迁移时要补写 `name` 与 `description`,再把正文整理成真正可复用的工作流说明;如果它本质是仓库全局约束而不是技能,应优先放回 persona/knowledge/env/AGENTS,而不是硬转 skill。',
|
|
3168
|
+
]) +
|
|
3169
|
+
fmtHeader('团队管理智能体的落地操作步骤') +
|
|
3170
|
+
fmtList([
|
|
3171
|
+
'1. 联网搜索:优先找官方文档、官方仓库、官方 marketplace/listing(例如 GitHub Copilot Agent Skills、Claude Code skills/subagents、skills.sh 条目)。',
|
|
3172
|
+
'2. 识别类型:判断来源到底是标准 SKILL、slash command、subagent、仓库级 custom instructions,还是脚本集合。不是所有 prompt 文件都适合落到 Dominds skills。',
|
|
3173
|
+
'3. 提取可移植公共子集:至少提炼出 `name`、`description`、正文工作流;删掉平台专有 shell 注入、命令占位符、隐式工具假设。',
|
|
3174
|
+
'4. 判断是否需要 app 化:只要来源 skill 依赖脚本、外部二进制、MCP、专有工具权限、或希望供多个 app/team 复用,优先走 Dominds app 开发与安装流程,再在 skill 里引用该 app/toolset。',
|
|
3175
|
+
'5. 写入 rtws:把纯提示型技能放到 `.minds/skills/team_shared/<skill-id>/SKILL.cn.md` 或个人目录;若团队工作语言需要英文对齐,再补 `SKILL.en.md`。',
|
|
3176
|
+
'6. 配置权限:根据 skill 真实需要,更新 `.minds/team.yaml` 的成员 `toolsets` / `tools`,必要时安装/启用对应 Dominds app;不要只写 `allowed-tools` 就结束。',
|
|
3177
|
+
'7. 本地化:`cn` 文件作为中文语义基准;`en` 追随 `cn`。若公开来源只有英文,先提炼成符合本团队语义的中文基准,再回写英文对齐版。',
|
|
3178
|
+
'8. 验收:用 `dominds read <member-id> --only-prompt` 检查 skill 是否已注入 system prompt,并确认没有把不该暴露的工具/脚本假设写进正文。',
|
|
3179
|
+
]) +
|
|
3180
|
+
fmtHeader('从常见官方格式迁移时的判断口诀') +
|
|
3181
|
+
fmtList([
|
|
3182
|
+
'“只有 `name/description/body` 的标准 SKILL” → 最容易迁移,优先原样改写后落盘。',
|
|
3183
|
+
'“带 `allowed-tools` 但无脚本” → 可先作为纯提示 skill 引入,再人工配置 Dominds toolsets。',
|
|
3184
|
+
'“带脚本 / Bash allowlist / MCP / 动态注入命令” → 默认走 Dominds app 封装路径,不要只复制 markdown。',
|
|
3185
|
+
'“其实是全局仓库约束” → 更可能属于 persona / knowledge / env / AGENTS,不一定应该做成 skill。',
|
|
3186
|
+
]));
|
|
3187
|
+
}
|
|
3188
|
+
return (fmtHeader('.minds/skills/* (skills)') +
|
|
3189
|
+
fmtList([
|
|
3190
|
+
'Recommended layout: team-shared skills live at `.minds/skills/team_shared/<skill-id>/SKILL.cn.md` (with `SKILL.en.md` as the English counterpart); personal skills live at `.minds/skills/individual/<member-id>/<skill-id>/SKILL.cn.md`.',
|
|
3191
|
+
'Language selection: Dominds work language is currently `zh|en`, but skill filenames use the more portable `cn|en` suffixes. When work language is `zh`, Dominds prefers `SKILL.cn.md`; when it is `en`, Dominds prefers `SKILL.en.md`; both may fall back to `SKILL.md`. There is no cross-language fallback.',
|
|
3192
|
+
'Portable-first format: follow the common Agent Skills subset used by GitHub/Codex/Claude/skills.sh style ecosystems: `SKILL.md + YAML frontmatter`. The minimum required fields are `name` and `description`; the Markdown body is the actual skill prompt/workflow.',
|
|
3193
|
+
'Current Dominds behavior eagerly injects matched skills into the agent system prompt. That makes a Dominds skill closer to a workflow knowledge pack than to a lazily loaded marketplace artifact. Keep bodies tight, and move long references into sibling files that the body points to.',
|
|
3194
|
+
'For compatibility with public skill sources, Dominds accepts `allowed-tools`, `user-invocable`, and `disable-model-invocation`; however, in Dominds these fields are currently informational only. They do not grant tools and do not change runtime dispatch yet.',
|
|
3195
|
+
'The hard boundary: a skill is not a permission system. Real tool access still comes from `.minds/team.yaml` (`toolsets` / `tools`) and installed Dominds apps.',
|
|
3196
|
+
'A team-management agent may browse the web for public skill definitions (prefer official docs/repos/marketplace listings), or write skills directly by summarizing the team’s own repeatable workflows. Before importing, verify license, applicability, script/tool dependencies, and any hidden persona/permission assumptions.',
|
|
3197
|
+
'For public-network skills that rely on scripts or explicit tool contracts: do not ship them by copying Markdown alone. Preferred path: wrap execution capability into a Dominds app (app-host tools / toolsets / teammate contract), then keep the skill focused on workflow guidance and app/toolset references.',
|
|
3198
|
+
]) +
|
|
3199
|
+
fmtHeader('Recommended SKILL File Format') +
|
|
3200
|
+
fmtCodeBlock('markdown', [
|
|
3201
|
+
'---',
|
|
3202
|
+
'name: repo-debugger',
|
|
3203
|
+
'description: >',
|
|
3204
|
+
' Workflow for debugging repository-level build/test failures. Use for CI failures,',
|
|
3205
|
+
' dependency drift, or environment inconsistencies.',
|
|
3206
|
+
'allowed-tools:',
|
|
3207
|
+
' - read_file',
|
|
3208
|
+
' - readonly_shell',
|
|
3209
|
+
'user-invocable: true',
|
|
3210
|
+
'disable-model-invocation: false',
|
|
3211
|
+
'---',
|
|
3212
|
+
'',
|
|
3213
|
+
'# Repo Debugger',
|
|
3214
|
+
'',
|
|
3215
|
+
'## Entry',
|
|
3216
|
+
'- Confirm the failure signal and reproduction path first.',
|
|
3217
|
+
'- If shell is required, use only the Dominds tools/specialists actually granted by the team; never treat `allowed-tools` as auto-authorization.',
|
|
3218
|
+
'',
|
|
3219
|
+
'## Workflow',
|
|
3220
|
+
'1. Gather the error signal and recent changes.',
|
|
3221
|
+
'2. Minimize reproduction.',
|
|
3222
|
+
'3. Isolate root cause and propose verification.',
|
|
3223
|
+
]) +
|
|
3224
|
+
fmtHeader('Field Mapping from Public Skill Formats into Dominds') +
|
|
3225
|
+
fmtList([
|
|
3226
|
+
'`name` -> keep as-is. Continue using a short hyphen-case identifier and keep it aligned with the directory name `<skill-id>`.',
|
|
3227
|
+
'`description` -> keep as-is, but strengthen the “when to use / when not to use” trigger guidance. This is already the critical discovery field in GitHub/Codex/skills.sh ecosystems.',
|
|
3228
|
+
'SKILL body -> keep as the Dominds skill body. If it contains platform-specific commands (`/skill-name`, `Bash(git add:*)`, Claude `!command` injection, etc.), rewrite those parts into Dominds-executable semantics.',
|
|
3229
|
+
'`allowed-tools` -> informational only in Dominds. Map actual capability needs into a Dominds app/toolset and/or `.minds/team.yaml members.<id>.toolsets|tools`.',
|
|
3230
|
+
'`user-invocable` / `disable-model-invocation` -> preserved only as compatibility metadata for now; Dominds does not yet use them as dispatch switches.',
|
|
3231
|
+
'Anthropic subagent fields such as `tools`, `model`, or subagent identity -> do not import directly into a Dominds skill. Extract the reusable workflow body into a skill; move tool capability into a Dominds app/toolset; move persona/responsibility boundaries into `.minds/team/<id>/persona.*.md`.',
|
|
3232
|
+
'GitHub `copilot-instructions.md`, `*.instructions.md`, `AGENTS.md`, and `.prompt.md` files are usually plain Markdown instructions, not complete skills. When converting them, add `name` and `description`, then turn the body into a reusable workflow. If the content is actually repo-wide policy rather than a skill, keep it in persona/knowledge/env/AGENTS instead of forcing it into `skills`.',
|
|
3233
|
+
]) +
|
|
3234
|
+
fmtHeader('Operational Steps for a Team-Management Agent') +
|
|
3235
|
+
fmtList([
|
|
3236
|
+
'1. Search official sources first: GitHub Copilot Agent Skills docs, Claude Code skills/subagents docs, official repos, and marketplace/listing entries such as skills.sh.',
|
|
3237
|
+
'2. Classify the source: is it a standard SKILL, slash command, subagent, repo-wide custom instructions file, or a script bundle? Not every prompt file should become a Dominds skill.',
|
|
3238
|
+
'3. Extract the portable core: at minimum keep `name`, `description`, and the workflow body. Remove platform-specific shell injection, command placeholders, and hidden tool assumptions.',
|
|
3239
|
+
'4. Decide whether it must become an app: if the source relies on scripts, external binaries, MCP, privileged tools, or should be reused across multiple apps/teams, prefer the Dominds app path first.',
|
|
3240
|
+
'5. Write into the rtws: store pure prompt skills under `.minds/skills/team_shared/<skill-id>/SKILL.cn.md` or the personal directory; add `SKILL.en.md` when an English counterpart is needed.',
|
|
3241
|
+
'6. Configure permissions explicitly: update `.minds/team.yaml` member `toolsets` / `tools`, and install/enable the supporting Dominds app when required. Do not stop at `allowed-tools` metadata.',
|
|
3242
|
+
'7. Localize deliberately: use the `cn` file as the Chinese semantic baseline, then align `en` to it. If the public source is English-only, distill it into your team’s Chinese baseline first.',
|
|
3243
|
+
'8. Verify with `dominds read <member-id> --only-prompt` to confirm the skill is injected and does not claim tools/scripts the member does not actually have.',
|
|
3244
|
+
]) +
|
|
3245
|
+
fmtHeader('Fast Triage Rules When Importing Official Formats') +
|
|
3246
|
+
fmtList([
|
|
3247
|
+
'“Standard SKILL with `name/description/body` only” -> easiest path; usually port directly with light rewriting.',
|
|
3248
|
+
'“Has `allowed-tools` but no scripts” -> may enter as a pure prompt skill first, then map real Dominds toolsets manually.',
|
|
3249
|
+
'“Has scripts / Bash allowlists / MCP / dynamic command injection” -> default to the Dominds app packaging path; do not just copy the Markdown.',
|
|
3250
|
+
'“Actually repo-global policy” -> more likely belongs in persona / knowledge / env / AGENTS than in a skill.',
|
|
3251
|
+
]));
|
|
3252
|
+
}
|
|
3122
3253
|
function renderPrimingManual(language) {
|
|
3123
3254
|
if (language === 'zh') {
|
|
3124
3255
|
return (fmtHeader('.minds/priming/*(启动脚本)') +
|
|
@@ -4455,6 +4586,7 @@ exports.teamMgmtManualTool = {
|
|
|
4455
4586
|
'',
|
|
4456
4587
|
`\`team_mgmt_manual({ topics: ["team"] })\`:${topicTitle('team')} — .minds/team.yaml(团队花名册、工具集、目录权限入口)`,
|
|
4457
4588
|
`\`team_mgmt_manual({ topics: ["minds"] })\`:${topicTitle('minds')} — .minds/team/<id>/*(persona/knowledge/lessons 资产怎么写)`,
|
|
4589
|
+
`\`team_mgmt_manual({ topics: ["skills"] })\`:${topicTitle('skills')} — .minds/skills/*(公开 skill 格式迁移、字段映射、app 化边界)`,
|
|
4458
4590
|
`\`team_mgmt_manual({ topics: ["priming"] })\`:${topicTitle('priming')} — .minds/priming/*(启动脚本如何编写、维护与复用)`,
|
|
4459
4591
|
'`启动脚本修改后建议立即运行:`team_mgmt_validate_priming_scripts({})`',
|
|
4460
4592
|
`\`team_mgmt_manual({ topics: ["env"] })\`:${topicTitle('env')} — .minds/env.*.md(运行环境提示:在团队介绍之前注入)`,
|
|
@@ -4477,6 +4609,7 @@ exports.teamMgmtManualTool = {
|
|
|
4477
4609
|
'',
|
|
4478
4610
|
`\`team_mgmt_manual({ topics: ["team"] })\`: ${topicTitle('team')} — .minds/team.yaml (roster/toolsets/permissions entrypoint)`,
|
|
4479
4611
|
`\`team_mgmt_manual({ topics: ["minds"] })\`: ${topicTitle('minds')} — .minds/team/<id>/* (persona/knowledge/lessons assets)`,
|
|
4612
|
+
`\`team_mgmt_manual({ topics: ["skills"] })\`: ${topicTitle('skills')} — .minds/skills/* (public skill migration, field mapping, app boundary)`,
|
|
4480
4613
|
`\`team_mgmt_manual({ topics: ["priming"] })\`: ${topicTitle('priming')} — .minds/priming/* (how to author, maintain, and reuse startup scripts)`,
|
|
4481
4614
|
'After editing startup scripts, run: `team_mgmt_validate_priming_scripts({})`.',
|
|
4482
4615
|
`\`team_mgmt_manual({ topics: ["env"] })\`: ${topicTitle('env')} — .minds/env.*.md (runtime intro injected before Team Directory)`,
|
|
@@ -4549,6 +4682,10 @@ exports.teamMgmtManualTool = {
|
|
|
4549
4682
|
const content = renderMindsManual(language);
|
|
4550
4683
|
return ok(content, [{ type: 'environment_msg', role: 'user', content }]);
|
|
4551
4684
|
}
|
|
4685
|
+
if (want('skills')) {
|
|
4686
|
+
const content = renderSkillsManual(language);
|
|
4687
|
+
return ok(content, [{ type: 'environment_msg', role: 'user', content }]);
|
|
4688
|
+
}
|
|
4552
4689
|
if (want('priming')) {
|
|
4553
4690
|
const content = renderPrimingManual(language);
|
|
4554
4691
|
return ok(content, [{ type: 'environment_msg', role: 'user', content }]);
|
|
@@ -3,6 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.buildToolsetManualTools = buildToolsetManualTools;
|
|
4
4
|
exports.formatToolsetManualIntro = formatToolsetManualIntro;
|
|
5
5
|
const runtime_language_1 = require("../shared/runtime-language");
|
|
6
|
+
const team_1 = require("../team");
|
|
6
7
|
const render_1 = require("./manual/render");
|
|
7
8
|
const spec_1 = require("./manual/spec");
|
|
8
9
|
const registry_1 = require("./registry");
|
|
@@ -57,16 +58,20 @@ function buildManTool() {
|
|
|
57
58
|
argsValidation: 'dominds',
|
|
58
59
|
async call(_dlg, _caller, args) {
|
|
59
60
|
const language = (0, runtime_language_1.getWorkLanguage)();
|
|
61
|
+
const dynamicToolsetNames = await team_1.Team.listDynamicToolsetNamesForMember({
|
|
62
|
+
member: _caller,
|
|
63
|
+
taskDocPath: _dlg.taskDocPath,
|
|
64
|
+
});
|
|
60
65
|
// Get toolsetId from args
|
|
61
66
|
const toolsetId = args?.toolsetId;
|
|
62
67
|
if (!toolsetId) {
|
|
63
68
|
// When no toolsetId is provided, show all available toolsets
|
|
64
|
-
const availableToolsetNames = _caller.listResolvedToolsetNames();
|
|
69
|
+
const availableToolsetNames = _caller.listResolvedToolsetNames({ dynamicToolsetNames });
|
|
65
70
|
const list = availableToolsetNames.map((t) => `\`${t}\``).join(', ');
|
|
66
71
|
return language === 'zh' ? `可用的工具集:${list}` : `Available toolsets: ${list}`;
|
|
67
72
|
}
|
|
68
73
|
// Step 1: Get available toolsets for this caller (dynamic availability)
|
|
69
|
-
const availableToolsetNames = _caller.listResolvedToolsetNames();
|
|
74
|
+
const availableToolsetNames = _caller.listResolvedToolsetNames({ dynamicToolsetNames });
|
|
70
75
|
// Find closest match for fuzzy matching
|
|
71
76
|
const allToolsets = Object.keys((0, registry_1.listToolsets)());
|
|
72
77
|
const suggestion = findClosestToolset(toolsetId, allToolsets);
|
|
@@ -86,7 +91,11 @@ function buildManTool() {
|
|
|
86
91
|
: `Toolset '${toolsetId}' is not available to you. Available toolsets: ${list}`;
|
|
87
92
|
}
|
|
88
93
|
const availableToolNames = new Set(_caller
|
|
89
|
-
.listTools({
|
|
94
|
+
.listTools({
|
|
95
|
+
onMissingToolset: 'silent',
|
|
96
|
+
onMissingTool: 'silent',
|
|
97
|
+
dynamicToolsetNames,
|
|
98
|
+
})
|
|
90
99
|
.map((tool) => tool.name));
|
|
91
100
|
const rendered = (0, render_1.renderToolsetManual)({
|
|
92
101
|
toolsetId,
|