/ Каталог / Песочница / DepWire
● Официальный depwire ⚡ Сразу

DepWire

автор depwire · depwire/depwire

Dependency graph context for AI-assisted refactoring.

DepWire builds a real dependency graph of your codebase and exposes it as MCP tools — 15+ queries like 'who imports this?', 'what does this function call transitively?', and 'what tests exercise this file?'. Designed to give refactoring agents the context they currently lack.

Зачем использовать

Ключевые функции

Живое демо

Как выглядит на практике

depwire-mcp.replay ▶ готово
0/0

Установка

Выберите клиент

~/Library/Application Support/Claude/claude_desktop_config.json  · Windows: %APPDATA%\Claude\claude_desktop_config.json
{
  "mcpServers": {
    "depwire-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "depwire"
      ]
    }
  }
}

Откройте Claude Desktop → Settings → Developer → Edit Config. Перезапустите после сохранения.

~/.cursor/mcp.json · .cursor/mcp.json
{
  "mcpServers": {
    "depwire-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "depwire"
      ]
    }
  }
}

Cursor использует ту же схему mcpServers, что и Claude Desktop. Конфиг проекта приоритетнее глобального.

VS Code → Cline → MCP Servers → Edit
{
  "mcpServers": {
    "depwire-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "depwire"
      ]
    }
  }
}

Щёлкните значок MCP Servers на боковой панели Cline, затем "Edit Configuration".

~/.codeium/windsurf/mcp_config.json
{
  "mcpServers": {
    "depwire-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "depwire"
      ]
    }
  }
}

Тот же формат, что и Claude Desktop. Перезапустите Windsurf для применения.

~/.continue/config.json
{
  "mcpServers": [
    {
      "name": "depwire-mcp",
      "command": "npx",
      "args": [
        "-y",
        "depwire"
      ]
    }
  ]
}

Continue использует массив объектов серверов, а не map.

~/.config/zed/settings.json
{
  "context_servers": {
    "depwire-mcp": {
      "command": {
        "path": "npx",
        "args": [
          "-y",
          "depwire"
        ]
      }
    }
  }
}

Добавьте в context_servers. Zed перезагружается автоматически.

claude mcp add depwire-mcp -- npx -y depwire

Однострочная команда. Проверить: claude mcp list. Удалить: claude mcp remove.

Сценарии использования

Реальные сценарии: DepWire

Rename an exported symbol safely across an unfamiliar codebase

👤 Engineers refactoring legacy code ⏱ ~15 min intermediate

Когда использовать: You don't trust the codebase enough to just grep-and-rename.

Предварительные требования
  • Server/skill installed and authenticated — See repo README
Поток
  1. Map the impact
    Show me every file that imports parseConfig from src/config.ts.✓ Скопировано
    → List of importers grouped by package
  2. Find covering tests
    Which tests exercise src/config.ts? Run them first.✓ Скопировано
    → Test files + pass/fail status
  3. Refactor
    Rename to loadConfig everywhere. Update tests too.✓ Скопировано
    → Diff across all importers

Итог: Rename with confidence — every call site and every test accounted for.

Подводные камни
  • Dynamic imports (require(x)) won't show up in the graph. For dynamic dispatch, double-check with grep. — Dynamic imports (require(x)) won't show up in the graph. For dynamic dispatch, double-check with grep.
Сочетать с: filesystem · github

Комбинации

Сочетайте с другими MCP — эффект x10

depwire-mcp + filesystem

Pair with filesystem for complementary capabilities

Use this server together with filesystem to complete a multi-step task.✓ Скопировано
depwire-mcp + github

Pair with github for complementary capabilities

Use this server together with github to complete a multi-step task.✓ Скопировано

Инструменты

Что предоставляет этот MCP

ИнструментВходные данныеКогда вызыватьСтоимость
who_imports file_or_symbol Find the blast radius of a change free
transitive_callers symbol Trace a function's full caller tree free
tests_covering file Find tests to run after touching a file free

Стоимость и лимиты

Во что обходится

Квота API
See provider docs for rate limits
Токенов на вызов
Varies by tool
Деньги
See repo README for pricing details
Совет
Cache tool results and avoid repeated identical calls.

Безопасность

Права, секреты, радиус поражения

Хранение учётных данных: Use environment variables; never commit secrets
Исходящий трафик: Tool calls go to the provider's API as documented

Устранение неполадок

Частые ошибки и исправления

no index built

Run depwire index from the repo root before first use. Re-run after major branch switches.

Проверить: who_imports returns results
missing files

Add the language pack (e.g. depwire lang add python) if your repo isn't pure TS.

Проверить: depwire status lists the language

Альтернативы

DepWire в сравнении

АльтернативаКогда использоватьКомпромисс
Sourcegraph MCPYou want hosted multi-repo searchEnterprise; depwire is local-first

Ещё

Ресурсы

📖 Читать официальный README на GitHub

🐙 Открытые задачи

🔍 Все 400+ MCP-серверов и Skills