Skip to main content
Glama
jev-super-agent
by Kadihx

jev-x-kit

CI MIT License TypeScript MCP Compatible Node >=22.5 Tests: 27/27

Universal TypeSafe Jev / OpenJev autonomous decision, deep research, ultra-planning & self-improving agent framework — packaged as a Claude Code plugin/skill, an MCP server, and a standalone CLI.

Built for Claude Code, Cursor, Codex, OpenCode, Continue.dev, Ollama / vLLM, and every MCP-compatible agent. Runs 100% free and offline: no API key, no GPU, no cloud required.

Install as a Claude Code plugin (30 seconds)

git clone https://github.com/Kadihx/jev-x-kit.git
cd jev-x-kit && npm install && npm run build

Then point Claude Code at this folder as a plugin (.claude-plugin/plugin.json is already wired up: it registers the jev skill and the jev-super-agent MCP server with 21 tools). See skills/jev/SKILL.md for the command cheat-sheet Claude reads to decide when to reach for Jev instead of free-text reasoning.

Related MCP server: jev-mcp

Why this exists (6 root problems)

  1. Latency wall — LLMs take 3–30s for a simple yes/no routing decision.

  2. Token cost explosion — agent loops burn $10–$50 per session on micro-decisions.

  3. JSON schema breakage — free-text models hallucinate parameters and break parsers.

  4. Context rot — "summarized" logs hallucinate file paths, commands and error codes.

  5. Single-pass blind spot — a model can't adversarially review its own plan.

  6. Vendor lock-in — paid APIs only, no offline path.

What this kit does

It inserts a System 1 decision layer in front of every micro-decision:

  • Non-autoregressive primitives: Choice (up to 255 options), Score (fractional 1–10), Noul (calibrated probability in [0, 1]) — never free text, schema-validated, zero output-token cost.

  • "BELKİ" Gatekeeper: confidence > 0.85 executes directly at $0 LLM cost; 0.60–0.85 splits into speculative sub-decisions; below 0.60 escalates to System 2 or a human.

  • Speculative fan-out: N independent questions are evaluated in one parallel pass — extra questions add no latency and no cost.

  • Winnow lossless compaction: irrelevant log lines are deleted, never summarized. File paths, commands, error codes, URLs and diff headers are always preserved byte-identically.

  • Adversarial red-teaming: a hostile reviewer generates concrete anti-theses; the Jev loop arbitrates the safest route with residual risks.

  • RLVR self-improvement: tsc + npm test pass/fail records ±1 rewards into .jev-skill-memory.json; verified wins auto-tune the gatekeeper thresholds.

Quickstart (zero config, offline)

npm install
npm run build
npm test            # 27 unit tests (core 20 + datacenter 7) on the deterministic offline simulator
npm run test:hub    # 7 datacenter tests (source registry, robots, license engine, FTS store, query tiers)
npm run smoke       # full end-to-end MCP smoke test (50 checks)

Everything works immediately with no network, no GPU and no API key — the deterministic offline simulator keeps every primitive valid and schema-safe.

MCP server setup

Add this to your agent's MCP config (mcp-config.json, claude_desktop_config.json, opencode.json, Continue.dev, Codex):

{
  "mcpServers": {
    "jev-super-agent": {
      "command": "node",
      "args": ["C:\\path\\to\\jev-x-kit\\dist\\index.js"],
      "env": {
        "JEV_BACKEND_PROVIDER": "auto",
        "OPENJEV_BASE_URL": "http://localhost:8000/v1",
        "JEV_LLM_BASE_URL": "http://localhost:11434/v1"
      }
    }
  }
}

Free local backends (auto-detected in order)

Backend

Command

Cost

OpenJev on vLLM (razorback16/openjev)

docker run --gpus all -p 8000:8000 razorback16/openjev

$0

LayA (NandhaKishorM/laya)

python -m laya.serve --port 8000

$0

Ollama (System-2 LLM for planner/red-team)

ollama serve (default :11434)

$0

Vercel AI Gateway free tier

set VERCEL_AI_GATEWAY_KEY

free tier

TypeSafe Jev native

TYPESAFE_JEV_API_KEY + TYPESAFE_JEV_NATIVE=1 (required — see below)

$0.042 / 1M in, $0 output

