Last time I posted codetree it had 16 tools and 921 tests. Since then it's been completely
reworked. Here's what changed and why.

---

WHAT CHANGED: 16 tools -> 23 tools (was 30, consolidated to 23)

The original version could read code structure and navigate relationships. The new version
understands your entire codebase as a graph — it can trace data flow, find security issues,
analyze git history, and onboard itself to unfamiliar repos without you telling it where
to start.

---

NEW: PERSISTENT CODE GRAPH (the biggest change)

codetree now builds a SQLite graph of every symbol and relationship in your repo. This
enables things that were impossible before:

  - get_repository_map — agent drops into an unfamiliar repo and instantly knows: what
    languages, what the entry points are, what the hotspots are, where to start reading.
    No more "let me read every file to understand the project."

  - get_change_impact — you changed a function. This tells the agent every caller
    (direct and transitive), classifies risk as CRITICAL/HIGH/MEDIUM, and lists which
    tests are affected. Works with git diffs too — "what's the impact of my uncommitted
    changes?"

  - resolve_symbol — agent sees "add" in code. Which add? This disambiguates to
    the exact qualified symbol with file and line, ranked by relevance.

  - search_graph — structured search with degree filters. "Show me all functions
    with 5+ callers" finds your most important code instantly.

  The graph updates incrementally using sha256 content hashing — only re-indexes files
  that actually changed. Sub-second updates on large repos.

---

NEW: SECURITY TAINT ANALYSIS

  analyze_dataflow — three modes in one tool:

  - mode="flow": traces how data moves through variables in a function. Shows dependency
    chains, external sources, dangerous sinks.

  - mode="taint": finds paths from untrusted input (request data, env vars, file reads)
    to dangerous operations (SQL queries, shell commands, eval). Classifies each path
    as SAFE (sanitizer found) or UNSAFE (direct flow to sink).

  - mode="cross_taint": follows tainted data across function call boundaries. If user
    input flows into helper_function(), it traces INTO that function to see if it
    reaches a sink there. Recurses up to N levels deep.

  This means your agent can now audit code for injection vulnerabilities automatically.

---

NEW: GIT HISTORY ANALYSIS

  git_history — three modes:

  - mode="blame": who wrote each line, when, which commit
  - mode="churn": most-changed files ranked by commit count — these are where bugs live
  - mode="coupling": files that always change together — hidden dependencies your
    architecture diagram doesn't show

---

NEW: HOT PATH DETECTION

  find_hot_paths — finds functions that are BOTH complex AND called frequently.
  complexity * caller_count = optimization priority. These are the functions where
  a 10% speedup actually matters.

---

NEW: DEPENDENCY VISUALIZATION

  get_dependency_graph — outputs file-level import graph as Mermaid syntax. Paste it
  into any Mermaid renderer and see your module structure. Also detects circular
  dependencies.

---

NEW: DOCUMENTATION SUGGESTIONS

  suggest_docs — finds undocumented functions and assembles context (what they call,
  who calls them, what variables they use) so the agent can write accurate docstrings
  without reading the entire file.

---

WHAT GOT CONSOLIDATED (30 -> 23)

Having 30 tools meant 30 tool descriptions eating the agent's context window. Consolidated
related tools using mode parameters:

  - 3 dataflow tools -> 1 (analyze_dataflow with mode)
  - 3 git tools -> 1 (git_history with mode)
  - Removed 3 tools covered by better alternatives (get_ast, get_variables, rank_symbols)

Same capabilities, 23% fewer tool descriptions consuming context.

---

BY THE NUMBERS

  Before:  16 tools,  921 tests, tree-sitter parsing only
  Now:     23 tools, 1058 tests, tree-sitter + SQLite graph + dataflow + git analysis

  10 languages: Python, JS/JSX, TS/TSX, Go, Rust, Java, C, C++, Ruby
  ~1 second startup. No external services. No config.

---

QUICK START (unchanged — still one command)

  claude mcp add codetree -- uvx --from mcp-server-codetree codetree --root .

  Works with Claude Code, Cursor, VS Code Copilot, Windsurf, Zed, Claude Desktop.

  GitHub: https://github.com/ThinkyMiner/codeTree
  Website: https://code-tree-website.vercel.app/
  PyPI: https://pypi.org/project/mcp-server-codetree/

---

What should I build next? The graph layer opens up a lot of possibilities — thinking
about things like architectural pattern detection, automatic refactoring suggestions,
or cross-repo analysis. What would actually help your workflow?
