Skip to content

Latest commit

ย 

History

History
398 lines (286 loc) ยท 12.1 KB

File metadata and controls

398 lines (286 loc) ยท 12.1 KB

Setup Guide โ€” Step-by-Step Installation (๋‹จ๊ณ„๋ณ„ ์„ค์น˜ ๊ฐ€์ด๋“œ)

This guide walks you through installing /coord from scratch. It is written for people who are comfortable with the command line but may not have used Claude Code's hook or MCP systems before.

์ด ๊ฐ€์ด๋“œ๋Š” ์ฒ˜์Œ๋ถ€ํ„ฐ /coord๋ฅผ ์„ค์น˜ํ•˜๋Š” ๊ณผ์ •์„ ์•ˆ๋‚ดํ•ฉ๋‹ˆ๋‹ค. ๋ช…๋ น์ค„์— ์ต์ˆ™ํ•˜์ง€๋งŒ Claude Code์˜ ํ›… ๋˜๋Š” MCP ์‹œ์Šคํ…œ์„ ์‚ฌ์šฉํ•ด ๋ณธ ์ ์ด ์—†๋Š” ๋ถ„๋“ค์„ ์œ„ํ•ด ์ž‘์„ฑ๋˜์—ˆ์Šต๋‹ˆ๋‹ค.


Prerequisites Checklist (์‚ฌ์ „ ์š”๊ตฌ์‚ฌํ•ญ ์ฒดํฌ๋ฆฌ์ŠคํŠธ)

Complete all items before starting installation. (์„ค์น˜๋ฅผ ์‹œ์ž‘ํ•˜๊ธฐ ์ „์— ๋ชจ๋“  ํ•ญ๋ชฉ์„ ์™„๋ฃŒํ•˜์„ธ์š”.)

  • Python 3.10 or higher โ€” python3 --version should print 3.10.x or above (Python 3.10 ์ด์ƒ)
  • Node.js 18 or higher โ€” node --version should print v18.x.x or above (Node.js 18 ์ด์ƒ)
  • npm 9 or higher โ€” npm --version should print 9.x.x or above (npm 9 ์ด์ƒ)
  • Claude Code โ€” install from https://claude.ai/code and run claude login (Claude Code ์„ค์น˜ ๋ฐ ๋กœ๊ทธ์ธ)
  • TAVILY_API_KEY โ€” get a free key at https://app.tavily.com (๋ฌด๋ฃŒ API ํ‚ค ๋ฐœ๊ธ‰)
  • Git โ€” git --version (Git ์„ค์น˜ ํ™•์ธ)
  • (Optional) OPENROUTER_API_KEY โ€” for premium model review in Stage 5 (์„ ํƒ์  โ€” ํ”„๋ฆฌ๋ฏธ์—„ ๋ชจ๋ธ ๊ฒ€ํ† ์šฉ)

Step 1 โ€” Clone the Repository (์ €์žฅ์†Œ ๋ณต์‚ฌ)

git clone https://github.com/Transconnectome/claude-code-coord.git
cd claude-code-coord

Verify the directory structure looks like this (๋””๋ ‰ํ† ๋ฆฌ ๊ตฌ์กฐ ํ™•์ธ):

claude-code-coord/
โ”œโ”€โ”€ .claude/                โ† Framework files to copy (๋ณต์‚ฌํ•  ํ”„๋ ˆ์ž„์›Œํฌ ํŒŒ์ผ)
โ”‚   โ”œโ”€โ”€ CLAUDE.md
โ”‚   โ”œโ”€โ”€ hooks/              โ† Anti-sycophancy hook scripts (์•„์ฒจ ๋ฐฉ์ง€ ํ›… ์Šคํฌ๋ฆฝํŠธ)
โ”‚   โ”œโ”€โ”€ agents/             โ† Specialist agent definitions (์ „๋ฌธ๊ฐ€ ์—์ด์ „ํŠธ ์ •์˜)
โ”‚   โ””โ”€โ”€ memory/             โ† Memory schema files (๋ฉ”๋ชจ๋ฆฌ ์Šคํ‚ค๋งˆ ํŒŒ์ผ)
โ”œโ”€โ”€ docs/                   โ† Documentation (๋ฌธ์„œ)
โ”œโ”€โ”€ settings/
โ”‚   โ””โ”€โ”€ settings.json.template
โ””โ”€โ”€ tests/

Step 2 โ€” Back Up Your Existing .claude/ (๊ธฐ์กด ์„ค์ • ๋ฐฑ์—…)

