@scayver/specshot-mcp-server 0.10.0 → 0.13.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 +104 -4
- package/dist/build-standard.js +5034 -53
- package/dist/index.js +36 -13
- package/dist/skills.js +476 -0
- package/dist/tool-descriptions.js +87 -0
- package/dist/tools/agent-loop.js +81 -0
- package/dist/tools/brand.js +2 -1
- package/dist/tools/canvas.js +5 -4
- package/dist/tools/concepts.js +58 -5
- package/dist/tools/images.js +67 -0
- package/dist/tools/inspiration.js +2 -1
- package/dist/tools/messages.js +12 -6
- package/dist/tools/prototype.js +27 -0
- package/dist/tools/render.js +53 -0
- package/dist/tools/review.js +27 -0
- package/dist/tools/site.js +78 -0
- package/dist/tools/skills.js +20 -0
- package/dist/tools/state.js +33 -0
- package/dist/tools/wireframe.js +41 -21
- package/dist/tools/wordpress.js +24 -0
- package/dist/tools/workspace.js +26 -22
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -9,7 +9,16 @@ import { registerWireframeTools } from "./tools/wireframe.js";
|
|
|
9
9
|
import { registerMessageTools } from "./tools/messages.js";
|
|
10
10
|
import { registerWorkspaceTools } from "./tools/workspace.js";
|
|
11
11
|
import { registerCanvasTools } from "./tools/canvas.js";
|
|
12
|
-
import {
|
|
12
|
+
import { registerStateTools } from "./tools/state.js";
|
|
13
|
+
import { registerImageTools } from "./tools/images.js";
|
|
14
|
+
import { registerWordPressTools } from "./tools/wordpress.js";
|
|
15
|
+
import { registerSkillTools } from "./tools/skills.js";
|
|
16
|
+
import { registerReviewTools } from "./tools/review.js";
|
|
17
|
+
import { registerPrototypeTools } from "./tools/prototype.js";
|
|
18
|
+
import { registerRenderTools } from "./tools/render.js";
|
|
19
|
+
import { registerAgentLoopTools } from "./tools/agent-loop.js";
|
|
20
|
+
import { registerSiteTools } from "./tools/site.js";
|
|
21
|
+
import { CONNECT_INSTRUCTIONS, MCP_PROMPTS } from "./build-standard.js";
|
|
13
22
|
import { createRequire } from "node:module";
|
|
14
23
|
/**
|
|
15
24
|
* Read the version from package.json instead of restating it. A hardcoded copy
|
|
@@ -45,18 +54,21 @@ if (!token) {
|
|
|
45
54
|
console.error(`[specshot-mcp] v${VERSION} -> ${baseUrl}${process.env.SPECSHOT_APP_URL ? "" : " (default; set SPECSHOT_APP_URL to override)"}`);
|
|
46
55
|
const client = new SpecShotClient(baseUrl, token);
|
|
47
56
|
// instructions travel with the connection: a client surfaces them to the model
|
|
48
|
-
// as system context, so the agent knows
|
|
49
|
-
//
|
|
50
|
-
//
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
//
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
})
|
|
57
|
+
// as system context, so the agent knows the law before it reads a single tool
|
|
58
|
+
// description. The short law fits clients that truncate long instructions, and
|
|
59
|
+
// names the design_law prompt that carries the whole of it; the short page
|
|
60
|
+
// workflow and where the design skills are follow it.
|
|
61
|
+
const server = new McpServer({ name: "specshot", version: VERSION }, { instructions: CONNECT_INSTRUCTIONS });
|
|
62
|
+
// The same prompts the hosted endpoint serves, with the same bodies: the whole
|
|
63
|
+
// design law, the build standard, the premium bar, the Etch rules, the protocol
|
|
64
|
+
// and the rest. Generated from the shared source (build-standard.ts says how), so
|
|
65
|
+
// the short law never names a prompt this transport does not have. Registered
|
|
66
|
+
// before the tools so they list first.
|
|
67
|
+
for (const prompt of MCP_PROMPTS) {
|
|
68
|
+
server.registerPrompt(prompt.name, { title: prompt.title, description: prompt.description }, () => ({
|
|
69
|
+
messages: [{ role: "user", content: { type: "text", text: prompt.body } }],
|
|
70
|
+
}));
|
|
71
|
+
}
|
|
60
72
|
/**
|
|
61
73
|
* whoami: ground truth about THIS process, so an agent never has to infer what
|
|
62
74
|
* it is running from a version written in a doc or remembered from a past
|
|
@@ -81,6 +93,7 @@ server.tool("whoami", "Confirm what you are actually connected to: the running s
|
|
|
81
93
|
},
|
|
82
94
|
],
|
|
83
95
|
}));
|
|
96
|
+
registerStateTools(server, client);
|
|
84
97
|
registerConceptTools(server, client);
|
|
85
98
|
registerBrandTools(server, client);
|
|
86
99
|
registerInspirationTools(server, client);
|
|
@@ -88,5 +101,15 @@ registerWireframeTools(server, client);
|
|
|
88
101
|
registerMessageTools(server, client);
|
|
89
102
|
registerWorkspaceTools(server, client);
|
|
90
103
|
registerCanvasTools(server, client);
|
|
104
|
+
registerImageTools(server, client);
|
|
105
|
+
registerWordPressTools(server, client);
|
|
106
|
+
registerSkillTools(server);
|
|
107
|
+
// The canvas slices (docs/CANVAS-DOOP-PLAN.md 4.0). Each slice registers in its own file only.
|
|
108
|
+
registerReviewTools(server, client);
|
|
109
|
+
registerPrototypeTools(server, client);
|
|
110
|
+
registerRenderTools(server, client);
|
|
111
|
+
registerAgentLoopTools(server, client);
|
|
112
|
+
// Whole-site generation for agents (docs/WHOLE-SITE-GENERATION-PLAN.md, "Agents over MCP").
|
|
113
|
+
registerSiteTools(server, client);
|
|
91
114
|
const transport = new StdioServerTransport();
|
|
92
115
|
await server.connect(transport);
|