CodeToPrompt MCP Server
An MCP server for the codetoprompt library, enabling integration with LLM agents.
CodeToPrompt MCP Server
CodeToPrompt MCP Server exposes the powerful features of the codetoprompt library through the Model Context Protocol (MCP). This allows LLM agents and other MCP-compatible clients to programmatically generate prompts, analyze codebases, and retrieve specific file contents.
🔧 Installation
Install from PyPI:
pip install codetoprompt-mcp
This will automatically install codetoprompt and the required mcp library.
🚀 Usage with an MCP Client
This server is designed to be used with an MCP client, such as the Claude Desktop App.
Example: Claude Desktop Configuration
To use this server with Claude, add it to your claude_desktop_config.json file:
{
"mcpServers": {
"CodeToPrompt": {
"command": "ctp-mcp"
}
}
}
Once configured, you can invoke the tools from your conversation with the LLM.
Available Tools
ctp-get-context: The primary tool for generating a comprehensive prompt from a directory. It supports all ofcodetoprompt's filtering, formatting, and compression options.ctp-analyse-project: Provides a detailed statistical analysis of a codebase, including token counts, line counts, and breakdowns by file type.ctp-get-files: Retrieves the content of specific files, formatted as a prompt. This is useful for targeted queries.
🤝 Contributing
We welcome contributions! Please refer to the main codetoprompt repository for contribution guidelines.
📄 License
This project is licensed under the MIT License. See the LICENSE file for full details.
Máy chủ liên quan
Scout Monitoring MCP
nhà tài trợPut performance and error data directly in the hands of your AI assistant.
Alpha Vantage MCP Server
nhà tài trợAccess financial market data: realtime & historical stock, ETF, options, forex, crypto, commodities, fundamentals, technical indicators, & more
LaTeX to MathML MCP Server
Converts LaTeX mathematical expressions to MathML format using MathJax-node.
Qase
Interact with the Qase API for test management. Requires a QASE_API_TOKEN for authentication.
ast-grep MCP
An experimental MCP server that uses the ast-grep CLI for code structural search, linting, and rewriting.
webrtcperf
WebRtcPerf is an open-source tool designed for testing WebRTC services with multiple concurrent client connections, measuring the most important RTC statistics and collecting them in an easy way.
Mastra/mcp
Client implementation for Mastra, providing seamless integration with MCP-compatible AI models and tools.
Steadybit
Interact with the Steadybit platform to run chaos engineering experiments.
Reactive AI Agent Framework
A reactive AI agent framework for creating agents that use tools to perform tasks, with support for multiple LLM providers and MCP servers.
MemGPT MCP Server
A server that provides a memory system for LLMs, enabling persistent conversations with various providers like OpenAI, Anthropic, and OpenRouter.
mcpproxy-go
Open-source local MCP proxy server. Routes multiple MCP servers through a single endpoint with BM25 tool filtering, quarantine security, activity logging, and web UI.
MCP Servers Nix
A Nix-based configuration framework for deploying MCP servers with ready-to-use packages, supporting modular and reproducible builds.