If you already have a ~/.claude/ directory, back it up first to avoid overwriting your existing settings.

์ด๋ฏธ ~/.claude/ ๋””๋ ‰ํ† ๋ฆฌ๊ฐ€ ์žˆ๋Š” ๊ฒฝ์šฐ ๊ธฐ์กด ์„ค์ • ๋ฎ์–ด์“ฐ๊ธฐ๋ฅผ ๋ฐฉ์ง€ํ•˜๊ธฐ ์œ„ํ•ด ๋จผ์ € ๋ฐฑ์—…ํ•˜์„ธ์š”.

# Check if ~/.claude/ exists (์กด์žฌ ์—ฌ๋ถ€ ํ™•์ธ)
ls ~/.claude/ 2>/dev/null && echo "Found" || echo "Not found"

# Back it up if it exists (์กด์žฌํ•˜๋Š” ๊ฒฝ์šฐ ๋ฐฑ์—…)
cp -r ~/.claude/ ~/.claude.backup.$(date +%Y%m%d)/

Step 3 โ€” Copy the Framework Files (ํ”„๋ ˆ์ž„์›Œํฌ ํŒŒ์ผ ๋ณต์‚ฌ)

# From inside the claude-code-coord directory (claude-code-coord ๋””๋ ‰ํ† ๋ฆฌ ๋‚ด์—์„œ)
cp -r .claude/ ~/.claude/

Verify the copy succeeded (๋ณต์‚ฌ ์„ฑ๊ณต ํ™•์ธ):

ls ~/.claude/
# Expected output (์˜ˆ์ƒ ์ถœ๋ ฅ):
# CLAUDE.md  agents/  hooks/  memory/

Step 4 โ€” Install MCP Servers (MCP ์„œ๋ฒ„ ์„ค์น˜)

Install each MCP server using npm. Some require additional configuration after installation.

npm์„ ์‚ฌ์šฉํ•˜์—ฌ ๊ฐ MCP ์„œ๋ฒ„๋ฅผ ์„ค์น˜ํ•ฉ๋‹ˆ๋‹ค. ์ผ๋ถ€๋Š” ์„ค์น˜ ํ›„ ์ถ”๊ฐ€ ๊ตฌ์„ฑ์ด ํ•„์š”ํ•ฉ๋‹ˆ๋‹ค.

Required servers (ํ•„์ˆ˜ ์„œ๋ฒ„)

# Multi-step reasoning engine (๋‹ค๋‹จ๊ณ„ ์ถ”๋ก  ์—”์ง„)
npm install -g @modelcontextprotocol/server-sequential-thinking

# Session key-value memory (์„ธ์…˜ ํ‚ค-๊ฐ’ ๋ฉ”๋ชจ๋ฆฌ)
npm install -g @modelcontextprotocol/server-memory

Recommended servers (๊ถŒ์žฅ ์„œ๋ฒ„)

# Real-time web search (์‹ค์‹œ๊ฐ„ ์›น ๊ฒ€์ƒ‰)
npm install -g @tavily/mcp-server

# Official library documentation (๊ณต์‹ ๋ผ์ด๋ธŒ๋Ÿฌ๋ฆฌ ๋ฌธ์„œ)
npm install -g @upstash/context7-mcp

# UI component generation (UI ์ปดํฌ๋„ŒํŠธ ์ƒ์„ฑ)
npm install -g @21st-dev/magic

# Bulk pattern-based code edits (์ผ๊ด„ ํŒจํ„ด ๊ธฐ๋ฐ˜ ์ฝ”๋“œ ์ˆ˜์ •)
npm install -g morphllm-mcp

Python-based servers (Python ๊ธฐ๋ฐ˜ ์„œ๋ฒ„)

# Create a virtual environment (๊ฐ€์ƒ ํ™˜๊ฒฝ ์ƒ์„ฑ)
python3 -m venv ~/coord-env
source ~/coord-env/bin/activate

# Playwright browser automation (Playwright ๋ธŒ๋ผ์šฐ์ € ์ž๋™ํ™”)
pip install playwright-mcp
playwright install chromium

# NotebookLM document analysis (NotebookLM ๋ฌธ์„œ ๋ถ„์„)
pip install notebooklm-mcp-cli

Verify all installations (๋ชจ๋“  ์„ค์น˜ ํ™•์ธ):

# Check npm packages (npm ํŒจํ‚ค์ง€ ํ™•์ธ)
npm list -g --depth=0 | grep -E "(sequential|memory|tavily|context7|magic|morphllm)"

# Check python packages (Python ํŒจํ‚ค์ง€ ํ™•์ธ)
source ~/coord-env/bin/activate
pip list | grep -E "(playwright|notebooklm)"

Step 5 โ€” Configure settings.json (settings.json ๊ตฌ์„ฑ)

Copy the template and fill in your API keys and paths.

ํ…œํ”Œ๋ฆฟ์„ ๋ณต์‚ฌํ•˜๊ณ  API ํ‚ค์™€ ๊ฒฝ๋กœ๋ฅผ ์ž…๋ ฅํ•ฉ๋‹ˆ๋‹ค.

cp settings/settings.json.template ~/.claude/settings.json

Open ~/.claude/settings.json in your editor and fill in:

ํŽธ์ง‘๊ธฐ์—์„œ ~/.claude/settings.json์„ ์—ด๊ณ  ๋‹ค์Œ์„ ์ž…๋ ฅํ•ฉ๋‹ˆ๋‹ค:

{
  "env": {
    "TAVILY_API_KEY": "tvly-YOUR_KEY_HERE",
    "OPENROUTER_API_KEY": "sk-or-YOUR_KEY_HERE"
  },
  "mcpServers": {
    "sequential-thinking": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-sequential-thinking"]
    },
    "memory": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-memory"]
    },
    "tavily": {
      "command": "npx",
      "args": ["-y", "@tavily/mcp-server"],
      "env": {
        "TAVILY_API_KEY": "tvly-YOUR_KEY_HERE"
      }
    },
    "context7": {
      "command": "npx",
      "args": ["-y", "@upstash/context7-mcp"]
    },
    "magic": {
      "command": "npx",
      "args": ["-y", "@21st-dev/magic"],
      "env": {
        "MAGIC_API_KEY": "YOUR_MAGIC_KEY_HERE"
      }
    },
    "playwright": {
      "command": "python3",
      "args": ["-m", "playwright_mcp"],
      "env": {
        "PATH": "/home/YOUR_USERNAME/coord-env/bin:/usr/local/bin:/usr/bin:/bin"
      }
    }
  }
}

Replace every YOUR_KEY_HERE and YOUR_USERNAME with your actual values.

๋ชจ๋“  YOUR_KEY_HERE์™€ YOUR_USERNAME์„ ์‹ค์ œ ๊ฐ’์œผ๋กœ ๊ต์ฒดํ•ฉ๋‹ˆ๋‹ค.


Step 6 โ€” Configure Hook Paths (ํ›… ๊ฒฝ๋กœ ๊ตฌ์„ฑ)

The anti-sycophancy hooks must point to the correct Python script paths. Add the hooks section to your ~/.claude/settings.json:

์•„์ฒจ ๋ฐฉ์ง€ ํ›…์€ ์˜ฌ๋ฐ”๋ฅธ Python ์Šคํฌ๋ฆฝํŠธ ๊ฒฝ๋กœ๋ฅผ ๊ฐ€๋ฆฌ์ผœ์•ผ ํ•ฉ๋‹ˆ๋‹ค. ~/.claude/settings.json์— hooks ์„น์…˜์„ ์ถ”๊ฐ€ํ•ฉ๋‹ˆ๋‹ค:

{
  "hooks": {
    "SessionStart": [
      {
        "type": "command",
        "command": "python3 /home/YOUR_USERNAME/.claude/hooks/chavis_session_init.py"
      }
    ],
    "UserPromptSubmit": [
      {
        "type": "command",
        "command": "python3 /home/YOUR_USERNAME/.claude/hooks/chavis_prompt_classify.py"
      },
      {
        "type": "command",
        "command": "python3 /home/YOUR_USERNAME/.claude/hooks/chavis_strategic_challenge.py"
      }
    ],
    "Stop": [
      {
        "type": "command",
        "command": "python3 /home/YOUR_USERNAME/.claude/hooks/chavis_stop_audit.py"
      },
      {
        "type": "command",
        "command": "python3 /home/YOUR_USERNAME/.claude/hooks/chavis_persistent_logger.py"
      }
    ]
  }
}

Replace YOUR_USERNAME with your actual home directory username (์‹ค์ œ ์‚ฌ์šฉ์ž ์ด๋ฆ„์œผ๋กœ ๊ต์ฒด):

# Find your username (์‚ฌ์šฉ์ž ์ด๋ฆ„ ํ™•์ธ)
whoami

