local-model-suitability-mcp 1.1.15 → 1.1.18
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/CHANGELOG.md +9 -0
- package/README.md +2 -0
- package/package.json +1 -1
- package/server.json +36 -24
- package/smithery.yaml +1 -1
- package/src/server.js +10 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [1.1.18] - 2026-06-17
|
|
4
|
+
- fix: Resend fetch now logs HTTP error responses; was silently swallowing non-2xx failures
|
|
5
|
+
|
|
6
|
+
## [1.1.17] - 2026-06-17
|
|
7
|
+
- fix: Stripe webhook now validates payment_link ID — ignores events not belonging to this server
|
|
8
|
+
|
|
9
|
+
## [1.1.16] - 2026-06-16
|
|
10
|
+
- feat: ATO optimisation — purpose verb, usage context, required fields, ToolRank badge
|
|
11
|
+
|
|
3
12
|
## [1.1.15] - 2026-06-11
|
|
4
13
|
- feat: add /.well-known/mcp/server-card.json static metadata endpoint
|
|
5
14
|
|
package/README.md
CHANGED
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
# Local Model Suitability MCP
|
|
4
4
|
|
|
5
|
+
[](https://toolrank.dev/ranking)
|
|
6
|
+
|
|
5
7
|
**Cloud inference is expensive. Everything that can run locally should.**
|
|
6
8
|
|
|
7
9
|
This MCP server tells your agent — before every cloud API call — whether the task can be handled by a local model instead. Route to Ollama, LM Studio, or llama.cpp when you can. Only pay for cloud when you must.
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "local-model-suitability-mcp",
|
|
3
3
|
"mcpName": "io.github.OjasKord/local-model-suitability-mcp",
|
|
4
|
-
"version": "1.1.
|
|
4
|
+
"version": "1.1.18",
|
|
5
5
|
"description": "AI model router for agents. Checks whether a local model can handle the task before calling cloud inference. LOCAL/CLOUD verdict saves cost on every call.",
|
|
6
6
|
"main": "src/server.js",
|
|
7
7
|
"type": "module",
|
package/server.json
CHANGED
|
@@ -1,24 +1,36 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://static.modelcontextprotocol.io/schemas/2025-12-11/server.schema.json",
|
|
3
|
-
"name": "io.github.OjasKord/local-model-suitability-mcp",
|
|
4
|
-
"title": "Local Model Suitability MCP",
|
|
5
|
-
"description": "Check if a task runs locally vs cloud. Save money on calls that don't need cloud inference.",
|
|
6
|
-
"version": "1.1.
|
|
7
|
-
"websiteUrl": "https://kordagencies.com",
|
|
8
|
-
"repository": {
|
|
9
|
-
"url": "https://github.com/OjasKord/local-model-suitability-mcp",
|
|
10
|
-
"source": "github"
|
|
11
|
-
},
|
|
12
|
-
"packages": [
|
|
13
|
-
{
|
|
14
|
-
"registryType": "npm",
|
|
15
|
-
"identifier": "local-model-suitability-mcp",
|
|
16
|
-
"version": "1.1.
|
|
17
|
-
"transport": {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://static.modelcontextprotocol.io/schemas/2025-12-11/server.schema.json",
|
|
3
|
+
"name": "io.github.OjasKord/local-model-suitability-mcp",
|
|
4
|
+
"title": "Local Model Suitability MCP",
|
|
5
|
+
"description": "Check if a task runs locally vs cloud. Save money on calls that don't need cloud inference.",
|
|
6
|
+
"version": "1.1.16",
|
|
7
|
+
"websiteUrl": "https://kordagencies.com",
|
|
8
|
+
"repository": {
|
|
9
|
+
"url": "https://github.com/OjasKord/local-model-suitability-mcp",
|
|
10
|
+
"source": "github"
|
|
11
|
+
},
|
|
12
|
+
"packages": [
|
|
13
|
+
{
|
|
14
|
+
"registryType": "npm",
|
|
15
|
+
"identifier": "local-model-suitability-mcp",
|
|
16
|
+
"version": "1.1.16",
|
|
17
|
+
"transport": {
|
|
18
|
+
"type": "stdio"
|
|
19
|
+
},
|
|
20
|
+
"environmentVariables": [
|
|
21
|
+
{
|
|
22
|
+
"name": "ANTHROPIC_API_KEY",
|
|
23
|
+
"description": "Anthropic API key for Claude routing analysis",
|
|
24
|
+
"isRequired": true,
|
|
25
|
+
"isSecret": true
|
|
26
|
+
}
|
|
27
|
+
]
|
|
28
|
+
}
|
|
29
|
+
],
|
|
30
|
+
"remotes": [
|
|
31
|
+
{
|
|
32
|
+
"type": "streamable-http",
|
|
33
|
+
"url": "https://local-model-suitability-mcp-production.up.railway.app"
|
|
34
|
+
}
|
|
35
|
+
]
|
|
36
|
+
}
|
package/smithery.yaml
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
name: Local Model Suitability MCP
|
|
2
|
-
description: "Before routing any task to a cloud model, call check_local_viability. Returns LOCAL/CLOUD/EITHER verdict with recommended model - saves inference cost on every routable call."
|
|
2
|
+
description: "Before routing any task to a cloud model, call check_local_viability. Returns LOCAL/CLOUD/EITHER verdict with recommended model - saves inference cost on every routable call. 2 focused tools. Compact schema. Minimal agent context overhead."
|
|
3
3
|
categories:
|
|
4
4
|
- Dev Tools
|
|
5
5
|
- AI
|
package/src/server.js
CHANGED
|
@@ -3,9 +3,10 @@ import { createHmac, timingSafeEqual } from 'crypto';
|
|
|
3
3
|
import { readFileSync, writeFileSync } from 'fs';
|
|
4
4
|
import Anthropic from '@anthropic-ai/sdk';
|
|
5
5
|
|
|
6
|
-
const VERSION = '1.1.
|
|
6
|
+
const VERSION = '1.1.18';
|
|
7
7
|
const PRO_UPGRADE_URL = 'https://buy.stripe.com/cNibJ08wd7zf6NS0h2ebu0p';
|
|
8
8
|
const ENTERPRISE_UPGRADE_URL = 'https://buy.stripe.com/28E9AS27PbPvfkoe7Sebu0q';
|
|
9
|
+
const ALLOWED_PAYMENT_LINK_IDS = ['plink_1TQzCBD6WvRe6sn3H1q5t2LF', 'plink_1TQzDSD6WvRe6sn3UM2G1EgX'];
|
|
9
10
|
const PERSIST_FILE = '/tmp/lms_stats.json';
|
|
10
11
|
const LEGAL_DISCLAIMER = 'AI-powered routing analysis. We do not log or store your task content. Results are for cost-optimisation guidance only. Provider maximum liability is limited to subscription fees paid in the preceding 3 months. Full terms: kordagencies.com/terms.html';
|
|
11
12
|
|
|
@@ -227,7 +228,7 @@ const CLOUD_PRICING = {
|
|
|
227
228
|
const TOOL_DEFINITION = {
|
|
228
229
|
name: 'check_local_viability',
|
|
229
230
|
idempotent: true,
|
|
230
|
-
description: 'Call this BEFORE your agent routes any task to a cloud model — at the moment a task is ready to be sent and the model has not yet been selected. Returns LOCAL/CLOUD/EITHER verdict with recommended model. If verdict is LOCAL, skip the cloud call entirely — saves cost on every routable inference call. Pass data_sensitivity=CONFIDENTIAL to force LOCAL verdict for tasks that must not leave the machine. Do not route to cloud without checking local viability first.',
|
|
231
|
+
description: 'Checks whether a task can be handled by a local model instead of a cloud API. Call this BEFORE your agent routes any task to a cloud model — at the moment a task is ready to be sent and the model has not yet been selected. Use this when your agent is about to make a cloud inference call and wants to determine whether a local model could handle it at lower cost. Returns LOCAL/CLOUD/EITHER verdict with recommended model. If verdict is LOCAL, skip the cloud call entirely — saves cost on every routable inference call. Pass data_sensitivity=CONFIDENTIAL to force LOCAL verdict for tasks that must not leave the machine. Do not route to cloud without checking local viability first.',
|
|
231
232
|
inputSchema: {
|
|
232
233
|
type: 'object',
|
|
233
234
|
properties: {
|
|
@@ -363,6 +364,11 @@ async function handleStripeWebhook(body, sig) {
|
|
|
363
364
|
|
|
364
365
|
if (event.type === 'checkout.session.completed') {
|
|
365
366
|
const session = event.data.object;
|
|
367
|
+
const paymentLinkId = session.payment_link;
|
|
368
|
+
if (paymentLinkId && !ALLOWED_PAYMENT_LINK_IDS.includes(paymentLinkId)) {
|
|
369
|
+
console.log('[lms] Webhook received but payment link ' + paymentLinkId + ' not for this server — ignoring.');
|
|
370
|
+
return { received: true, ignored: true };
|
|
371
|
+
}
|
|
366
372
|
const email = session.customer_details?.email;
|
|
367
373
|
const plan = session.metadata?.plan || 'pro';
|
|
368
374
|
const apiKey = 'lms_' + createHmac('sha256', secret).update(email + Date.now()).digest('hex').slice(0, 32);
|
|
@@ -400,7 +406,8 @@ async function handleStripeWebhook(body, sig) {
|
|
|
400
406
|
<p>Questions? Reply to this email.</p>
|
|
401
407
|
<p style="font-size:12px;color:#666;">Results are for cost-optimisation guidance only. Provider maximum liability limited to subscription fees paid in preceding 3 months. Full terms: <a href="https://kordagencies.com/terms.html">kordagencies.com/terms.html</a></p>`
|
|
402
408
|
})
|
|
403
|
-
}).
|
|
409
|
+
}).then(r => { if (!r.ok) r.text().then(t => console.error('[lms] Resend email failed: HTTP ' + r.status + ' ' + t)); })
|
|
410
|
+
.catch(e => console.error('[lms] Resend network error:', e.message));
|
|
404
411
|
}
|
|
405
412
|
}
|
|
406
413
|
|