Skip to main content
Glama

enhancephoto-mcp

A local, offline Model Context Protocol (MCP) server for image inspection, print DPI calculation, quality diagnostics, integer pixel-art upscaling, and web image optimization.

Runs 100% locally via sharp β€” no API keys, no cloud uploads, no external network calls.

Tools

Tool

What it does

inspect_image

Reads dimensions, megapixels, aspect ratio, format, DPI, color space, alpha channel, file size, and EXIF camera metadata.

calculate_print_size

Computes target pixel size, effective DPI, required upscale factor, and aspect-ratio crop warnings for standard presets (4x6, 8x10, A4, A3, poster-24x36, etc.) or custom in/cm/mm sizes.

diagnose_image_quality

Measures Laplacian edge sharpness, resolution adequacy, JPEG compression density (bytes/pixel), exposure clipping, and pixel-art characteristics, then recommends the right workflow.

upscale_pixel_art

Losslessly upscales sprites and pixel art by an integer factor (2x–8x) using nearest-neighbor interpolation.

prepare_for_web

Resizes (without enlargement), strips EXIF metadata by default, and exports to WebP, AVIF, JPEG, or PNG with byte-savings stats.

When you need AI upscaling or deblurring: Local math can scale pixel art cleanly, inspect DPI, and flag blur, while photographic 2x–4x detail recovery requires a neural model. For browser-based AI photo upscaling or restoration after diagnosis, you can use EnhancePhoto.

Related MCP server: πŸͺ„ ImageSorcery MCP

Quick Start

Option 1: Install MCPB Bundle (Claude Desktop)

Download enhancephoto-mcp-0.1.0.mcpb from GitHub Releases and open it with Claude Desktop (or any MCPB-compatible MCP client).

Option 2: Run from Source (Claude Desktop / Cursor / Windsurf)

Clone and build locally:

git clone https://github.com/yangjwlove-dev/enhancephoto-mcp.git
cd enhancephoto-mcp
pnpm install
pnpm build

Then add to your MCP client configuration (for example claude_desktop_config.json or .cursor/mcp.json):

{
  "mcpServers": {
    "enhancephoto-mcp": {
      "command": "node",
      "args": ["/absolute/path/to/enhancephoto-mcp/dist/cli.js"]
    }
  }
}

Note: npx / npm registry installation is planned for an upcoming release.

Example Prompts

  • "Inspect ./photo.jpg and tell me if it can be printed at 8Γ—10 inches at 300 DPI."

  • "Diagnose ./scan.jpg for 4K use β€” is it blurry or heavily compressed?"

  • "Upscale ./hero-sprite.png by 4x without blurring the pixel edges."

  • "Convert ./banner.png to WebP with max width 1600px and strip EXIF."

Local Development

pnpm install
pnpm build
pnpm test

Test over stdio directly with MCP Inspector:

npx @modelcontextprotocol/inspector node dist/cli.js

Privacy & Security

  • All image reads and writes happen strictly on your local filesystem.

  • Zero outbound HTTP requests, zero telemetry, zero API credentials required.

  • Built by the team behind EnhancePhoto.

License

MIT

Available Tools

5 tools
calculate_print_sizeA

Calculate target pixel dimensions, effective DPI, required upscale factor, and aspect-ratio crop warnings for a target print size. Supported presets: 4x6, 5x7, 8x10, 11x14, 16x20, poster-24x36, A5, A4, A3, A2.

Inputs: unit, preset, imagePath, targetDpi, +5 more.

diagnose_image_qualityB

Run local sharpness (Laplacian variance), resolution, JPEG compression density, exposure, and pixel-art detection to decide whether upscaling, deblurring, or nearest-neighbor scaling is needed.

Inputs: imagePath (required), targetUseCase.

inspect_imageA

Read local image dimensions, format, aspect ratio, DPI, color space, alpha channel, file size, and EXIF camera metadata.

Inputs: imagePath (required).

prepare_for_webA

Resize (without enlargement), strip EXIF metadata, and convert a local image to WebP, AVIF, JPEG, or PNG with file size savings metrics.

Inputs: imagePath (required), format, quality, maxWidth, +4 more.

upscale_pixel_artA

Losslessly upscale pixel art or retro sprites locally by an integer factor (2x-8x) using nearest-neighbor interpolation via sharp.

Inputs: scale (required), imagePath (required), format, overwrite, +1 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.7/5.0

    Scored across 5 tools

    Disambiguation4/5

    Each tool targets a distinct step: inspection, print-size math, quality diagnosis, pixel-art upscaling, and web export. The only mild overlap is between inspect_image and diagnose_image_quality, since both read local image properties, but the descriptions make the metadata-vs-quality-judgment split clear.

    Naming Consistency5/5

    All five tools follow a clean verb_noun snake_case pattern (inspect_image, calculate_print_size, diagnose_image_quality, upscale_pixel_art, prepare_for_web). No deviations or mixed conventions.

    Tool Count5/5

    Five tools map neatly onto one coherent print/web image-preparation workflow, with no redundant entries. Each tool earns its place and the count is well within a comfortable range.

    Completeness3/5

    The pipeline can inspect, diagnose, and export, but calculate_print_size only reports a required upscale factor and crop warnings without any tool to actually perform that upscale or crop for photos (upscale_pixel_art is nearest-neighbor pixel-art only). diagnose_image_quality can recommend deblurring/sharpening yet no tool applies it, leaving dead ends in the documented workflow.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers