repo-context
Integrates with OpenAI-compatible chat completion APIs to enable repository exploration through natural language queries, providing read-only tools like file reading, glob, and grep.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@repo-contextFind the request validation logic in the repository"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
repo-context
Read-only repository context explorer for coding agents.
The canonical architecture is a local CLI-first exploration core that talks to an OpenAI-compatible FastContext-style model endpoint. MCP is an adapter around the same core, not the primary abstraction.
Current Status
This repository has the initial Python 3.13+ implementation for spec 001:
CLI, shared exploration core, read-only repository tools, OpenAI-compatible
chat-completions client, optional trajectory logging, and a thin MCP adapter.
Primary planning artifacts:
Related MCP server: code_nav MCP
Usage
Use the CLI first for local debugging, scripts, CI checks, and one-off questions. It has the smallest moving parts and exposes the exact core result.
Use MCP when an MCP-capable editor or agent should call repository exploration as a tool during its workflow. MCP delegates to the same core as the CLI.
Configure
Prefer .repo-context.toml for stable project-local settings:
cp .repo-context.toml.example .repo-context.tomlUse environment variables for temporary overrides, CI, or secrets:
cp .env.example .envrepo-context reads real environment variables from the process environment;
it does not load .env by itself. Configure at least:
FASTCONTEXT_BASE_URL=http://localhost:8000/v1
FASTCONTEXT_MODEL=your-model-nameConfiguration precedence:
defaults < .repo-context.toml < environment variables < CLI overridesCLI
Text output:
uv run repo-context explore \
--query "Find the request validation logic" \
--repo . \
--max-turns 6 \
--citationJSON output:
uv run repo-context explore \
--query "Find the request validation logic" \
--repo . \
--format jsonMCP
Install optional MCP dependencies:
uv sync --extra mcpDevelopment server command:
uv run repo-context mcp --transport stdioTool: explore_repository(query, repo_root?, max_turns?, citation?)
Generic MCP client config shape:
{
"mcpServers": {
"repo-context": {
"command": "uv",
"args": [
"run",
"--project",
"/path/to/repo-context",
"--extra",
"mcp",
"repo-context",
"mcp",
"--transport",
"stdio"
],
"env": {
"FASTCONTEXT_BASE_URL": "http://localhost:8000/v1",
"FASTCONTEXT_MODEL": "your-model-name"
}
}
}
}Validate
uv run pytest
uv run ruff check .
uv run mypyScope
In scope:
Local, read-only repository exploration.
Root-scoped
read_file,repo_glob, andrepo_greptools.OpenAI-compatible chat completion loop with bounded tool observations.
CLI output with file paths and line-range citations.
MCP adapter that delegates to the CLI/core implementation.
Out of scope for the MVP:
Repository mutation.
Vector database ownership or embedding/model serving.
MCP-first
context_search,context_pack, andcontext_gettools.OKF bundle output.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Tools
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/zyf0717/repo-context'
If you have feedback or need assistance with the MCP directory API, please join our Discord server