Skip to main content
Glama

MCP SVG-Marp Server

An MCP (Model Context Protocol) server that converts SVG files to Marp presentations.

Features

  • Convert SVG files to Marp markdown presentations

  • Extract text content from SVG files

  • Generate PNG images from SVG for embedding in presentations

  • Analyze SVG structure and suggest presentation layout

  • Support for different Marp themes (default, gaia, uncover)

Related MCP server: marp-agent-mcp

Prerequisites

  • Node.js 18+

  • One of the following for SVG to PNG conversion:

    • ImageMagick (convert command)

    • Inkscape

    • librsvg (rsvg-convert command)

Installation

If you have Nix installed, you can use the provided flake:

# Enter development shell with all dependencies
nix develop

# Install Node.js dependencies
npm install

# Build the TypeScript project
npm run build

Manual Installation

# Install system dependencies (Ubuntu/Debian)
sudo apt-get install imagemagick inkscape librsvg2-bin

# Install Node.js dependencies
npm install

# Build the project
npm run build

Usage

Starting the MCP Server

npm start

The server communicates via stdio and implements the MCP protocol.

Available MCP Tools

convert_svg_to_marp

Converts an SVG file to a Marp presentation.

Parameters:

  • svgPath (required): Path to the input SVG file

  • outputPath (optional): Path for the output Marp markdown file

  • options (optional):

    • theme: Marp theme to use ("default", "gaia", or "uncover")

    • includeImage: Include the SVG as a PNG image (default: true)

    • extractText: Extract text from SVG for content (default: true)

Example:

{
  "tool": "convert_svg_to_marp",
  "arguments": {
    "svgPath": "/path/to/diagram.svg",
    "outputPath": "/path/to/presentation.md",
    "options": {
      "theme": "gaia",
      "includeImage": true,
      "extractText": true
    }
  }
}

analyze_svg

Analyzes an SVG file and suggests a Marp presentation structure.

Parameters:

  • svgPath (required): Path to the SVG file to analyze

Example:

{
  "tool": "analyze_svg",
  "arguments": {
    "svgPath": "/path/to/diagram.svg"
  }
}

Output Format

The generated Marp markdown includes:

  1. Front matter with Marp configuration

  2. Title slide with SVG title or first text element

  3. Image slide with the converted PNG (if enabled)

  4. Content slide with extracted text as bullet points (if available)

  5. Metadata slide with image dimensions and format information

Example Output