Set JEV_BACKEND_PROVIDER to auto (default), typesafe_jev, openjev_local, laya_local or heuristic (fully offline).

TYPESAFE_JEV_NATIVE=1 is not optional for the hosted API. TypeSafe's real API is a single POST /v1/systemone endpoint (state + named questions in, named answers + token usage out) — there is no /chat/completions endpoint at api.typesafe.ai, so without the native flag the chat-proxy transport 404s and every call silently falls back to the offline heuristic. Verified live on 2026-09-21: a 12-candidate jev_research run cost $0.00016874 in real TypeSafe API usage. Note the hosted API only answers Choice/Score/Noul — it has no chat/completion endpoint, so point JEV_LLM_BASE_URL at Ollama/vLLM/etc. regardless, for planner/red-team/research-synthesis text generation.

CLI (scriptable, zero MCP client needed)

node dist/cli.js info                                    # backend + chain diagnosis
node dist/cli.js decide "run tsc first?" --options "yes,no"
node dist/cli.js plan "Ship an offline decision layer" --preset software-architecture
node dist/cli.js redteam "We cache everything forever"
node dist/cli.js compact --file build.log --goal "port binding error"
node dist/cli.js audit .
node dist/cli.js guardrail --tool bash --args "rm -rf /"
node dist/cli.js verify --cwd .                          # RLVR: tsc + tests -> reward
node dist/cli.js label --file data.jsonl --mode score
node dist/cli.js memory report
node dist/cli.js features                                # 20 enterprise features

MCP tools (28)

Tool

Module

What it does

jev_evaluate

1

Fan-out batch of Choice/Score/Noul in one pass

jev_decide

1

"BELKİ" gatekeeper: execute / speculative / system2

jev_plan

2

Ultra-planning: hypothesis + anti-thesis + 4-dim Jev score

jev_redteam

3

Adversarial dual loop: anti-theses, severity, arbitration

jev_audit

4

360° scan: architecture / security / marketing / legal / budget

jev_research

5a

4 parallel channels: web / academic / code / social + Jev re-rank

jev_compact

5b

Winnow lossless context compaction (delete, never summarize)

jev_github_mine

6

License audit + clean-room originality guard (5-gram Jaccard)

jev_label_dataset

7

Auto-label rows at $0/row into JSONL

jev_preference_pairs

7

RLCD/DPO chosen/rejected pairs for local models

jev_distill_recipe

7

LoRA distillation recipe + axolotl YAML (Qwen2.5-0.5B / ModernBERT-421M)

jev_verify

8

RLVR: run tsc/tests, record reward, auto-tune thresholds

jev_memory

8

Skill memory report / optimize / record / state

jev_dispatch

9

Chief-of-staff role routing from shared memory

jev_guardrail

9

AutoMode pre-execution gate (allow / ask / block)

jev_privacy_sanitize

10.7

Local PII/secret masking before external calls

jev_rerank

10.12

RAG noise filter + top-K re-ranking

jev_edge_qa

10.11

Deterministic edge-case test matrix

jev_pr_gate

10.16

PR gatekeeper: secrets, breaking exports, leftovers

jev_features

10

20-feature catalog with honest status

jev_backend_info

infra

Backend chain, pricing, policy, presets, paths

hub_crawl

research

Politely crawl the 11-source personal-development knowledge base

hub_query

research

FTS5 + Jev-ranked, cited answers from the crawled hub

hub_stats

research

Doc counts / word counts per source

hub_ingest_rendered

research

Browser-render bridge: feed a page rendered by the calling agent's own browser tool (e.g. Claude Code's claude-in-chrome) through the same extract/license/store pipeline — for client-rendered sources a plain fetch can't read

jev_compact_transcript

5b

Winnow for structured message transcripts: pairs each tool call with its result by id, decides per-pair (keep / truncate / drop), anchors override a "drop" verdict

jev_calibration_check

new

Feeds known-answer Choice cases through the gatekeeper; compares claimed confidence to real accuracy per threshold bucket and checks option-order position bias

jev_competitor_scan

new

Paginated/sortable GitHub search, Noul-ranked against our own positioning, System-2 "closest rival + gaps" synthesis

One-click MCP install

Instead of hand-editing claude_desktop_config.json / .cursor/mcp.json / .continue/config.json, run:

npm run install-mcp