Step 7 โ€” Initialize the Memory Directories (๋ฉ”๋ชจ๋ฆฌ ๋””๋ ‰ํ† ๋ฆฌ ์ดˆ๊ธฐํ™”)

The hook system writes to specific directories that must exist before the first session.

ํ›… ์‹œ์Šคํ…œ์€ ์ฒซ ๋ฒˆ์งธ ์„ธ์…˜ ์ „์— ์กด์žฌํ•ด์•ผ ํ•˜๋Š” ํŠน์ • ๋””๋ ‰ํ† ๋ฆฌ์— ์”๋‹ˆ๋‹ค.

# Create anti-sycophancy memory directories (์•„์ฒจ ๋ฐฉ์ง€ ๋ฉ”๋ชจ๋ฆฌ ๋””๋ ‰ํ† ๋ฆฌ ์ƒ์„ฑ)
mkdir -p ~/.claude/projects/-home-$(whoami)/memory/sycophancy/lessons/
mkdir -p /tmp/chavis/

# Create the initial pattern library (์ดˆ๊ธฐ ํŒจํ„ด ๋ผ์ด๋ธŒ๋Ÿฌ๋ฆฌ ์ƒ์„ฑ)
touch ~/.claude/projects/-home-$(whoami)/memory/sycophancy/pattern_library.md
touch ~/.claude/projects/-home-$(whoami)/memory/sycophancy/session_log.jsonl
touch ~/.claude/projects/-home-$(whoami)/memory/sycophancy/calibration_log.jsonl

# Create the MEMORY.md index (MEMORY.md ์ธ๋ฑ์Šค ์ƒ์„ฑ)
touch ~/.claude/projects/-home-$(whoami)/memory/MEMORY.md

Step 8 โ€” Verify the Installation (์„ค์น˜ ๊ฒ€์ฆ)

Run the test suite to confirm everything is working.

ํ…Œ์ŠคํŠธ ์Šค์œ„ํŠธ๋ฅผ ์‹คํ–‰ํ•˜์—ฌ ๋ชจ๋“  ๊ฒƒ์ด ์ž‘๋™ํ•˜๋Š”์ง€ ํ™•์ธํ•ฉ๋‹ˆ๋‹ค.

cd claude-code-coord/tests/

# Run hook system unit tests (ํ›… ์‹œ์Šคํ…œ ๋‹จ์œ„ ํ…Œ์ŠคํŠธ ์‹คํ–‰)
python3 -m pytest test_hooks.py -v

# Run a quick end-to-end smoke test (๋น ๋ฅธ ์—”๋“œ-ํˆฌ-์—”๋“œ ์Šค๋ชจํฌ ํ…Œ์ŠคํŠธ)
claude code --print "/coord 'This is a setup verification test. Reply with COORD_OK.'"

Expected output for the smoke test (์Šค๋ชจํฌ ํ…Œ์ŠคํŠธ ์˜ˆ์ƒ ์ถœ๋ ฅ):

COORD_OK

If you see COORD_OK, the installation succeeded (์„ค์น˜ ์„ฑ๊ณต).


Troubleshooting (๋ฌธ์ œ ํ•ด๊ฒฐ)

Problem: MCP server not found (MCP ์„œ๋ฒ„๋ฅผ ์ฐพ์„ ์ˆ˜ ์—†์Œ)

Error: Cannot find module '@modelcontextprotocol/server-sequential-thinking'

Fix (ํ•ด๊ฒฐ): The npm package was not installed globally. Re-run:

npm install -g @modelcontextprotocol/server-sequential-thinking
# Verify (ํ™•์ธ)
npx -y @modelcontextprotocol/server-sequential-thinking --version

Problem: Hook script permission denied (ํ›… ์Šคํฌ๋ฆฝํŠธ ๊ถŒํ•œ ๊ฑฐ๋ถ€)

Error: Permission denied: ~/.claude/hooks/chavis_session_init.py

Fix (ํ•ด๊ฒฐ):

chmod +x ~/.claude/hooks/chavis_*.py

Problem: Tavily API key rejected (Tavily API ํ‚ค ๊ฑฐ๋ถ€)

Error: TAVILY_API_KEY is invalid or expired

Fix (ํ•ด๊ฒฐ): Get a new key at https://app.tavily.com. Paste it in both the env top-level and the tavily mcpServer env in ~/.claude/settings.json.

