sem MCP
Semantic git for agents: shows changes by function and class and works out what an edit in the code touches.
- 3,450 ★ on the repository
- Last commit
Extended access
Why this level
- Reads repository source code and writes a cache to disk; cloud queries run only after separate consent.
Install
- Works in
In your terminal, with SkillFoxx CLI
npx skillfoxx add mcp/semDetects the agents on your machine, shows the access level and pins the version.
Other ways to install
Access and checks
How we reviewExtended accessThe tool runs code or makes network calls and only reads external data.
- Reads repository source code and writes a cache to disk; cloud queries run only after separate consent.
This is third-party code. Review the repository files before installing.
What it does
sem parses code with tree-sitter, extracts every function, class and method as a separate entity and compares versions entity by entity. Instead of "lines 40–62 changed" an agent sees "function parse_config was modified". Renames and moves are detected on their own, and whitespace or formatting edits are told apart from logic changes. The `sem mcp` command starts an MCP server over stdio. It gives the agent eight tools: definition lookup (`sem_find`), text search (`sem_grep`), change impact (`sem_impact`), change verification (`sem_check`), what a human should review (`sem_certify`), a diff between two revisions (`sem_diff`), a dependency graph (`sem_graph`) and entity history (`sem_history`). The same binary also works as a plain command-line tool in any git repository with no setup.
Who it is for. Developers on large repositories where an agent burns tokens reading whole files to answer one question about a function's callers.
Good fit when
- Before a refactor you need to know which functions and tests a signature change touches.
- A fifty-file review has to separate entities with changed logic from formatting-only edits.
- An agent looks up a function definition and its callers without reading neighbouring modules.
- A pre-commit check asks whether a change broke dependent parts of the code.
Not a fit when
- You need a line-by-line diff with context for a patch: plain `git diff` is enough.
- The project language is not among the tree-sitter parsers sem supports.
- Company policy forbids cloud queries against a private repository.
Example request
Show which functions a signature change to submitOrder would touch, and give only the context needed for the refactor.MCP
- Transport
- stdio, http
- Authentication
- not required
Environment variables
SEM_CACHE_DIR- Root directory of the entity cache, defaults to the OS cache.
Limitations
sem installs as a single Rust binary. The entity cache lives in SQLite outside the repository, and `SEM_CACHE_DIR` changes its path. The first query in a repository builds the `index.sem` index, so it takes longer than later ones on a large project. Cloud queries are enabled per repository: logging in uploads nothing by itself. The Streamable HTTP mode is described as a preview, and stdio is the default. Older tool names (`sem_entities`, `sem_callers`) still answer but are no longer listed.
How to disable. Remove the `sem` entry from the client MCP configuration (`claude mcp remove sem`). Uninstall the binary the way you installed it. Clear the entity cache by hand in the OS cache directory.
FAQ
How do I connect sem to Claude Code?
Run `claude mcp add sem -- sem mcp`. For Cursor and Claude Desktop add an `mcpServers` entry with the command `sem` and the argument `mcp`. If the binary is not on PATH, use its absolute path.
Do I need to install the MCP server separately?
No. The server ships in the same binary, and `sem mcp` starts it with no extra install.
What does `npx @ataraxy-labs/sem-skill` do?
It installs a skill that tells the agent when to reach for sem. The MCP connection stays a separate step.
How does `sem_diff` differ from `git diff`?
`sem_diff` reports which entities changed between two revisions, while `git diff` lists changed lines. Use the second for a patch and the first for analysing a change.
What does the sem cache hold and where is it?
The entity cache sits in SQLite in the OS cache directory, outside the repository. `SEM_CACHE_DIR` changes the cache root, and repo-local overrides are ignored so cache files do not dirty the working tree.
Discussion
No questions or reviews yet.
Related
MCP serversOne MCP server gives agents a code map across over 300 languages, git history, shared memory and document search with OCR.
Fast semantic code search for agents: returns the exact snippets instead of reading whole files and spends far fewer tokens
A structural code search MCP server for agents: finds the right file by query intent and runs locally
An MCP server that indexes code with tree-sitter and returns individual functions and classes to the agent instead of whole files
A git MCP server with 28 tools: an agent clones, commits, branches, merges, rebases and manages worktrees in local repositories.
A local MCP server with call graphs and symbol search: the agent sees code structure and what an edit affects in advance.
Comparison with similar tools
Cards that share the main search query, and how they differ.
| Tool | Official | Authentication | Repository stars | Main difference |
|---|---|---|---|---|
| sem (this card) | no | not required | 3,450 | |
| GitNexus | no | not required | 48,470 | indexes code into a knowledge graph; sem computes entities and change impact straight from git history |
| Weave | no | 1,356 | removes false merge conflicts; sem answers questions about callers and change impact |
README in short
Parsing goes through tree-sitter, the cache sits in SQLite, and the same commands exist as console verbs. Every verb accepts the `--json` flag.