scripts/install-mcp.js detects Claude Desktop, Cursor and Continue.dev on your machine, merges (never overwrites) a jev-super-agent entry into whichever config files exist, and backs up each original file to <file>.bak first.

How it works

flowchart LR
    Q[Decision request] --> G{"BELKİ Gatekeeper<br/>confidence?"}
    G -- "&gt; 0.85" --> E["Execute directly<br/>$0, no LLM call"]
    G -- "0.60 – 0.85" --> S["Speculative fan-out<br/>N sub-decisions in parallel"]
    G -- "&lt; 0.60" --> T["Escalate to System 2<br/>(planner / red-team)"]

    subgraph Backend resolution
        B1[typesafe_jev] -->|unreachable| B2[openjev_local]
        B2 -->|unreachable| B3[laya_local]
        B3 -->|unreachable| B4["heuristic<br/>(always available)"]
    end

    E -.-> B1
    S -.-> B1
    T -.-> B1

Every primitive call (Choice / Score / Noul) is schema-validated — never free text — and the backend chain always terminates in a deterministic offline simulator, so nothing ever fails closed even with no network, no GPU and no API key.

Multi-domain presets (7)

software-architecture, marketing-growth, product-ux, cost-model-router, cybersecurity, legal-compliance (KVKK/GDPR), finance-valuation — every preset injects rules, red-flags, checklists and a scoring rubric into Jev state verbatim.

Self-improving memory

.jev-skill-memory.json stores decisions, verified outcomes and calibration buckets. The dynamic threshold auto-tuner lowers the executeThreshold when calibrated buckets over-deliver and raises it when they fail — so the system provably gets cheaper and safer with every verified outcome.

Configuration (all optional, all env-driven)

Env var

Default

Purpose

JEV_BACKEND_PROVIDER

auto

auto / typesafe_jev / openjev_local / laya_local / heuristic

OPENJEV_BASE_URL

http://localhost:8000/v1

local OpenJev / vLLM endpoint

TYPESAFE_JEV_API_KEY

—

hosted Jev key (or VERCEL_AI_GATEWAY_KEY)

JEV_LLM_BASE_URL

http://localhost:11434/v1

System-2 LLM (Ollama, vLLM, LM Studio)

JEV_LLM_MODEL

qwen2.5:7b-instruct

System-2 model

JEV_GATE_EXECUTE

0.85

gatekeeper direct-execution threshold

JEV_GATE_ESCALATE

0.6

"BELKİ" escalation threshold

JEV_MEMORY_PATH

<repo>/.jev-skill-memory.json

persistent self-improving memory

Development

npm run build      # strict TS compile (zero warnings)
npm test           # 27 unit tests (core 20 + datacenter 7)
npm run smoke      # 50-check end-to-end MCP client test
npm run test:real  # REAL model test: needs `ollama serve` + a local model (e.g. qwen2.5:3b)
npm run test:hub   # 7 datacenter-only tests, no network

Benchmark: how much does this actually save?

Real, reproducible numbers (not marketing copy) comparing jev_research to a Claude Code session doing the same research task by hand (WebSearch/WebFetch + inline reasoning, no local decision layer):

jev_research

vanilla Claude Code

Tokens entering Claude's context

~2,300 avg

~43,000 avg (~19x more)

Tool round-trips

1

10-12 (~11x more)

Wall-clock

3-10s (measured)

~30-36s (assumption-labeled estimate)

Full methodology, caveats, and how to reproduce every number yourself: BENCHMARK.md.

Research Hub (knowledge data center)

Nightly-scraped research library for personal development, rationality, cognitive psychology and philosophy — 11 curated sources in 3 tiers (mental-models / library / academic), SQLite + FTS5 store, Jev-ranked answers.

npm run hub -- sources                        # list the 11 sources + policies
npm run hub -- crawl --dry-run                 # robots.txt + discovery preview, zero writes
npm run hub -- crawl --source sivers --force   # crawl one source now (off-hours override)
npm run hub -- crawl                           # full nightly crawl (02:00–06:00 Europe/Berlin)
npm run hub -- query "second-order thinking"   # FTS5 + Jev Noul re-rank + VERIFIED/PROBABLE/REJECTED tiers
npm run hub -- stats                           # docs + word counts per source

