Syke

io.github.khalomsky由 GitHub 帳號 khalomsky 發布v1.5.4更新於 Oct 24, 2026

AI code impact analysis — dependency graphs, cascade detection, and build gates for AI agents

已驗證STDIO僅桌面開發者工具資料與分析

概覽

AI 產生的概覽

SYKE 是本地 MCP 伺服器,為程式碼庫建立相依圖,讓 AI 代理在建置或部署前檢查改動是否會破壞下游檔案。

可以做什麼
  • 建置安全檢查:執行建置前閘門,回傳 PASS/WARN/FAIL 結論,或給出 HIGH/MEDIUM/LOW/NONE 的快速風險判斷。
  • 檢視相依性:列出某個檔案的內部匯入,並分析改動的完整影響範圍,包含循環相依叢集與風險評分。
  • 排序與更新相依圖:依 PageRank 找出最重要的樞紐檔案,並在改動後重建相依圖。
  • AI 與監控:透過所選 AI 供應商對檔案及其相依方做語意分析,並對可能破壞相依方的改動發出提醒。
  • 視覺化:本機網頁儀表板以互動方式呈現相依圖與風險指標。
適用情境
適合 AI 程式代理修改多檔案專案時,在提交或部署前自動確認下游程式碼未被破壞。也適合想把相依影響分析與建置閘門接進代理工作流程的團隊。
執行需求
透過 npx 執行 npm 套件 @syke1/mcp-server,需要 Node.js,僅支援桌面端。選用設定位於 ~/.syke/config.json 或環境變數:SYKE_LICENSE_KEY 用於 Pro 功能,以及一個 AI 供應商金鑰(GEMINI_KEY、OPENAI_KEY 或 ANTHROPIC_KEY)用於語意分析。儀表板預設監聽本機 3333 埠。
安裝前請注意
Pro 版本需要廠商儀表板提供的授權金鑰;AI 分析會用你自己的 API 金鑰把檔案內容傳送給所選供應商(Gemini、OpenAI 或 Anthropic)。伺服器會掃描原始碼目錄並讀取 git 歷史,儀表板在本機埠提供存取。免費版僅包含閘門、安全檢查與相依性列表工具。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Syke,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

SYKE — Your Codebase Has a Pulse

AI code impact analysis MCP server. SYKE monitors every file your AI touches, maps dependency graphs, detects cascading breakage, and gates builds before damage spreads.

Works with Claude Code, Cursor, Windsurf, and any MCP-compatible AI coding agent.

[SYKE Dependency Graph]

[SYKE Impact Analysis]

[SYKE Node Detail]

How It Works

  1. On startup, SYKE scans your source directory and builds a complete dependency graph using static import analysis.
  2. Your AI agent modifies files freely — no interruptions during normal work.
  3. Before build/deploy, the AI calls gate_build to check if all changes are safe.
  4. If dependencies break, SYKE detects cascading failures and blocks the build with a FAIL verdict.
  5. The dashboard shows a real-time visualization of your dependency graph with risk indicators.

SYKE is a safety net, not a gatekeeper. It doesn't block your AI while working — it catches what your AI missed before you ship.

Quick Start

1. Create config file

Create ~/.syke/config.json:

json
{  "licenseKey": "SYKE-XXXX-XXXX-XXXX-XXXX",  "geminiKey": "your-gemini-api-key"}

Get your license key at syke.cloud/dashboard. You only need ONE AI key. Supported: geminiKey, openaiKey, anthropicKey.

2. Register MCP server

Claude Code:

bash
claude mcp add syke -- npx @syke1/mcp-server@latest

Cursor (.cursor/mcp.json):

json
{  "mcpServers": {    "syke": {      "command": "npx",      "args": ["@syke1/mcp-server@latest"]    }  }}

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

json
{  "mcpServers": {    "syke": {      "command": "npx",      "args": ["@syke1/mcp-server@latest"]    }  }}

Windows note: If npx is not found, use the full path: "command": "C:\\Program Files\\nodejs\\npx.cmd"

3. Add build gate to your project

Add this line to your project's CLAUDE.md (or equivalent AI instruction file):

