NEXUS

NEXUS

NEXUS enhances AI coding agents with semantic code indexing, context engineering, change impact analysis, persistent memory, safe execution, and deterministic orchestration through 31 MCP tools.

Category
访问服务器

README

NEXUS — God-Tier MCP Server for Agentic Coding Agents

The most powerful, advanced, and robust MCP server for CLI coding agents.

NEXUS gives your AI coding agent capabilities it structurally lacks: deep code understanding, change-impact awareness, persistent memory, engineered context, verified execution, and deterministic orchestration.

31 tools · 10 families · 20+ languages · zero native dependencies


Quick Install (Cline CLI / Claude Desktop / Cursor / etc.)

git clone https://github.com/Senpai-Sama7/nexus-mcp-server.git
cd nexus-mcp-server
npm install
npm run build

# Install MCP config for all detected clients (Cline CLI, Claude Desktop, Cursor, Windsurf, Gemini, OpenCode)
./install-mcp.sh /path/to/project1 /path/to/project2

The install-mcp.sh script writes a cline_mcp_settings.json (and equivalents for other clients) that registers one NEXUS MCP server instance per workspace. Each instance points at a different NEXUS_WORKSPACE so you get a separate code index per project.


Manual Configuration

Cline CLI (~/.cline/cline_mcp_settings.json)

{
  "mcpServers": {
    "nexus": {
      "command": "node",
      "args": ["/path/to/nexus-mcp-server/dist/server.js"],
      "env": { "NEXUS_WORKSPACE": "/path/to/your/project" },
      "disabled": false
    },
    "nexus-other-project": {
      "command": "node",
      "args": ["/path/to/nexus-mcp-server/dist/server.js"],
      "env": { "NEXUS_WORKSPACE": "/path/to/another/project" },
      "disabled": false
    }
  }
}

Claude Desktop (~/Library/Application Support/Claude/claude_desktop_config.json on macOS)

Same mcpServers format as above.

Cline VSCode extension

~/.config/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json — same format.

Claude Code (.mcp.json in your project root)

{
  "mcpServers": {
    "nexus": {
      "command": "node",
      "args": ["./nexus-mcp-server/dist/server.js"],
      "env": { "NEXUS_WORKSPACE": "${workspaceFolder}" }
    }
  }
}

OpenCode (~/.config/opencode/opencode.jsonc)

OpenCode uses a different MCP schema — mcp keyed by server name, command as an array, environment under environment, plus enabled/timeout:

{
  "mcp": {
    "nexus": {
      "type": "local",
      "command": ["node", "/path/to/nexus-mcp-server/dist/server.js"],
      "environment": {
        "NEXUS_WORKSPACE": "/path/to/your/project",
        "NEXUS_LOG_LEVEL": "info"
      },
      "enabled": true,
      "timeout": 15000
    },
    "nexus-other-project": {
      "type": "local",
      "command": ["node", "/path/to/nexus-mcp-server/dist/server.js"],
      "environment": {
        "NEXUS_WORKSPACE": "/path/to/another/project",
        "NEXUS_LOG_LEVEL": "info"
      },
      "enabled": true,
      "timeout": 15000
    }
  }
}

Gemini CLI (~/.gemini/settings.json)

Same mcpServers shape as Cline CLI:

{
  "mcpServers": {
    "nexus": {
      "command": "node",
      "args": ["/path/to/nexus-mcp-server/dist/server.js"],
      "env": { "NEXUS_WORKSPACE": "/path/to/your/project", "NEXUS_LOG_LEVEL": "info" }
    },
    "nexus-other-project": {
      "command": "node",
      "args": ["/path/to/nexus-mcp-server/dist/server.js"],
      "env": { "NEXUS_WORKSPACE": "/path/to/another/project", "NEXUS_LOG_LEVEL": "info" }
    }
  }
}

Cursor (~/.cursor/mcp.json)

Windsurf (~/.codeium/windsurf/mcp_config.json)

Both use the same mcpServers format as Cline CLI above.


Why NEXUS?

Every current coding agent has 10 structural gaps. NEXUS fills all 10:

  1. Agents read raw text → NEXUS builds a semantic symbol/reference/dependency graph
  2. Agents edit blind → NEXUS computes blast radius before changes
  3. Agents forget everything between sessions → NEXUS persists namespaced memory
  4. Agents fetch context greedily → NEXUS ranks and budgets context (repo map, context packs)
  5. Agents can't verify structurally → NEXUS parses test/lint/typecheck output into structured diagnostics
  6. Agents do serial work → NEXUS runs deterministic parallel fan-out + persistent task DAGs
  7. Agents leak secrets / touch sensitive files → NEXUS scans, jails, and warns
  8. Agents get huge unreadable tool dumps → NEXUS paginates with cursors + head/tail truncation
  9. Agents lose state on crash → NEXUS snapshots files and checkpoints task state
  10. Agents can't see the project at a glance → NEXUS workspace health + map on demand