Pipeline per document: hour-window gate → robots.txt gate → sitemap/HTML/JSON discovery → license check (public-domain full text · academic/library metadata-only) → polite fetch → data/research-hub.sqlite (+ FTS5 index).

License

MIT.

Available Tools

24 tools
hub_crawlResearch hub crawler (personal-development knowledge base)A

Politely crawl the 11 curated sources (Farnam Street, LessWrong, Derek Sivers, Julian Shapiro, Internet Archive, Open Library, Project Gutenberg, Wikibooks, PhilArchive, PsyArXiv, CORE) into the local SQLite+FTS5 research hub. Respects robots.txt and each source's off-hours crawl window unless force=true.

Inputs: force, dbPath, dryRun, sources, +2 more.

hub_queryResearch hub query (rationality / cognitive-psychology / philosophy)A

FTS5 search over the crawled research hub, re-ranked by Jev Noul relevance into VERIFIED/PROBABLE/REJECTED tiers, then synthesized into a cited, step-by-step answer that grounds claims in mental models and cognitive-science findings over popular advice.

Inputs: query (required), topK, limit, dbPath, +1 more.

hub_statsResearch hub statsA

Report document counts, word totals and last-crawl timestamps per source in the research hub.

Inputs: dbPath.

jev_audit360° diagnostic auditA

Scan a project directory and score five dimensions (architecture, security, marketing, legal, budget) with findings, evidence and ranked fix actions.

Inputs: root (required), preset.

jev_backend_infoBackend + environment infoA

Report the resolved backend chain, pricing, gatekeeper policy, presets, memory summary and workspace paths so agents can self-diagnose the setup.

Inputs: no named parameters.

jev_compactWinnow lossless context compactionB

Delete irrelevant log/grep/diff lines at $0 cost WITHOUT summarizing: kept lines are byte-identical. File paths, commands, error codes, URLs and diff headers are always preserved.

Inputs: file, goal, text, maxLines, +1 more.

jev_decideGatekeeper decision (execute / speculative / system2)A

Route one decision through the 'BELKİ' gatekeeper: confidence above the tuned threshold executes directly ($0 LLM), mid range triggers speculative sub-decisions, low confidence escalates to System 2.

Inputs: options (required), question (required), state, persist.

jev_dispatchChief-of-staff role dispatcherA

Read shared memory + task intent and pick the next agent role (researcher / planner / implementer / reviewer / writer / auditor) with a ready handoff payload.

Inputs: task (required), context.

jev_distill_recipeSLM distillation recipeA

Emit a concrete LoRA distillation recipe (axolotl/unsloth + vLLM) for Qwen2.5-0.5B or a ModernBERT-421M decision head; optionally write the axolotl YAML into artifacts/training.

Inputs: target, writeYaml, datasetFile.