After completing code changes, always run the gate_build MCP tool before committing or deploying.

This ensures your AI agent automatically runs SYKE's safety check after every task — no manual prompting needed.

4. Restart your AI agent

SYKE auto-detects your project language and builds the dependency graph on startup. Open http://localhost:3333 to see your live dashboard.

Features

8 MCP Tools

ToolTierDescription
gate_buildFreeMandatory pre-build check. Returns PASS/WARN/FAIL verdict before any build or deploy.
check_safeFreeQuick one-line safety verdict: HIGH/MEDIUM/LOW/NONE risk.
get_dependenciesFreeLists internal imports (forward dependencies) of a file.
analyze_impactProFull impact analysis with SCC, risk scoring, and git coupling.
get_hub_filesProRanks files by PageRank importance score.
refresh_graphProRe-scans all source files and rebuilds the dependency graph.
ai_analyzeProAI semantic analysis (Gemini/OpenAI/Claude) of a file and its dependents.
check_warningsProReal-time monitoring alerts for file changes that may break dependents.

Multi-AI Provider Support

SYKE supports three AI providers for semantic analysis. Bring your own key:

ProviderModelConfig KeyEnv Variable
Google Geminigemini-2.5-flashgeminiKeyGEMINI_KEY
OpenAIgpt-4o-miniopenaiKeyOPENAI_KEY
Anthropicclaude-sonnet-4-20250514anthropicKeyANTHROPIC_KEY

Auto-selection: SYKE uses the first available key (Gemini > OpenAI > Anthropic). Force provider: Set aiProvider in config (or SYKE_AI_PROVIDER env var) to override.

Advanced Graph Algorithms

SYKE goes beyond simple dependency counting. Five production-grade algorithms work together to deliver precise, fast, and context-rich impact analysis — all running locally with zero AI token cost.

1. SCC Condensation + Topological Sort

Circular dependencies are the #1 source of misleading impact analysis. SYKE uses Tarjan's algorithm to detect all Strongly Connected Components, condenses them into a clean DAG, then runs topological sort to compute correct cascade levels.

Before: "47 files affected" (inflated by cycles)After:  "3 files in circular cluster (Level 0) → 5 files (Level 1) → 4 files (Level 2)"
  • O(V+E) computation — runs in single-digit milliseconds
  • Every SCC with size > 1 is flagged as a circular dependency cluster
  • Cascade levels are accurate even in heavily cyclic codebases
2. Composite Risk Scoring

Five signals combined into a single 0–1 risk score:

SignalWeightWhat it measures
Fan-in30%How many files depend on this one
Stability Index20%I = Ce/(Ca+Ce) — lower = foundation file = riskier to change
Cyclomatic Complexity20%Internal branching complexity (regex-based, 8 languages)
Cascade Depth15%How many layers deep the impact propagates
PageRank15%Recursive importance in the dependency graph
auth_service.ts → Risk: 0.82 (CRITICAL)  Fan-in: 24, Stability: 0.12, Complexity: 47, Cascade: 4 levels, PageRank: 99th
string_utils.ts → Risk: 0.31 (LOW)  Fan-in: 18, Stability: 0.85, Complexity: 3, Cascade: 1 level, PageRank: 42nd

AI agents can now make threshold decisions: proceed if < 0.3, warn if 0.3–0.7, block if > 0.7.

3. Historical Change Coupling

Static imports miss hidden dependencies — files that always change together but have no import relationship. SYKE mines your git history (last 500 commits) to find these logical couplings.

auth_service.ts changed →  [Dependency Graph] auth_provider.ts, login_screen.ts  [Git Coupling — Hidden Dependencies]    config/auth_config.json (85% confidence, 12 co-changes)    styles/auth.css (72% confidence, 8 co-changes)
  • Catches 15–30% of impacted files that static analysis misses entirely
  • Filters mega-commits (>20 files) to avoid noise
  • 5-minute cache with auto-refresh
4. PageRank for File Importance

Simple fan-in counts treat all dependents equally. PageRank computes recursive importance — a file imported by many important files ranks higher than one imported by many leaf files.

