jev-router
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@jev-routerRoute this coding task: fix the failing auth test"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Jev-chooses-a-LLM
Jev Router for Cursor
Cursor executes. LLMs write and build. Jev decides how much intelligence the task deserves.
Honest promise: pick the cheapest available route likely to complete successfully under policy — not a mathematically optimal model.
TypeSafe Jev is a decision layer only (Choice / Score / Noul). It does not browse, write prose, edit files, or operate accounts. Env: TYPESAFE_API_KEY.
Personal smoke test
In the Cursor Agents window for this project, paste:
Find today's most popular public posts about TypeSafe Jev on X/Twitter (by views if available). Rank the top 5 and say why each is popular. Do not log in or post anything.Expected: Jev routes first (often BALANCED), then work uses web/research tools. In chat this is soft routing; for hard model switch use SDK --run.
Related MCP server: DeepMyst MCP Server
Chat vs SDK (read this)
Mode | What changes | What does not |
Cursor Chat + MCP | Parent calls | Parent chat model is not hot-swapped |
SDK | Jev decides tier, then | Needs |
Approval gates (production_deploy, financial_transaction, …) stop SDK runs unless you pass --approve.
What this product is
Mode | Enforcement | How routing works |
Chat (soft) | Rule + MCP + subagents | Parent calls |
SDK (hard) | Code path |
|
Hard routing rules (deterministic)
confidence < 0.70→ BALANCEDSecurity-sensitive → at least INTELLIGENCE
Financial / production deploy → INTELLIGENCE + human approval flag
Send/delete email, publish → approval required
Read-only research OK; simple reversible edit may be COST
COST fail → BALANCED → INTELLIGENCE → stop
Max 2 escalations; no infinite retry; no same-tier retry unless error says retry can succeed
Jev unavailable → BALANCED +
degradedRouting: true
What you need for a working system
This repo is enough to run end-to-end if you bring keys and follow the right mode.
Required for routing (Jev)
Node.js 20+ (22.13+ recommended; 22+ for
--use-system-caon Windows TLS issues)TYPESAFE_API_KEYin local.env(never commit)npm install && npm test && npm run demo
Required for real model switching (SDK)
CURSOR_API_KEYin.envnpm install @cursor/sdk(optionalDependency / peer)Run:
npx tsx sdk-runner/cli.ts --run "your task"
# Windows TLS/antivirus MITM:
# $env:NODE_OPTIONS="--use-system-ca"Cursor Chat (soft mode)
Symlink/copy this folder into
~/.cursor/plugins/local/Jev-chooses-a-LLM(seescripts/setup.sh)Enable MCP
jev-routerHonest limit: chat parent model is not hot-swapped. Jev decides the tier; the parent (e.g. Grok) may still execute unless you use SDK
--run.
Not included / not claimed
Your personal API keys
Guaranteed Cursor Router
auto-smart(account-dependent; we fall back to catalog models)Automatic X login / posting
Dollar cost when the plan does not expose billed cents
Clone
git clone https://github.com/Bodila51/Jev-chooses-a-LLM.git
cd jev-router-for-cursor
cp .env.example .env
# put TYPESAFE_API_KEY (and CURSOR_API_KEY for SDK --run) in .env — never commit it
npm install
npm test
npm run demoInstall
cd jev-router-for-cursor
cp .env.example .env # set TYPESAFE_API_KEY; CURSOR_API_KEY for live SDK
npm install
npm test
npm run demoCursor Chat plugin (local)
./scripts/setup.sh
# or: ln -s "$(pwd)" ~/.cursor/plugins/local/jev-router-for-cursorEnable the plugin in Cursor. Set variable TYPESAFE_API_KEY (Plugins → Configure) or export it for the MCP process. Restart Cursor if needed.
MCP only
npm run mcp
# or: npx tsx mcp/server.tsTools: jev_route, jev_dry_run, jev_status.
mcp.json wires the server for the plugin via ${CURSOR_PLUGIN_ROOT}.
Commands (Chat)
Command | Effect |
| Route only |
| Route then delegate to subagent |
| Dry-run routing |
| Skip Jev this turn |
| Config + hard rules |
SDK runner
# Dry-run (no CURSOR_API_KEY required for routing path)
npm run dry-run -- "Rename foo to bar in util.ts"
# Route only
npm run route -- "Research TS test runners"
# Status
npx tsx sdk-runner/cli.ts --status
# Live run (needs CURSOR_API_KEY and Node >= 22.13 for @cursor/sdk)
npx tsx sdk-runner/cli.ts --run "Fix the failing auth test"Programmatic:
import { runRoutedTask } from "./sdk-runner/index.js";
const result = await runRoutedTask({
facts: { task: "…", repoPresent: true, needsEdit: true },
dryRun: true,
});Models
Prefer Cursor Router:
auto-smart+optimize_for:cost|balanced|intelligencewhenCursor.models.list()shows it.If missing: pick real catalog IDs for the three tiers; never invent IDs.
Offline/static fallback in
config.example.jsondocumentscomposer-2.5only as a last resort label.
Cost
run.usage / agent.getUsage() — if cost is unavailable it is labeled unavailable. This product never invents dollar amounts.
Config
See config.example.json:
{
"enabled": true,
"defaultMode": "balanced",
"confidenceThreshold": 0.7,
"maximumEscalations": 2,
"maximumTaskCostUsd": 1.0,
"showRoutingTrace": true,
"logPromptContent": false,
"requireApprovalFor": ["send_email","delete_data","publish","production_deploy","financial_transaction"]
}Kill switch: "enabled": false or /jev-bypass.
Architecture
User task
├─ Chat: rule → MCP jev_route → subagent jev-{cost|balanced|intelligence}
└─ SDK: facts → Jev → policy → model catalog → Agent.create/send → escalateShared: shared/config.ts, shared/telemetry.ts, shared/redaction.ts
MCP: mcp/server.ts, mcp/router.ts, mcp/policy.ts, mcp/typesafe-client.ts
SDK: sdk-runner/*
Skills (optional)
email-triage— Jev classify/rank only; no sendresearch-rank— Jev ranks candidates; Cursor browses/writes
Testing
npm testUses mock TypeSafe client and fixtures (11 product scenarios). No real API keys required in CI.
Chat mode is soft-enforced (rule + agents). SDK mode is hard-enforced in code.
Security
See SECURITY.md. Never commit .env. Telemetry redacts secrets; prompts off by default.
Limitations
Chat cannot force the parent model ID; it delegates to subagents.
Live
@cursor/sdkneeds Node >= 22.13 andCURSOR_API_KEY.Without
TYPESAFE_API_KEY, dry-run/demo uses a deterministic mock; live Chat routing should set the key or expectdegradedRouting.Optional Gmail/X are not bundled OAuth apps — skills document the pattern only.
Uninstall
rm -f ~/.cursor/plugins/local/jev-router-for-cursor
# remove MCP entry / disable plugin in CursorLicense
MIT — see LICENSE.
This server cannot be deployed
Maintenance
Related MCP Connectors
AI model routing on your own vendor keys: pick the best model per prompt, or route and run it.
Pay-per-call ($0.01 USDC) model-routing for AI coding agents: which LLM to call, cost vs. quality.
Sourced AI-model pricing and capability data — compare and route to the cheapest capable model.
AI routing, memory, guardrails, and governance. Routes across Claude, GPT, Gemini.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceAutomatically selects the optimal LLM model for each task in Cursor IDE by analyzing query complexity, task type, and applying customizable routing strategies across 17 different AI models.2-

DeepMyst MCP Serverofficial
AlicenseNot gradedqualityDmaintenanceEnables intelligent LLM optimization and routing for Claude Desktop and HTTP clients, reducing token usage and automatically selecting the best model for each query.4MIT- FlicenseNot gradedqualityDmaintenanceAutomatically routes queries to the most suitable AI model based on task type, cost constraints, and performance needs, supporting multiple providers and customizable priorities.-
- AlicenseNot gradedqualityBmaintenanceEnables intelligent model selection for coding tasks by analyzing task type, scope, and difficulty, with fallback chains and host-specific mappings.523 npm1MIT