Diagram as Code MCP Server
This is a MCP server to provide mermaid js validation tools and prompt for MCP client
Why Use This MCP Server?
This MCP server is essential for MCP clients working with Mermaid.js diagrams. Large Language Models (LLMs) might be trained with older data and outdated Mermaid.js syntax, and they may not have enough content trained to effectively fix syntax errors. This server addresses these critical limitations by providing specialized tools to assist in authoring, validating, and automatically fixing Mermaid.js syntax, ensuring diagrams are correctly formatted and functional.
Features
- No Brackets Description: A prompt to instruct bots to avoid using brackets in descriptions.
- Mermaid.js Support: A tool to assist in authoring, validating, and fixing syntax for Mermaid.js diagrams.
Setup
- Clone this repository
- Install Python dependencies:
- Run the server:
Running Options
- Default stdio mode:
python -m hkopenai.diagram_as_code_mcp_server
- SSE mode (port 8000):
python -m hkopenai.diagram_as_code_mcp_server --sse
- Serve prompt as tool:
python -m hkopenai.diagram_as_code_mcp_server --tool
Cline Integration
Cline does not support prompt from mcp server at this moment. The prompt is provided as tool:
To connect this MCP server to Cline using stdio:
- Add this configuration to your Cline MCP settings (cline_mcp_settings.json):
Testing
Tests are available in tests
. Run with:
This server cannot be installed
hybrid server
The server is able to function both locally and remotely, depending on the configuration or use case.
An MCP server that provides custom prompts for guiding bot interactions, specifically to avoid using brackets in descriptions.
Related MCP Servers
- AsecurityAlicenseAqualityAn MCP server that enables posting messages to Discord webhooks, allowing customization of content, username, and avatar URL.Last updated -10JavaScriptMIT License
- -securityAlicense-qualityAn MCP server that analyzes codebases and generates contextual prompts, making it easier for AI assistants to understand and work with code repositories.Last updated -10PythonMIT License
- -security-license-qualityAn MCP server that provides tools for interacting with Anthropic's prompt engineering APIs, allowing users to generate, improve, and templatize prompts based on task descriptions and feedback.Last updated -1TypeScriptISC License
- -securityFlicense-qualityAn MCP server that provides user dialogue capabilities for AI code editors, allowing AI to interact with users through dialog boxes when needing input during the coding process.Last updated -Python