@geohar/opencode-svg-mcp 0.10.7 → 0.11.1
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 +1 -1
- package/instructions.txt +7 -3
- package/package.json +4 -3
package/dist/index.js
CHANGED
|
@@ -35,7 +35,7 @@ const DEFAULT_GRACE = "1h";
|
|
|
35
35
|
* shipped stale at 0.2.6 for several releases, so fresh installs pinned to a
|
|
36
36
|
* years-old server. Override per-launch with the `version` option or
|
|
37
37
|
* `$SVG_MCP_VERSION`. */
|
|
38
|
-
const SVG_MCP_TOOL_VERSION = "0.
|
|
38
|
+
const SVG_MCP_TOOL_VERSION = "0.11.1";
|
|
39
39
|
// ── the diagram-authoring directive ────────────────────────────────
|
|
40
40
|
// Appended to the system prompt so the agent reaches for svg-mcp's tools instead of
|
|
41
41
|
// hand-writing SVG XML (the analogue of the Claude Code plugin's SessionStart
|
package/instructions.txt
CHANGED
|
@@ -13,9 +13,13 @@ topic you have to remember to think about. That's deliberate: you will not remem
|
|
|
13
13
|
|
|
14
14
|
`create_session` is on the tools: call it ONCE per drawing task, then pass its
|
|
15
15
|
`session_id` on EVERY svg-mcp call that follows (each tool's schema marks the argument).
|
|
16
|
-
Keep the id in the conversation — drawings persist under it
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
Keep the id in the conversation — drawings persist under it for the rest of the task.
|
|
17
|
+
A session_id-less call fails with this same guidance: that's the cue you skipped the
|
|
18
|
+
mint, not a bug to route around — run create_session, retry with the id.
|
|
19
|
+
The same goes for documents: there is no "current" one, so pass the `document_id` you got
|
|
20
|
+
from `create_document` on every call that acts on it, even when only one is open.
|
|
21
|
+
The calls shown below omit `session_id` and `document_id` for brevity; every real call
|
|
22
|
+
passes both.
|
|
19
23
|
|
|
20
24
|
### 1. About to write `<svg`, or hand-edit XML inside one? That's the cue.
|
|
21
25
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@geohar/opencode-svg-mcp",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.1",
|
|
4
4
|
"description": "OpenCode plugin: run the svg-mcp MCP server via sharedserver and register its endpoint with OpenCode. Stands down when a combiner already serves svg-mcp.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -12,9 +12,9 @@
|
|
|
12
12
|
"LICENSE"
|
|
13
13
|
],
|
|
14
14
|
"scripts": {
|
|
15
|
-
"build": "tsc",
|
|
15
|
+
"build": "node ./node_modules/typescript/bin/tsc",
|
|
16
16
|
"clean": "rm -rf dist",
|
|
17
|
-
"typecheck": "tsc --noEmit",
|
|
17
|
+
"typecheck": "node ./node_modules/typescript/bin/tsc --noEmit",
|
|
18
18
|
"prepack": "node -e \"require('fs').copyFileSync('../../CLAUDE.md.example', './instructions.txt')\"",
|
|
19
19
|
"prepublishOnly": "npm run clean && npm run build"
|
|
20
20
|
},
|
|
@@ -47,6 +47,7 @@
|
|
|
47
47
|
"devDependencies": {
|
|
48
48
|
"@opencode-ai/plugin": "^1.3.0",
|
|
49
49
|
"@types/node": "^22.0.0",
|
|
50
|
+
"@typescript/native": "npm:typescript@^7.0.2",
|
|
50
51
|
"typescript": "^5.6.0"
|
|
51
52
|
},
|
|
52
53
|
"engines": {
|