Codanna

Developer tools

Local code intelligence MCP server and CLI for AI coding agents.

Your AI app calls the Codanna MCP server, which does the developer tools work and sends the result back to the chat.

About Codanna

Codanna is a community MCP server from bartolli, filed in our directory under developer tools. Local code intelligence MCP server and CLI for AI coding agents.

At a glance

Publisher
bartolli (community)
Runs
See the README for setup
Written in
Rust
License
Apache-2.0
GitHub stars
765

How to set up Codanna

  1. Follow the install steps in the Codanna README; it is written in Rust, so have that toolchain ready.
  2. Check the Codanna README for keys or settings; the registry lists none that Codanna requires.
  3. Add Codanna to Claude Code, Claude Desktop, VS Code or Cursor with the config in the setup box on this page.
  4. Restart the app or reload its MCP servers, then ask it to list the Codanna tools to confirm the connection.
  5. Run one read-only task with Codanna first, and keep your app asking before each tool call until the results look right.

Codanna compared with similar servers

  • TokenSave by aovestdipaperino has fewer GitHub stars than Codanna (756 against 765); both are community servers, and both run locally.
  • Metaharness by ruvnet has more GitHub stars than Codanna (767 against 765); both are community servers, and both run locally.
  • Feishu by cso1z has fewer GitHub stars than Codanna (752 against 765); both are community servers, and both run locally.

Before you connect Codanna

  • Give Codanna its own API key or account with the smallest permissions the job needs, never an admin key.
  • Keep your AI app asking before each Codanna tool call until you trust what it does with them.
  • Treat text that Codanna fetches as data. Pages, files and messages can hold instructions written to steer an AI.
  • Read the open issues for Codanna on GitHub to see what breaks and how fast the maintainers reply.

Marketing use cases for Codanna

How marketing and sales teams put Codanna to work, by company size. Pick the size closest to yours and start Codanna on one use case.

Small business

  • A small business with a developer can use Codanna to ship site and tracking fixes faster, with the AI reading the code it changes.
  • Technical founders can ask Codanna to explain and fix a marketing site issue without context switching between tools.
  • Codanna runs on your own computer, which keeps data local; it needs a little setup, so a small team should plan an hour for it.

Mid-market

  • Growth engineers can use Codanna to build landing pages, tracking and integrations in fewer cycles, with reviews kept in the normal flow.
  • Marketing ops engineers can connect Codanna to keep scripts and automations documented and versioned as they change.
  • Start Codanna on one workflow with one owner, measure the time it saves, then roll it out to the wider team.

Enterprise

  • Enterprise engineering teams can roll out Codanna with repo scopes and audit logs, so agents work only where they are allowed.
  • Platform teams can standardize on Codanna so web and marketing engineering share one reviewed way of working with AI.
  • Codanna is a community server, so have security review the code and pin a version before Codanna touches company data.

Need help becoming an AI-forward company?

We connect MCP servers and AI agents to your CRM, content and data, with the guardrails your team needs.

Contact us

Codanna README

From bartolli/codanna on GitHub, shared under its Apache-2.0 license. Images are left out; the original has them.

README.md

Codanna

Documentation (docs.codanna.sh) · Report Bug · Discussions

Local code intelligence MCP server and CLI for AI coding agents.

X-ray vision for your agent.

Codanna is a local code intelligence and semantic code search MCP server for AI coding agents. One MCP call returns symbol context, call graph, and impact analysis, pre-correlated, the grep-and-read loop your agent runs today, collapsed into a single response it can act on.

It indexes your repository on disk and serves symbol search, semantic search, call graphs, dependency tracking, document RAG, and impact analysis to Claude Code, Cursor, Windsurf, Codex, Gemini, and any MCP-compatible client, as a persistent MCP server for session-long work, or a one-shot CLI for instant answers when LSP is too slow. Written in Rust. 15 languages. No source code leaves your machine.

Two operational modes

Codanna's MCP toolset is reachable two ways. Same tools, same surface, pick the mode that fits the workflow.