jev_edge_qaSynthetic QA edge-case matrix (feature #11)A

Generate a deterministic edge-case test matrix (input, concurrency, dependency, auth, state, time, billing) for a feature spec.

Inputs: spec (required), count.

jev_evaluateJev multi-primitive fan-out evaluationA

Evaluate a batch of decisions in ONE parallel pass: choice (<=255 options), score (fractional scale) and noul (calibrated probability). Extra questions do not increase latency or cost.

Inputs: requests (required).

jev_featuresEnterprise feature catalog (module 10)A

List the 20 enterprise features with honest implemented/scaffolded status and their hosting tool.

Inputs: no named parameters.

jev_github_mineGitHub mining & clean-room inspirationA

Audit a repository license (permissive vs copyleft/unknown) and, for restricted licenses, extract an architecture-only clean-room spec with a 5-gram similarity guard proving originality.

Inputs: repo (required), similarityThreshold.

jev_guardrailAutoMode guardrail (pre-execution safety gate)B

Classify a tool call before execution: dangerous pattern blacklist + Jev Noul danger and Score severity produce an allow / ask / block verdict with reasons.

Inputs: args (required), tool (required).

jev_label_datasetAuto-dataset labeler ($0/row on local backends)A

Label raw rows with Jev primitives in one fan-out pass and write a JSONL dataset into artifacts/datasets for distillation.

Inputs: rows (required), mode, options, question, +1 more.

jev_memorySelf-improving memory (report / optimize / record / state)A

Inspect and steer the arena-style skill memory: calibration buckets, verified win rate, threshold auto-tuning and manual outcome recording.

Inputs: op, detail, passed, question, +1 more.

jev_planUltra-planning & spec engineA

Produce a steeled plan: System-2 hypothesis + hostile anti-thesis, scored by the Jev loop on feasibility, failure risk, cost and maintainability. Works offline with deterministic fallbacks.

Inputs: goal (required), preset, context.

jev_preference_pairsRLCD / DPO preference pair generatorB

Score every candidate answer with the Jev Score primitive and emit chosen/rejected JSONL pairs for local DPO training.

Inputs: items (required), writeFile.

jev_pr_gatePR gatekeeper (feature #16)A

Check a unified diff for breaking export removals, hardcoded secrets, console leftovers, new TODOs and dependency manifest changes; returns allow/ask/block.

Inputs: files (required).

jev_privacy_sanitizePrivacy sanitizer (feature #7)A

Mask PII and secrets (emails, cards, IBAN, Turkish ID, API keys, bearer tokens, private keys, env assignments) locally before anything is sent to an external model.

Inputs: text (required).

jev_redteamAdversarial red-teaming dual loopB

Generate concrete anti-theses against a thesis, score their severity/evidence with the Jev loop and arbitrate the safest route with residual risks and mitigations.

Inputs: thesis (required), context, maxAntiTheses.

jev_rerankRAG noise filter & re-ranker (feature #12)A

Re-rank retrieved passages with Jev Noul relevance and keep the top-K, dropping the noise.

Inputs: query (required), documents (required), topK.

jev_researchUltra-deep research (4 parallel channels)A

Sweep web (Wikipedia/Brave), academic (arXiv), code (GitHub/npm) and social (HN/X) channels in parallel, re-rank with Jev relevance and synthesize a cited brief. Free/keyless sources by default.

Inputs: query (required), maxHits, channels.

jev_verifyRLVR verification (tsc + tests -> reward)A

Run verification commands (default: npx tsc --noEmit, npm test) in a working directory, record +1/-1 reward into the skill memory and auto-tune the gatekeeper thresholds.

Inputs: cwd, commands, question, timeoutMs.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.5/5.0

    Scored across 24 tools

    Disambiguation4/5

    Most tools target a clearly distinct resource or stage, and the descriptions are detailed enough to separate them. A few pairs (jev_evaluate/jev_decide, jev_research/jev_rerank, jev_plan/jev_redteam) share conceptual machinery, but their intended workflows are still distinguishable.

    Naming Consistency3/5

    The common 'jev_' prefix and snake_case style provide a consistent family feel, but the underlying pattern is mixed: some tools are verbs (jev_decide, jev_verify), some verb_noun (jev_label_dataset, jev_distill_recipe), and some nouns or noun phrases (jev_memory, jev_features, jev_preference_pairs). The separate 'hub_' prefix also breaks the single naming scheme.

    Tool Count3/5

    At 24 tools, the set sits squarely in the heavy range and includes several highly specialized or self-diagnostic tools (jev_features, jev_backend_info, hub_stats). It is not egregious because the server appears to be a broad all-in-one agent platform, but the count still feels larger than a tightly scoped MCP server.

    Completeness4/5

    The tool set covers major agent workflows well: research, decision-making, planning, red-teaming, dataset preparation, safety checks, and verification. Minor gaps exist—there is no explicit implementation/execution tool and no training execution step beyond emitting recipes—but these are likely handled outside this server or are intentional boundaries.

    Maintenance

    ActivityStale
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      C
      maintenance
      Provides coding agents with structured planning, persistent project memory, automated verification, and safety permission controls through MCP tools, enabling better planning, context retention, self-checking, and guarded execution.
      MIT
    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables coding agents to make structured local decisions, choose bounded browser actions with approvals, and run coding workflows such as file relevance, context pruning, diff screening, and completion checks through MCP or CLI.
      Apache 2.0
    • A
      license
      Not graded
      quality
      B
      maintenance
      Exposes local MCP tools for typed, calibrated LLM decisions — gating risky actions, yes/no judging, classification, ordinal rating, and multi-question decisions in one pass. Runs on the model Devin's CLI already provides via ACP (or a fully offline local backend), so agents get calibrated confidence with no extra API key, no Ollama, and no waitlist.
      42 PyPI
      6
      MIT