@lex-tools/codebase-context-dumper
Officialcodebase-context-dumper Сервер MCP
Сервер протокола контекста модели (MCP), предназначенный для простого переноса контекста вашей кодовой базы в большие языковые модели (LLM).
Зачем это использовать?
Большие контекстные окна в LLMs — это мощно, но ручной выбор и форматирование файлов из большой кодовой базы — утомительно. Этот инструмент автоматизирует процесс следующим образом:
Рекурсивное сканирование каталога вашего проекта.
Включение текстовых файлов из указанного дерева каталогов, которые не исключены правилами
.gitignore.Автоматический пропуск двоичных файлов.
Объединение содержимого с четкими маркерами пути к файлу.
Поддержка фрагментации для обработки кодовых баз, размер которых превышает окно контекста LLM.
Полная интеграция с MCP-совместимыми клиентами.
Related MCP server: code-index-mcp
Использование (рекомендуется: npx)
Самый простой способ использовать этот инструмент — через npx , который запускает последнюю версию без необходимости локальной установки.
Настройте свой клиент MCP (например, Claude Desktop, расширения VS Code) для использования следующей команды:
{
"mcpServers": {
"codebase-context-dumper": {
"command": "npx",
"args": [
"-y",
"@lex-tools/codebase-context-dumper"
]
}
}
}После этого клиент MCP сможет вызвать инструмент dump_codebase_context , предоставляемый этим сервером.
Характеристики и сведения об инструментах
Инструмент: dump_codebase_context
Рекурсивно считывает текстовые файлы из указанного каталога, соблюдая правила .gitignore и пропуская двоичные файлы. Объединяет содержимое с заголовками/нижними колонтитулами пути к файлу. Поддерживает разбиение вывода на фрагменты для больших кодовых баз.
Функциональность :
Сканирует каталог, указанный в
base_path.Учитывает файлы
.gitignoreна всех уровнях (включая вложенные и.gitпо умолчанию).Обнаруживает и пропускает двоичные файлы.
Считывает содержимое каждого допустимого текстового файла.
Добавляет заголовок (
--- START: relative/path/to/file ---) и нижний колонтитул (--- END: relative/path/to/file ---) к содержимому каждого файла.Объединяет все обработанное содержимое файла в одну строку.
Входные параметры :
base_path(строка, обязательно): абсолютный путь к каталогу проекта для сканирования.num_chunks(целое число, необязательно, по умолчанию: 1): Общее количество фрагментов, на которые нужно разделить вывод. Должно быть >= 1.chunk_index(целое число, необязательно, по умолчанию: 1): Индекс возвращаемого фрагмента, начинающийся с 1. Требуетnum_chunks > 1иchunk_index <= num_chunks.
Вывод : возвращает объединенное (и потенциально разбитое на фрагменты) текстовое содержимое.
Локальная установка и использование (расширенная)
Если вы предпочитаете запустить локальную версию (например, для разработки):
Клонируйте репозиторий:
git clone git@github.com:lex-tools/codebase-context-dumper.git cd codebase-context-dumperУстановить зависимости:
npm installСборка сервера:
npm run buildНастройте клиент MCP так, чтобы он указывал на локальный вывод сборки:
{ "mcpServers": { "codebase-context-dumper": { "command": "/path/to/your/local/codebase-context-dumper/build/index.js" // Adjust path } } }
Внося вклад
Вклады приветствуются! Подробности о разработке, отладке и выпуске новых версий см. на сайте CONTRIBUTING.md.
Лицензия
Этот проект лицензирован по Apache License 2.0. Подробности смотрите в файле LICENSE .
Available Tools
1 tooldump_codebase_contextA
Recursively reads text files from a specified directory, respecting .gitignore rules and skipping binary files. Concatenates content with file path headers/footers. Supports chunking the output for large codebases.
| Name | Required | Description | Default |
|---|---|---|---|
| base_path | Yes | The absolute path to the project directory to scan. | |
| num_chunks | No | Optional total number of chunks to divide the output into (default: 1). | |
| chunk_index | No | Optional 1-based index of the chunk to return (default: 1). Requires num_chunks > 1. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It effectively describes key operational traits: recursive file reading, .gitignore respect, binary file skipping, output formatting with headers/footers, and chunking for large outputs. However, it doesn't mention potential limitations like file size constraints, permission requirements, or error handling, leaving some gaps.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is highly concise and well-structured in two sentences: the first covers core functionality and constraints, the second addresses scalability. Every phrase adds value (e.g., 'respecting .gitignore rules', 'skipping binary files', 'chunking the output'), with no wasted words or redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's moderate complexity (recursive file operations, chunking) and lack of annotations/output schema, the description does a good job covering core behavior and constraints. It explains what the tool does, key features, and output handling, but omits details like return format, error scenarios, or performance implications, which would enhance completeness for an agent.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the input schema already fully documents all three parameters (base_path, num_chunks, chunk_index). The description adds no additional parameter-specific information beyond what's in the schema, such as examples or edge cases. The baseline score of 3 reflects adequate but minimal value addition from the description.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the specific action ('recursively reads text files', 'concatenates content with file path headers/footers') and resource ('from a specified directory'), including key behavioral details like respecting .gitignore rules and skipping binary files. With no sibling tools, it fully defines the tool's unique purpose without redundancy.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for scanning codebases ('large codebases') and mentions chunking for scalability, but provides no explicit guidance on when to use this tool versus alternatives or any prerequisites. Since there are no sibling tools, the lack of comparative guidance is less critical, but still leaves usage context somewhat open-ended.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
1 tool update
- First observed
dump_codebase_context
TDQS
With only one tool, there is no possibility of ambiguity or overlap between tools. The tool has a single, clearly defined purpose.
A single tool inherently has perfect naming consistency, as there are no other tools to compare it against for patterns or conventions.
One tool is too few for most practical server purposes, as it severely limits functionality and interaction. While the tool is well-described, a single tool feels thin and incomplete for a codebase context server.
The server's purpose appears to be codebase context management, but with only a dump tool, there are significant gaps. Missing operations like search, filter, update, or delete context make the surface incomplete and likely insufficient for agent workflows.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
A Model Context Protocol server for Wix AI tools
Model Context Protocol server for the Apideck Unified API. Connect any MCP-compatible agent framework to 100+ accounting systems, HRIS platforms, file storage providers, and more through one integration. More information https://www.apideck.com/mcp-server
Enable secure connectivity between Sentry issues and debugging data, and LLM clients, using a Model Context Protocol (MCP) server.
Related MCP Servers
- AlicenseBqualityFmaintenanceA Model Context Protocol server that enables LLMs to read, search, and analyze code files with advanced caching and real-time file watching capabilities.61939MIT
- AlicenseAqualityAmaintenanceA Model Context Protocol (MCP) server that helps large language models index, search, and analyze code repositories with minimal setup141,005MIT

CodeAlive MCPofficial
AlicenseNot gradedqualityAmaintenanceA Model Context Protocol server that enhances AI agents by providing deep semantic understanding of codebases, enabling more intelligent interactions through advanced code search and contextual awareness.89MIT- FlicenseNot gradedqualityDmaintenanceA Model Context Protocol (MCP) server that provides VSCode context and filesystem operations for AI assistants.9-
Appeared in Searches
- A tool for debugging Pine Script code
- How to convert Figma files to React code
- A platform for hosting and sharing code
- Using separate agents for schema validation, code standards, and directory structure enforcement in development workflows
- Finding the Top 10 Most Frequently Pulled Packages from Nexus Repository
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/lex-tools/codebase-context-dumper'
If you have feedback or need assistance with the MCP directory API, please join our Discord server