---
marp: true
theme: default
paginate: true
backgroundColor: #fff
backgroundImage: linear-gradient(to bottom right, #6366F1, #8B5CF6)
style: |
  section {
    font-family: 'Arial', sans-serif;
  }
  h1 {
    color: #FFFFFF;
    font-size: 56px;
  }
---

# My SVG Diagram

Description of the diagram

---

<!-- _class: centered -->

![SVG Content](diagram.png)

---

## Content

- First text element
- Second text element
- Third text element

---

## Image Information

- **Dimensions**: 800 × 600 pixels
- **Format**: SVG (Scalable Vector Graphics)

Using with Claude

This MCP server is designed to work seamlessly with Claude. When you ask Claude to create slides or presentations from SVGs, it will:

  1. Automatically create professional SVG designs based on your content

  2. Convert to Marp using the convert_svg_to_marp tool

  3. Provide both files - the original SVG and the Marp markdown

Trigger Phrases

Claude will automatically use this tool when you say things like:

  • "Convert this SVG to a Marp presentation"

  • "Make a slide from this diagram"

  • "Create a Marp presentation about [topic]"

  • "このSVGをMarpプレゼンに変換して"

Development

# Run in development mode (with hot reload)
npm run dev

# Build the project
npm run build

# Start the built server
npm start

Integration with Claude Desktop

To use this MCP server with Claude Desktop, add it to your MCP servers configuration:

{
  "mcpServers": {
    "svg-marp": {
      "command": "node",
      "args": ["/path/to/mcp-svg-marp/dist/index.js"]
    }
  }
}

Marp Output Capabilities

From the generated Marp markdown, you can create:

  • HTML presentations - Interactive slideshows for web browsers

  • PDF documents - For printing or sharing

  • PNG/JPEG images - Individual slide images

  • PowerPoint files - Using Marp CLI's PPTX export

Converting Marp to Other Formats

# Install Marp CLI globally
npm install -g @marp-team/marp-cli

# Convert to HTML
marp presentation.md -o presentation.html

# Convert to PDF
marp presentation.md -o presentation.pdf

# Convert to PPTX
marp presentation.md -o presentation.pptx

# Convert to PNG images
marp presentation.md -o slide.png

License

MIT

Available Tools

2 tools
analyze_svgB

Analyze an SVG file and suggest Marp presentation structure

ParametersJSON Schema
NameRequiredDescriptionDefault
svgPathYesPath to the SVG file to analyze

TDQS

B3.2/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description must carry the full behavioral burden. It conveys a read-only intent via 'Analyze' but does not disclose what the output looks like, whether it modifies anything, or any limitations. The minimal wording fails to give the agent a clear picture of the tool's runtime behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, concise sentence that avoids redundancy. It directly states the tool's purpose and output, with no wasted words.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

There is no output schema, so the description should at least hint at the returning structure or format, but it does not. Additionally, the sibling tool's existence suggests a workflow context that is unaddressed, leaving the description incomplete for practical use.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 100% coverage; the only parameter, svgPath, is described as 'Path to the SVG file to analyze', which is sufficient. The description does not add additional parameter-level detail, but baseline 3 applies since the schema fully documents the parameter.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific action ('Analyze an SVG file') and the intended output ('suggest Marp presentation structure'), making the tool's purpose immediately clear. It distinguishes itself from the sibling tool convert_svg_to_marp by emphasizing the suggestion/analysis aspect rather than direct conversion.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no explicit guidance on when to use this tool versus the sibling convert_svg_to_marp. It only states what it does, leaving the when-to-use decision entirely implicit.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

convert_svg_to_marpB

Convert an SVG file to a Marp presentation

ParametersJSON Schema
NameRequiredDescriptionDefault
optionsNoConversion options
svgPathYesPath to the input SVG file
outputPathNoPath for the output Marp markdown file (optional, defaults to same directory as SVG)

TDQS

B3.2/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, and the description does not disclose any side effects such as file creation, overwriting behavior, or required permissions. It also omits the default output path behavior, leaving the agent without crucial operational details.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, concise sentence that immediately states the tool's purpose without any unnecessary words or repetition.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description is minimal and fails to mention conversion options, the optional outputPath default, or how it relates to the sibling tool. While the schema provides parameter details, the description lacks operational context needed for an agent to fully understand the tool's behavior.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema fully documents all parameters. The description adds no additional parameter semantics, meeting the baseline expectation for coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool converts an SVG file to a Marp presentation, using a specific verb and resource. The verb 'convert' is distinct from the sibling tool 'analyze_svg', making the purpose unambiguous and well-differentiated.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no guidance on when to use this tool versus the sibling 'analyze_svg', nor any mention of prerequisites or conditions. The description only provides the basic action without usage context.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

TDQS

A3.5/5.0
Disambiguation5/5

Each tool has a clearly distinct purpose: one analyzes an SVG to suggest a Marp structure, the other converts an SVG to a Marp presentation. There is no functional overlap or ambiguity.

Naming Consistency5/5

Both tool names follow a consistent snake_case verb_noun pattern: convert_svg_to_marp and analyze_svg. The naming is predictable and clearly indicates the action and target.

Tool Count3/5

With only 2 tools, the server feels slightly thin for a conversion-oriented domain. However, the tools are tightly focused and cover the primary workflow, making the count borderline but defensible.

Completeness4/5

The core workflow of analyzing an SVG for structure and then converting it to Marp is fully covered. Minor gaps exist, such as no tool for managing multiple conversions or editing Marp output, but these are not dead ends for the main purpose.

Maintenance

ActivityInactive
ResponsivenessSyncing

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

Related MCP Servers

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/koppe-pan/mcp-svg-marp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server