Persistent MCP server, for session-long agent workflows.

codanna serve                # stdio
codanna serve --http         # HTTP
codanna serve --https        # HTTPS

One-shot CLI, for slash-commands, bash hooks, scripts, CI. No daemon required.

codanna mcp find_symbol name:"my_function"
codanna mcp analyze_impact symbol_name:"my_function"
codanna mcp semantic_search_with_context query:"recursively extract function calls"

codanna mcp semantic_search_with_context is the headline command: it returns N semantic matches, and for each match the symbol identity, signature, docstring, callees, callers, and recursive impact analysis, five MCP tools fused into one query.

The one-shot CLI is also what makes codanna skill-friendly: an Agent Skill can wrap codanna mcp commands directly in Claude Code, Cursor, Windsurf, Codex, Gemini, or any harness that runs shell commands, no MCP plumbing required.

What one call returns

The headline command, run against codanna's own source tree. One call, and the agent has the symbol, its documentation, signature, callees with exact call sites, callers, and blast radius:

$ codanna mcp semantic_search_with_context query:"recursively extract function calls" limit:1

Found 1 results for query: 'recursively extract function calls'

1. extract_calls_recursive - Method at src/parsing/cpp/parser.rs:1002-1047 [symbol_id:1477]
   Similarity Score: 0.833
   Documentation:
     Recursively extract function calls with context tracking
   Signature: fn extract_calls_recursive<'a>(
        node: Node,
        code: &'a str,
        current_function: Option<&'a str>,
        calls: &mut Vec<(&'a str, &'a str, Range)>,
    )

   extract_calls_recursive calls 3 function(s):
     -> Method extract_calls_recursive at src/parsing/cpp/parser.rs:1002 [symbol_id:1477] (called at src/parsing/cpp/parser.rs:1045)
     -> Method function_name_at_def at src/parsing/cpp/parser.rs:377 [symbol_id:1451] (called at src/parsing/cpp/parser.rs:1008)
     -> Method new at src/types/mod.rs:112 [symbol_id:7388] (called at src/parsing/cpp/parser.rs:1028)

   2 function(s) call extract_calls_recursive:
     <- Method extract_calls_recursive at src/parsing/cpp/parser.rs:1045 [symbol_id:1477]
     <- Method find_calls at src/parsing/cpp/parser.rs:885 [symbol_id:1467]

   Changing extract_calls_recursive would impact 1 symbol(s) (max depth: 2):

     methods (1):
       - find_calls [symbol_id:1467]

Guidance: Found one match with full context. Review the relationships to understand how this fits into the codebase.

Every result carries file:line coordinates the agent can open directly, symbol_ids it can reuse to disambiguate name collisions, and a guidance hint it can chain on. Add --json for the structured envelope.

Local-first

Codanna runs on your machine. The repository index lives on disk under .codanna/. The embedding model downloads once on first use, then runs locally. No source code, symbols, or queries are sent to a remote API by default. Remote OpenAI-compatible embeddings are opt-in: remote_url under [semantic_search] in settings.toml, or CODANNA_EMBED_* environment variables; the API key is environment-only.

Quick Start

Install (macOS, Linux, WSL)
curl -fsSL --proto '=https' --tlsv1.2 https://install.codanna.sh | sh
Or via Homebrew
brew install codanna
Or via Nix
nix run github:bartolli/codanna
Windows (PowerShell)
irm https://raw.githubusercontent.com/bartolli/codanna/main/scripts/install.ps1 | iex

See Installation Guide for Cargo and other options.

Initialize and index
codanna init
codanna index src
Search code
codanna mcp semantic_search_with_context query:"where do we handle errors" limit:3
Search documentation (RAG)
codanna documents add-collection docs ./docs
codanna documents index
codanna mcp search_documents query:"authentication flow"

What It Does