Environment Variables

Variable Default Description
NEXUS_WORKSPACE process.cwd() Workspace root (the jail boundary)
NEXUS_LOG_LEVEL info One of: debug, info, warn, error, silent

The 31 Tools

A. Workspace (3)

  • nexus_workspace_overview — languages, LOC, git state, index health
  • nexus_search — regex/literal/glob content search
  • nexus_read_span — line-range read with encoding + injection detection

B. Code Intelligence (6)

  • nexus_index_build — build/refresh the code index
  • nexus_file_symbols — symbol outline of a file
  • nexus_find_symbols — fuzzy workspace-wide symbol search
  • nexus_references — all reference sites of a symbol
  • nexus_call_graph — callers/callees, depth-N
  • nexus_dependency_graph — import graph: deps / dependents

C. Context Engineering (2) ⭐

  • nexus_repo_map — ranked repo map within a token budget (Aider-style)
  • nexus_context_pack — task-focused context bundle

D. Change Safety (4)

  • nexus_impact_analysis — blast radius before editing
  • nexus_git_diff — smart diff with stats + paginated hunks
  • nexus_snapshot / nexus_restore — checkpoint and rollback

E. Execution & Verification (4)

  • nexus_exec — run commands with timeout + secret redaction
  • nexus_exec_poll — poll/kill background jobs
  • nexus_test_run — detect framework (jest/vitest/pytest/cargo/go) → structured failures
  • nexus_diagnose — tsc/eslint → parsed {file, line, col, severity, rule, message}

F. Memory (3)

  • nexus_memory_write / nexus_memory_search / nexus_memory_forget — persistent knowledge

G. Orchestration (4)

  • nexus_task_submit / nexus_task_update / nexus_task_status — DAG task management
  • nexus_fanout — parallel map with concurrency limit

H. Security & Hygiene (2)

  • nexus_secret_scan — scan for AWS/GitHub/OpenAI/JWT/keys
  • nexus_audit_manifest — dependency risk heuristics (typosquat, unpinned)

I. Refactor (1)

  • nexus_rename_symbol — preview-first, graph-scoped rename

J. Meta (2)

  • nexus_server_status — self-diagnostics
  • nexus_guide — on-demand playbook for workflows

Recommended Workflows

New Feature

1. nexus_workspace_overview
2. nexus_repo_map
3. nexus_context_pack focusFiles:[...]
4. nexus_dependency_graph file:...
5. nexus_snapshot (checkpoint)
6. Implement (using nexus_read_span, nexus_search)
7. nexus_test_run + nexus_diagnose
8. nexus_secret_scan
9. nexus_memory_write (record decisions)

Refactor

1. nexus_index_build force:true
2. nexus_find_symbols name:"oldName"
3. nexus_impact_analysis target:"oldName" mode:"symbol"
4. nexus_snapshot
5. nexus_rename_symbol (preview!)
6. nexus_test_run

Debug

1. nexus_diagnose
2. nexus_test_run
3. nexus_search pattern:"error message"
4. nexus_call_graph symbol:... direction:callers
5. nexus_memory_write (record the fix)

Architecture Highlights

  • Zero native dependencies — pure JS regex-based parser works on any platform
  • 20+ languages supported — TS/JS/Python/Go/Rust/Java/C/C++/C#/Ruby/PHP/Swift/Kotlin/Lua/Shell/...
  • Path jail — every file op goes through symlink-resolved boundary check
  • Sensitive file protection — .env, keys, credentials blocked by default
  • Indirect prompt injection guard — file contents/command outputs scanned for attack patterns
  • Secret redaction — 15+ detectors (AWS, GitHub, OpenAI, Anthropic, JWT, etc.)
  • Process-group kill — timeouts kill entire process trees, no leaks
  • Atomic persistence — tmp-file + rename for index, memory, snapshots
  • LRU memory caps — never unbounded growth
  • Tool annotations — truthful readOnlyHint / destructiveHint / idempotentHint / openWorldHint
  • Multi-workspace — run multiple NEXUS instances, each indexing a different project

Testing

npm run test:client

Validates all 31 tools via the full JSON-RPC protocol end-to-end. 100% pass rate.


License

MIT

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选