Before: utils.ts ranked #1 (25 dependents — but all are leaf components)After:  auth.ts ranked #1 (20 dependents — 15 of which are core modules)
  • Standard Power Iteration with damping factor 0.85
  • Precomputed at startup, incrementally updated on file changes
  • Every file gets a rank position and percentile (e.g., "rank #3 of 245, 99th percentile")
5. Incremental Graph Updates + Memoized Queries

For large codebases (10K+ files), full graph rebuilds are too slow. SYKE now updates only the changed file's edges and invalidates only the affected cache entries.

Before: 1 file changed → re-parse all 500 files → 2+ secondsAfter:  1 file changed → re-parse 1 file → edge diff → 50ms        Same file queried again → cache hit → O(1) instant
  • Reverse index enables O(affected) cache invalidation instead of O(cache_size)
  • SCC and PageRank recompute after edge changes (still < 100ms for 10K files)
  • 500-entry LRU cache with hit/miss diagnostics

Language Support

Auto-detected, zero-config: Dart/Flutter, TypeScript/JavaScript, Python, Go, Rust, Java, C++, Ruby.

Web Dashboard

Live dependency graph visualization at localhost:3333 with:

  • Interactive 3D node graph (click any file to see its connections)
  • Real-time cascade monitoring
  • Risk level indicators
  • Server offline detection with auto-reconnect

Configuration

SYKE reads from ~/.syke/config.json (primary) with environment variable overrides:

Config KeyEnv VariableDescriptionRequired
licenseKeySYKE_LICENSE_KEYPro license key from dashboardNo (Free tier works without)
geminiKeyGEMINI_KEYGoogle Gemini API key for ai_analyzeNo (any one AI key)
openaiKeyOPENAI_KEYOpenAI API key for ai_analyzeNo (any one AI key)
anthropicKeyANTHROPIC_KEYAnthropic API key for ai_analyzeNo (any one AI key)
aiProviderSYKE_AI_PROVIDERForce AI provider: gemini, openai, or anthropicNo (auto-selects)
portSYKE_WEB_PORTDashboard port (default: 3333)No

Full config example (~/.syke/config.json):

json
{  "licenseKey": "SYKE-XXXX-XXXX-XXXX-XXXX",  "geminiKey": "AIza...",  "openaiKey": "",  "anthropicKey": "",  "port": 3333}

Recommended Workflow

You (developer)          AI Agent            SYKE     |                      |                  |     |-- "Add feature X" -->|                  |     |                      |-- modifies files |     |                      |-- modifies files |     |                      |-- modifies files |     |                      |                  |     |                      |-- gate_build --->|     |                      |                  |-- scans graph     |                      |                  |-- checks impact     |                      |<-- PASS/FAIL ----|     |                      |                  |     |<-- "Done. Safe to    |                  |     |    build." ----------|                  |

Founding 100 — Free Pro for Early Adopters

We're giving the first 100 developers full Pro access for 30 days — no credit card, no strings.

What you get:

  • All 8 MCP tools with advanced algorithms (SCC, PageRank, Risk Scoring, Git Coupling)
  • Unlimited files, multi-project support
  • Real-time cascade monitoring + web dashboard
  • AI semantic analysis (BYOK — Gemini, OpenAI, or Claude)

How to claim:

  1. Sign up at syke.cloud
  2. Star this repo
  3. Click "I Starred" in your dashboard → 30 days Pro unlocked

Spots are limited. Once they're gone, they're gone.

Source CodeThis repository contains the Free tier source code — the core dependency graph engine, language plugins, and 3 free MCP tools (gate_build, check_safe, get_dependencies).Pro and Cortex features (advanced algorithms, AI analysis, real-time monitoring, web dashboard) are included in the npm package as compiled code.

License

Elastic License 2.0 (ELv2)

You can use, modify, and distribute SYKE freely, with two limitations:

  1. No managed service — You cannot offer SYKE as a hosted/managed service to third parties.
  2. No license key circumvention — You cannot remove, disable, or bypass the license key functionality.

來源:README.md,提交 d68bef1

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

1
  1. v1.5.4最新Sep 16, 2026

評分

已滿足適用檢查項的 40%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分

    請在儲存庫或註冊中心條目中宣告授權條款。