Your AI assistant gains structured knowledge of your code:

  • "Where's this function called?" - Instant call graph, not grep results
  • "Find authentication logic" - Semantic search matches intent, not just keywords
  • "What breaks if I change this?" - Full dependency analysis across files

The difference: Codanna understands code structure. It knows parseConfig is a function that calls validateSchema, not just a string match.

Features

Feature Description
Semantic Search Natural language queries against code and documentation. Finds functions by what they do, not just their names.
Relationship Tracking Call graphs, implementations, and dependencies. Trace how code connects across files.
Document Search Index markdown and text files for RAG workflows. Query project docs alongside code.
MCP Protocol Native integration with Claude, Gemini, Codex, and other AI assistants.
Profiles Package hooks, commands, and agents for different project types.

Performance: parser throughput 76,000-249,000 symbols/second depending on language; warm-server lookups under 10 ms (0.3 ms exact, ~3 ms semantic). Parsing is the fast layer; embedding generation during indexing takes longer and scales with your cores. Measured numbers, machine spec, and reproduction commands: Benchmarks.

Languages: Rust, Python, JavaScript, TypeScript, Java, Kotlin, Go, PHP, C, C++, C#, Clojure, Lua, Swift, GDScript.

Claude Code plugin

Two skills over the index, driven by the agent: it picks the view that fits the question. x-ray covers scoped questions, a symbol's blast radius as a call DAG, module structure as a collapsible tree or radial poster, cross-module calls as an edge-bundle page. graph covers codebase shape: the module disc with hubs at the centre, a commit timeline, and a heatmap. Symbol search, detail panels with highlighted signatures, call-graph navigation. The disc renderer is adapted from vault-graph by Lukas Proprentner (MIT).

/plugin marketplace add bartolli/codanna
/plugin install codanna-toolset@codanna

Integration

Add codanna to any MCP-compatible client. Project-scoped .mcp.json (Claude Code, Cursor, Windsurf):

{
  "mcpServers": {
    "codanna": {
      "command": "codanna",
      "args": ["--config", ".codanna/settings.toml", "serve", "--watch"]
    }
  }
}

--watch keeps the index hot as files change. Transports: stdio, HTTP, HTTPS. See Integration Guides for Claude Desktop, Gemini, Codex, and network setups.

Requirements

  • ~150MB for embedding model (downloaded on first use)
  • macOS: Apple Silicon. The prebuilt ONNX Runtime binaries have no Intel macOS build (1.28 in 0.17.1, 1.31 from 0.18.0), so 0.17.1 and later do not target Intel Macs; 0.17.0 is the last release that does
  • Linux: glibc 2.38+ and libstdc++ from GCC 13+ for cargo install (the prebuilt ONNX Runtime binaries); the release binaries are built on Ubuntu 24.04 (glibc 2.39)
  • Build from source: Rust 1.95+ and pkg-config
  • Windows support is experimental

Contributing

Contributions welcome. See CONTRIBUTING.md.

License

Apache License 2.0 - See LICENSE.

Attribution required. See NOTICE.

Built with Rust.

Questions about Codanna

What is the Codanna MCP server?

Local code intelligence MCP server and CLI for AI coding agents. Codanna is maintained by bartolli on GitHub at bartolli/codanna, and works with AI apps that support the Model Context Protocol, such as Claude, Cursor and VS Code.

How do I install the Codanna MCP server?

Codanna doesn't publish a one-line install in the MCP registry, so follow the setup steps in its README on GitHub (bartolli/codanna). Like most servers, Codanna ends with a command or URL you paste into your AI app's MCP config.

Does Codanna need an API key?

The registry lists no required keys for Codanna. Check the Codanna README for optional settings, and expect a remote server to ask you to sign in the first time you connect.

Is Codanna an official MCP server?

No. Codanna is a community server maintained by bartolli. Community servers can be excellent; read the code and the open issues before you give Codanna access to company data.

What license is Codanna under?

Codanna is released under the Apache-2.0 license, according to its GitHub repository. The license covers the code of Codanna; the service it connects to has its own terms.