edgegate-mcp 0.1.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/LICENSE +21 -0
- package/README.md +82 -0
- package/bin/edgegate-mcp +2 -0
- package/bin/edgegate-mcp-install +2 -0
- package/dist/client.d.ts +54 -0
- package/dist/client.js +103 -0
- package/dist/client.js.map +1 -0
- package/dist/install.d.ts +1 -0
- package/dist/install.js +118 -0
- package/dist/install.js.map +1 -0
- package/dist/server.d.ts +1 -0
- package/dist/server.js +113 -0
- package/dist/server.js.map +1 -0
- package/dist/tools/check_status.d.ts +15 -0
- package/dist/tools/check_status.js +48 -0
- package/dist/tools/check_status.js.map +1 -0
- package/dist/tools/create_pipeline.d.ts +68 -0
- package/dist/tools/create_pipeline.js +74 -0
- package/dist/tools/create_pipeline.js.map +1 -0
- package/dist/tools/get_audit_report.d.ts +15 -0
- package/dist/tools/get_audit_report.js +46 -0
- package/dist/tools/get_audit_report.js.map +1 -0
- package/dist/tools/get_report.d.ts +15 -0
- package/dist/tools/get_report.js +53 -0
- package/dist/tools/get_report.js.map +1 -0
- package/dist/tools/run_gate.d.ts +18 -0
- package/dist/tools/run_gate.js +48 -0
- package/dist/tools/run_gate.js.map +1 -0
- package/dist/tools/setup_github_action.d.ts +18 -0
- package/dist/tools/setup_github_action.js +69 -0
- package/dist/tools/setup_github_action.js.map +1 -0
- package/dist/tools/setup_workspace.d.ts +18 -0
- package/dist/tools/setup_workspace.js +73 -0
- package/dist/tools/setup_workspace.js.map +1 -0
- package/dist/types.d.ts +64 -0
- package/dist/types.js +2 -0
- package/dist/types.js.map +1 -0
- package/dist/version.d.ts +2 -0
- package/dist/version.js +3 -0
- package/dist/version.js.map +1 -0
- package/package.json +49 -0
- package/plugin.json +26 -0
- package/skills/edgegate-audit.md +17 -0
- package/skills/edgegate-gate.md +15 -0
- package/skills/edgegate-init.md +35 -0
- package/skills/edgegate-status.md +14 -0
package/package.json
ADDED
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "edgegate-mcp",
|
|
3
|
+
"version": "0.1.1",
|
|
4
|
+
"description": "MCP server for EdgeGate — set up edge-AI regression gates from Claude Code, Cursor, or Claude Desktop.",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"engines": {
|
|
8
|
+
"node": ">=20"
|
|
9
|
+
},
|
|
10
|
+
"bin": {
|
|
11
|
+
"edgegate-mcp": "./bin/edgegate-mcp",
|
|
12
|
+
"edgegate-mcp-install": "./bin/edgegate-mcp-install"
|
|
13
|
+
},
|
|
14
|
+
"main": "./dist/server.js",
|
|
15
|
+
"files": [
|
|
16
|
+
"dist/",
|
|
17
|
+
"bin/",
|
|
18
|
+
"skills/",
|
|
19
|
+
"plugin.json",
|
|
20
|
+
"README.md",
|
|
21
|
+
"LICENSE"
|
|
22
|
+
],
|
|
23
|
+
"scripts": {
|
|
24
|
+
"build": "tsc",
|
|
25
|
+
"dev": "tsx src/server.ts",
|
|
26
|
+
"test": "vitest run",
|
|
27
|
+
"test:watch": "vitest",
|
|
28
|
+
"lint": "eslint 'src/**/*.ts'",
|
|
29
|
+
"format": "prettier --write 'src/**/*.ts'",
|
|
30
|
+
"prepublishOnly": "npm run build && npm test && npm run lint"
|
|
31
|
+
},
|
|
32
|
+
"dependencies": {
|
|
33
|
+
"@modelcontextprotocol/sdk": "^1.29.0",
|
|
34
|
+
"undici": "^6.0.0",
|
|
35
|
+
"zod": "^3.23.0",
|
|
36
|
+
"zod-to-json-schema": "^3.23.0"
|
|
37
|
+
},
|
|
38
|
+
"devDependencies": {
|
|
39
|
+
"@types/node": "^20.0.0",
|
|
40
|
+
"@typescript-eslint/eslint-plugin": "^7.0.0",
|
|
41
|
+
"@typescript-eslint/parser": "^7.0.0",
|
|
42
|
+
"eslint": "^8.57.0",
|
|
43
|
+
"msw": "^2.3.0",
|
|
44
|
+
"prettier": "^3.0.0",
|
|
45
|
+
"tsx": "^4.7.0",
|
|
46
|
+
"typescript": "^5.4.0",
|
|
47
|
+
"vitest": "^1.6.0"
|
|
48
|
+
}
|
|
49
|
+
}
|
package/plugin.json
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "edgegate",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Edge-AI regression gates from Claude Code — set up CI, run benchmarks, and fetch audit PDFs from any prompt.",
|
|
5
|
+
"author": "Frozo / EdgeGate",
|
|
6
|
+
"homepage": "https://edgegate.frozo.ai",
|
|
7
|
+
"repository": "https://github.com/frozo-ai/edgegate-mcp",
|
|
8
|
+
"license": "MIT",
|
|
9
|
+
"mcpServers": {
|
|
10
|
+
"edgegate": {
|
|
11
|
+
"type": "stdio",
|
|
12
|
+
"command": "npx",
|
|
13
|
+
"args": ["-y", "edgegate-mcp"],
|
|
14
|
+
"env": {
|
|
15
|
+
"EDGEGATE_API_KEY": "${EDGEGATE_API_KEY}",
|
|
16
|
+
"EDGEGATE_API_URL": "${EDGEGATE_API_URL:-https://edgegateapi.frozo.ai}"
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"skills": [
|
|
21
|
+
"skills/edgegate-init.md",
|
|
22
|
+
"skills/edgegate-gate.md",
|
|
23
|
+
"skills/edgegate-status.md",
|
|
24
|
+
"skills/edgegate-audit.md"
|
|
25
|
+
]
|
|
26
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: edgegate-audit
|
|
3
|
+
description: Fetch the signed audit PDF for a completed EdgeGate run. Use for compliance records or to attach to a release.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# /edgegate-audit
|
|
7
|
+
|
|
8
|
+
The user needs the audit PDF for a specific run (for SOC2, ISO, internal compliance, or to attach to a release).
|
|
9
|
+
|
|
10
|
+
1. If they gave you a `run_id`, call `edgegate_get_audit_report` directly.
|
|
11
|
+
2. If not, call `edgegate_get_report` and ask which run they want.
|
|
12
|
+
3. Return the signed URL. Remind the user that:
|
|
13
|
+
- URLs are time-limited (~1h).
|
|
14
|
+
- The PDF contains the signed evidence bundle hash, device fingerprints, and gate decisions.
|
|
15
|
+
- Save it locally if they need a durable record.
|
|
16
|
+
|
|
17
|
+
If the run is still in-flight or the report hasn't generated yet, you'll get a 404. Tell the user to wait 1-2 minutes and retry.
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: edgegate-gate
|
|
3
|
+
description: Trigger an EdgeGate run on an existing pipeline. Use when the user says "run the gates" or "test this PR on devices".
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# /edgegate-gate
|
|
7
|
+
|
|
8
|
+
The user wants to trigger an EdgeGate run.
|
|
9
|
+
|
|
10
|
+
1. If you don't know the `workspace_id`, call `edgegate_setup_workspace` first.
|
|
11
|
+
2. If you don't know the `pipeline_id`, ask the user. (In v1.0 there is no `list_pipelines` tool; tell them to find it in the dashboard at `https://edgegate.frozo.ai/workspace/{id}/pipelines`.)
|
|
12
|
+
3. Call `edgegate_run_gate` with the workspace_id + pipeline_id. Optionally accept a `model_artifact_id` override.
|
|
13
|
+
4. Tell the user the run_id and that they can check status with `/edgegate-status`.
|
|
14
|
+
|
|
15
|
+
If you get a 409, that means another run is already in flight (workspace_concurrency=1). Tell the user to wait for it to finish, or check status.
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: edgegate-init
|
|
3
|
+
description: Walk a new EdgeGate user from zero to a running CI gate. Wire the workspace, generate a pipeline from a model, and (optionally) set up the GitHub Action.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# /edgegate-init
|
|
7
|
+
|
|
8
|
+
You are an assistant onboarding the user to EdgeGate. EdgeGate is a SaaS that runs AI model regression tests on real Snapdragon devices and produces signed evidence bundles to gate CI/CD pipelines.
|
|
9
|
+
|
|
10
|
+
Goal of this skill: take the user from "I have a model file" to "every PR is automatically gated by EdgeGate" in under 5 minutes.
|
|
11
|
+
|
|
12
|
+
## Steps
|
|
13
|
+
|
|
14
|
+
1. **Confirm workspace.** Call `edgegate_setup_workspace` with no args. Present the list. Ask the user which one to use; if they say "the first one", pick `result[0].id`. Confirm before continuing.
|
|
15
|
+
|
|
16
|
+
2. **Define the pipeline.** Ask the user:
|
|
17
|
+
- "Which model file do you want to gate? (path or artifact_id)"
|
|
18
|
+
- "Which Snapdragon devices? (default: Samsung Galaxy S24, Galaxy S23)"
|
|
19
|
+
- "Which gates? Common defaults: inference_time_ms ≤ 10, peak_memory_mb ≤ 150"
|
|
20
|
+
|
|
21
|
+
If they hand you a file path (e.g. `./model.onnx`), tell them they need to upload it via the dashboard first to get an artifact_id (the MCP tool does not handle uploads in v1.0). Link: `https://edgegate.frozo.ai/workspace/{workspace_id}/models`.
|
|
22
|
+
|
|
23
|
+
If they hand you an artifact_id, proceed to `edgegate_create_pipeline`.
|
|
24
|
+
|
|
25
|
+
3. **Trigger the first run.** Call `edgegate_run_gate` with the workspace_id + new pipeline_id. Tell the user the run_id. Note that runs take 3-5 min per device.
|
|
26
|
+
|
|
27
|
+
4. **Wire CI.** Ask "Should I set up the GitHub Action so every PR runs this gate?" — if yes, call `edgegate_setup_github_action`. Present the YAML and `gh` commands; tell the user to commit the YAML and run the `gh` commands.
|
|
28
|
+
|
|
29
|
+
5. **Confirm.** Tell the user what's now set up: workspace `<name>`, pipeline `<name>`, run `<id>` in flight, and (if applicable) GitHub Action wired.
|
|
30
|
+
|
|
31
|
+
## Failure modes
|
|
32
|
+
|
|
33
|
+
- **No workspaces.** The API key may have been revoked. Direct the user to `https://edgegate.frozo.ai/workspace/<id>/settings#api-keys` to generate a fresh key.
|
|
34
|
+
- **Workspace is on Free tier.** Pipelines per month are capped. Direct them to `/pricing`.
|
|
35
|
+
- **Cell count > 25.** Reduce models × devices.
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: edgegate-status
|
|
3
|
+
description: Check on an in-flight or recent EdgeGate run. Shows status, per-device metrics, gate pass/fail.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# /edgegate-status
|
|
7
|
+
|
|
8
|
+
The user wants to know how a run is doing.
|
|
9
|
+
|
|
10
|
+
1. If they gave you a `run_id`, call `edgegate_check_status` directly.
|
|
11
|
+
2. If they did NOT give you a run_id, call `edgegate_get_report` to show the last 10 runs, then ask which one they meant.
|
|
12
|
+
3. Render the result. If the run is FAILED, lead with the violating gate and the actual value — don't bury it.
|
|
13
|
+
|
|
14
|
+
For PASSED runs, briefly summarize the metrics so the user has the numbers handy for a PR comment.
|