์ƒˆ ํ‚ค๋ฅผ https://app.tavily.com์—์„œ ๋ฐœ๊ธ‰๋ฐ›์œผ์„ธ์š”. ~/.claude/settings.json์˜ ์ตœ์ƒ์œ„ env์™€ tavily mcpServer env ๋ชจ๋‘์— ๋ถ™์—ฌ๋„ฃ์Šต๋‹ˆ๋‹ค.


Problem: Playwright browser not found (Playwright ๋ธŒ๋ผ์šฐ์ €๋ฅผ ์ฐพ์„ ์ˆ˜ ์—†์Œ)

Error: browserType.launch: Executable doesn't exist at โ€ฆ/chromium

Fix (ํ•ด๊ฒฐ):

source ~/coord-env/bin/activate
playwright install chromium

Problem: Memory directory write error (๋ฉ”๋ชจ๋ฆฌ ๋””๋ ‰ํ† ๋ฆฌ ์“ฐ๊ธฐ ์˜ค๋ฅ˜)

FileNotFoundError: [Errno 2] No such file or directory:
  '~/.claude/projects/-home-username/memory/sycophancy/session_log.jsonl'

Fix (ํ•ด๊ฒฐ): Re-run Step 7 with your correct username substituted.

Step 7์„ ์˜ฌ๋ฐ”๋ฅธ ์‚ฌ์šฉ์ž ์ด๋ฆ„์œผ๋กœ ๋Œ€์ฒดํ•˜์—ฌ ๋‹ค์‹œ ์‹คํ–‰ํ•ฉ๋‹ˆ๋‹ค.


Problem: Claude Code does not recognize /coord (Claude Code๊ฐ€ /coord๋ฅผ ์ธ์‹ํ•˜์ง€ ๋ชปํ•จ)

The /coord system is a skill registered in ~/.claude/CLAUDE.md. If it is not working, verify the file was copied correctly.

/coord ์‹œ์Šคํ…œ์€ ~/.claude/CLAUDE.md์— ๋“ฑ๋ก๋œ ์Šคํ‚ฌ์ž…๋‹ˆ๋‹ค. ์ž‘๋™ํ•˜์ง€ ์•Š์œผ๋ฉด ํŒŒ์ผ์ด ์˜ฌ๋ฐ”๋ฅด๊ฒŒ ๋ณต์‚ฌ๋˜์—ˆ๋Š”์ง€ ํ™•์ธํ•ฉ๋‹ˆ๋‹ค.

# Check CLAUDE.md exists and contains coord (CLAUDE.md ์กด์žฌ ๋ฐ coord ํฌํ•จ ํ™•์ธ)
grep -l "coord" ~/.claude/CLAUDE.md && echo "Found" || echo "Missing โ€” re-run Step 3"

Quick Verification Checklist (๋น ๋ฅธ ๊ฒ€์ฆ ์ฒดํฌ๋ฆฌ์ŠคํŠธ)

After completing all steps, verify each item:

๋ชจ๋“  ๋‹จ๊ณ„๋ฅผ ์™„๋ฃŒํ•œ ํ›„ ๊ฐ ํ•ญ๋ชฉ์„ ํ™•์ธํ•ฉ๋‹ˆ๋‹ค:

  • ~/.claude/CLAUDE.md exists and contains /coord (์กด์žฌ ๋ฐ /coord ํฌํ•จ)
  • ~/.claude/settings.json has your API keys and hook paths (API ํ‚ค ๋ฐ ํ›… ๊ฒฝ๋กœ ํฌํ•จ)
  • ~/.claude/hooks/chavis_*.py files exist and are executable (์‹คํ–‰ ๊ฐ€๋Šฅํ•œ ํ›… ํŒŒ์ผ)
  • ~/.claude/projects/-home-USERNAME/memory/sycophancy/ directory exists (๋””๋ ‰ํ† ๋ฆฌ ์กด์žฌ)
  • npx -y @modelcontextprotocol/server-sequential-thinking runs without error (์˜ค๋ฅ˜ ์—†์ด ์‹คํ–‰)
  • Smoke test returns COORD_OK (์Šค๋ชจํฌ ํ…Œ์ŠคํŠธ ํ†ต๊ณผ)

If all items are checked, your installation is complete. (๋ชจ๋“  ํ•ญ๋ชฉ์ด ํ™•์ธ๋˜๋ฉด ์„ค์น˜๊ฐ€ ์™„๋ฃŒ๋˜์—ˆ์Šต๋‹ˆ๋‹ค.)