@baitong-dev/skills-mcp 0.0.5 → 0.0.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.js +7 -6
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -12,9 +12,9 @@ const mcp_helpers_1 = require("@baitong-dev/mcp-helpers");
|
|
|
12
12
|
// eslint-disable-next-line @typescript-eslint/no-require-imports
|
|
13
13
|
const yamlFront = require('yaml-front-matter');
|
|
14
14
|
const MCP_NAME = 'Skills MCP';
|
|
15
|
-
const MCP_VERSION = '0.0.
|
|
15
|
+
const MCP_VERSION = '0.0.6';
|
|
16
16
|
function getSkillsRootDir() {
|
|
17
|
-
const dir =
|
|
17
|
+
const dir = mcp_helpers_1.MCP_SKILLS_DIR;
|
|
18
18
|
if (!fs_1.default.existsSync(dir)) {
|
|
19
19
|
fs_1.default.mkdirSync(dir, {
|
|
20
20
|
recursive: true
|
|
@@ -73,7 +73,7 @@ function registerLoadSkill(server) {
|
|
|
73
73
|
.slice(0, 3)
|
|
74
74
|
.join(', ');
|
|
75
75
|
const hint = examples.length > 0 ? ` (e.g., ${examples}, ...)` : '';
|
|
76
|
-
server.registerTool('
|
|
76
|
+
server.registerTool('skill', {
|
|
77
77
|
description: `Load a specialized skill that provides domain-specific instructions and workflows.
|
|
78
78
|
|
|
79
79
|
When you recognize that a task matches one of the available skills listed below, use this tool to load the full skill instructions.
|
|
@@ -85,7 +85,7 @@ Available skills are listed in system-reminder messages in the conversation.
|
|
|
85
85
|
Invoke this tool to load a skill when a task matches one of the available skills listed.`,
|
|
86
86
|
inputSchema: zod_1.default.object({
|
|
87
87
|
skillName: zod_1.default.string().describe(`The name of the skill from available skills${hint}`),
|
|
88
|
-
toolInfo: mcp_helpers_1.
|
|
88
|
+
toolInfo: mcp_helpers_1.ToolInfoSchema
|
|
89
89
|
})
|
|
90
90
|
}, async ({ skillName }) => {
|
|
91
91
|
if (metadata.length === 0) {
|
|
@@ -115,10 +115,11 @@ Invoke this tool to load a skill when a task matches one of the available skills
|
|
|
115
115
|
const skillFilePath = getSkillFilePath(skillName);
|
|
116
116
|
const json = readSkillJson(skillFilePath);
|
|
117
117
|
const result = {
|
|
118
|
-
title: `Loaded
|
|
118
|
+
title: `Loaded ${skillName}`,
|
|
119
119
|
metadata: {
|
|
120
120
|
name: skillName,
|
|
121
|
-
dir: skillCwd
|
|
121
|
+
dir: skillCwd,
|
|
122
|
+
format: 'markdown'
|
|
122
123
|
},
|
|
123
124
|
output: `Base directory for this skill: ${skillCwd}
|
|
124
125
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@baitong-dev/skills-mcp",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.7",
|
|
4
4
|
"main": "./dist/index.js",
|
|
5
5
|
"bin": {
|
|
6
6
|
"@baitong-dev/skills-mcp": "./dist/index.js"
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"commander": "^14.0.3",
|
|
20
20
|
"yaml-front-matter": "^4.1.1",
|
|
21
21
|
"zod": "^4.3.4",
|
|
22
|
-
"@baitong-dev/mcp-helpers": "0.0.
|
|
22
|
+
"@baitong-dev/mcp-helpers": "0.0.8"
|
|
23
23
|
},
|
|
24
24
|
"devDependencies": {
|
|
25
25
|
"typescript": "^5.9.2"
|