Skip to main content
Glama

mcp-ink-design ✒️

Model Context Protocol (MCP) Server for High-Craft Web Design & Engineering.
Defeating "AI Slop" through bespoke OKLCH color harmonies, mathematical fluid typography, layered physical depth, Three.js 3D experiences, OWASP security audits, and dedicated Python verification.


💎 The Anti-AI-Slop Manifesto (INK_MASTER.md)

Most AI-generated web interfaces look generic, repetitive, and bland:

  • Cliche #6366f1 / #a855f7 purple-to-blue linear gradients on dark cards.

  • Rigid pixel typography that breaks or looks clumsy on mobile devices.

  • Single harsh black drop-shadows instead of layered ambient occlusion.

  • Div-heavy markup lacking semantic landmarks (<main>, <header>, <nav>).

  • Dangerous client-side DOM injections (innerHTML, eval) and tokens stored in localStorage.

mcp-ink-design enforces a human-grade architectural standard:

  1. Perceptually Uniform OKLCH Color Spaces: Uniform lightness and chroma without dead gray zones in gradients.

  2. Mathematical Fluid Typography: Smooth viewport scaling using clamp(min, preferred, max).

  3. Tactile Micro-Interactions: Real physical response curves (cubic-bezier(0.16, 1, 0.3, 1)).

  4. Purposeful 3D WebGL / Three.js: Responsive canvases with devicePixelRatio clamping and memory disposal cleanup.

  5. Zero-Trust Security & Auth: Strict Content Security Policy (CSP), safe DOM sinks, and HttpOnly cookie architecture.

  6. External Verification Suite: Automated Python linter for AST security, contrast calculations, and design heuristics.


Related MCP server: web-design-harvester

🛠️ Tool Suite (tools/list — 11 Standardized Tools)

All 11 tools strictly follow the MCP Glama Benchmark standards (ink_<verb>_<noun>, explicit MCP tool annotations, typed output schemas, and operational usage guidelines):

Canonical Tool Name

Title

Verb + Noun

Annotations

Output Schema

Purpose

ink_create_base

Scaffold Web Application Foundation

create + base

readOnlyHint: true

CreateBaseOutputSchema

Scaffolds complete semantic HTML5, CSS architecture, OKLCH tokens, and main.js

ink_generate_palette_tokens

Generate OKLCH Palette & Design Tokens

generate + palette_tokens

readOnlyHint: true

PaletteTokensOutputSchema

Generates bespoke OKLCH palettes, CSS custom properties, and WCAG AAA contrast ratios

ink_craft_component

Craft UI Component with Tactile Physics

craft + component

readOnlyHint: true

CraftComponentOutputSchema

Crafts tactile components (glass-card, tactile-button, hero-section, navigation-bar, etc.)

ink_build_threejs_experience

Build 3D WebGL Canvas Experience

build + threejs_experience

readOnlyHint: true

ThreejsExperienceOutputSchema

Generates memory-safe Three.js canvas experiences (particle-constellation, geometric-wireframe)

ink_generate_script_logic

Generate Modular Architecture Logic

generate + script_logic

readOnlyHint: true

ScriptLogicOutputSchema

Generates zero-dependency logic modules (state-store, event-bus, scroll-observer, form-validator)

ink_audit_security

Audit Frontend Code Security & Headers

audit + security

readOnlyHint: true

SecurityAuditOutputSchema

Scans code for DOM XSS, eval, token leakage in localStorage, and generates tailored CSP headers

ink_validate_design

Validate Design Craft & Contrast Compliance

validate + design

readOnlyHint: true

ValidateDesignOutputSchema

Computes Craft Grade (S, A, B, C), checks anti-slop rules, evaluates contrast, and audits RTL/LTR logical properties

ink_run_python_tests

Run Python AST & Contrast Verification Suite

run + python_tests

readOnlyHint: true

PythonTestRunnerOutputSchema

Executes the dedicated Python testing suite (ink_verifier) via stdin JSON pipeline

ink_capture_viewport

Capture Multi-Viewport Responsive Snapshots

capture + viewport

readOnlyHint: false

CaptureViewportOutputSchema

Captures 16:9 Desktop, 9:16 Story, and 390x844 Mobile snapshots with automated overflow checks

ink_inspect_website_style

Inspect & Reverse-Engineer Website Style

inspect + website_style

readOnlyHint: true

InspectWebsiteStyleOutputSchema

Deconstructs any website (URL or HTML/CSS) into an OKLCH palette, font hierarchy, and design blueprint

ink_import_custom_assets

Import & Configure Web Fonts and Assets

import + custom_assets

readOnlyHint: true

ImportCustomAssetsOutputSchema

Configures dynamic Google Fonts imports (Arabic & Latin) and generates CSS variables with optical line-heights


🌍 Arabic Typography & RTL/LTR Logical Properties

mcp-ink-design includes first-class engineering for Arabic and bilingual web apps:

  • Modern CSS Logical Properties: Automatically enforces margin-inline, padding-inline, inset-inline, and text-align: start instead of hardcoded physical directions.

  • Arabic Optical Compensation: Line-heights for Arabic glyphs are adjusted to 1.75 - 1.85 for body text to avoid diacritic and ascender clipping.

  • Curated Arabic Font Stacks: IBM Plex Sans Arabic, Cairo, Tajawal, Readex Pro, and Amiri.

  • Bidi Isolation: Automated <bdi> wrapping and unicode-bidi: isolate prevent punctuation jumping in mixed-language code snippets.


📸 Multi-Viewport Capture (16:9, 9:16, Mobile)

After modifying any layout, ink_capture_viewport captures:

  1. 16:9 Landscape (1600x900 / 1920x1080): Desktop container validation.

  2. 9:16 Tall Story (540x960 / 1080x1920): Vertical social and mobile story view.

  3. Standard Mobile (390x844): Responsive mobile layout check, ensuring zero horizontal scrollbar leaks.

📖 MCP Resources (resources/list)

  • ink://master/philosophy: The complete text of INK_MASTER.md constitution and tool execution pipeline.

  • ink://tokens/design-presets: Curated OKLCH presets (editorial, luxury-dark, cyber-tactile, neo-brutalist, organic-modern).

  • ink://security/owasp-frontend: Client-side OWASP security checklist and guidelines.


💬 MCP Prompts (prompts/list)

  • ink_creative_direction: Guided session to establish project aesthetics, color tokens, and layout before writing code.

  • ink_anti_slop_audit: Guided workflow to inspect any existing code, compute craft scores, and remediate slop.


🚀 Installation & Client Setup

1. Claude Desktop

Add to your claude_desktop_config.json:

{
  "mcpServers": {
    "ink-design": {
      "command": "npx",
      "args": ["-y", "mcp-ink-design"]
    }
  }
}

Or when developing locally:

{
  "mcpServers": {
    "ink-design": {
      "command": "node",
      "args": ["c:/Users/DKurdistan/Desktop/mcp-ink-design/dist/index.js"],
      "env": {
        "INK_PYTHON_PATH": "python"
      }
    }
  }
}

2. Antigravity IDE / Cursor / Windsurf

Add to your workspace .agents/mcp_config.json or global config:

{
  "mcpServers": {
    "ink-design": {
      "command": "node",
      "args": ["c:/Users/DKurdistan/Desktop/mcp-ink-design/dist/index.js"]
    }
  }
}

🐍 Python Verification Suite (python/ink_verifier)

The server includes a dedicated Python testing and verification engine that runs independently or via ink_run_python_tests:

# Run python unit tests
python -m unittest discover -s python/test

# Test contrast ratio directly via CLI
echo '{"foreground": "#ffffff", "background": "#0b0f19"}' | python -m python.ink_verifier.cli --action contrast --stdin
# Test security linter
echo '{"code": "element.innerHTML = userVal;"}' | python -m python.ink_verifier.cli --action security --stdin

🧪 Development & Quality Gates

# Typecheck
npm run typecheck

# Run Vitest test suite (unit, contract, integration)
npm test

# Build distribution bundle
npm run build

# Inspect package tarball
npm pack --dry-run

📜 License

MIT License — Created by MarwanDevMCP.

Available Tools

11 tools
ink_audit_securityAudit Frontend Code Security & HeadersA
Read-onlyIdempotent

PURPOSE: Audit frontend and full-stack web code for client-side security vulnerabilities (DOM XSS, eval/Function sinks, innerHTML execution, plain-text token storage in localStorage, missing security headers, and strict CSP generation).

BEHAVIOR: Executes AST and regex static security scanning in-memory. Purely read-only; never executes or mutates the audited code, and never transmits source code over external networks. Emits severity ratings (critical, high, medium, low) and exact code remediations.

USAGE GUIDELINES:

  • When to use: Use prior to deployment or code review to ensure zero client-side injection vulnerabilities, secure token handling, and robust Content-Security-Policy headers.

  • When NOT to use: Do NOT use to validate CSS aesthetic quality, color contrast, or fluid typography rules (use ink_validate_design instead), nor for external URL penetration testing.

  • Alternatives: Use ink_validate_design for design system, contrast, and bidi compliance checks; use ink_run_python_tests for Python AST test suites.

RETURNS: ResultEnvelope containing 'securityScore', pass/fail boolean, structured 'findings' array with line numbers and remediations, recommended 'recommendedCspHeader', and safe authentication storage patterns.

Inputs: code (required), filename. Returns: data, status, summary, evidence, +2 more

ink_build_threejs_experienceBuild 3D WebGL Canvas ExperienceA
Read-onlyIdempotent

PURPOSE: Generate high-performance, responsive 3D WebGL scenes using Three.js (particle constellations, geometric wireframes, morphing meshes, or interactive hero canvases) with memory-safe lifecycles.

BEHAVIOR: Generates client-side HTML container, full-bleed CSS, and JavaScript module code purely in-memory. Zero filesystem mutations. Incorporates GPU protections: automatically clamps window.devicePixelRatio to 2, attaches window resize listeners, pauses requestAnimationFrame on hidden browser tabs via the Page Visibility API, and exposes a clean teardown disposal function (geometries, materials, renderer.dispose()).

USAGE GUIDELINES:

  • When to use: Use when a page needs an interactive 3D hero background, ambient particle field, or futuristic geometric visual experience.

  • When NOT to use: Do NOT use for standard 2D UI widgets or layouts (use ink_craft_component instead), nor for basic CSS animations without WebGL.

  • Alternatives: Use ink_craft_component for 2D UI components; use ink_create_base for scaffolding the full application shell.

RETURNS: ResultEnvelope containing canvas mounting 'html', full-bleed responsive 'css', initialization and teardown 'js', and lifecycle documentation.

Inputs: sceneType, particleCount, accentColorHex, enableMouseParallax. Returns: data, status, summary, evidence, +2 more

ink_capture_viewportCapture Multi-Viewport Responsive SnapshotsA
Idempotent

PURPOSE: Capture 3 high-resolution viewport snapshots (16:9 Desktop Landscape 1920x1080, 9:16 Vertical Story 1080x1920, and Mobile View 390x844) via headless Chromium to verify layout integrity, responsiveness, and optical centering.

BEHAVIOR: Launches local headless Chromium with an isolated temporary user-data profile. Renders the provided HTML string or URL, waits for network idle, and writes 3 PNG image files to the target outputDirectory (defaults to '.ink_snapshots/'). Detects horizontal scrollbar leaks and viewport overflow. Requires local Chromium/Chrome installed.

USAGE GUIDELINES:

  • When to use: Call after making HTML/CSS modifications or finishing a component to visually confirm that elements align properly across desktop, mobile, and tall vertical screens.

  • When NOT to use: Do NOT use for fast code syntax or contrast checks without browser rendering (use ink_validate_design instead).

  • Alternatives: Use ink_validate_design for fast static design linting; use ink_inspect_website_style to reverse-engineer design tokens from live URLs.

RETURNS: ResultEnvelope containing structured 'snapshots' list (with label, viewport, exact dimensions, file path, and size) and layout overflow metrics.

Inputs: htmlOrUrl (required), title, outputDirectory. Returns: data, status, summary, evidence, +2 more

ink_craft_componentCraft UI Component with Tactile PhysicsA
Read-onlyIdempotent

PURPOSE: Synthesize bespoke, tactile UI components (hero sections, glass cards, tactile buttons, navigation bars, metrics grids, modal dialogs) with semantic HTML5, modern CSS logical properties, and spring micro-interaction physics.

BEHAVIOR: Generates component markup, stylesheets, and lifecycle JavaScript strings purely in-memory. Does not mutate the filesystem, write to disk, or initiate network connections. Enforces keyboard accessibility (ARIA dialog, roving tabindex, escape dismiss) and bidi RTL/LTR compliance.

USAGE GUIDELINES:

  • When to use: Use when creating individual, high-craft UI components and interactive widgets that need to be embedded in an existing layout.

  • When NOT to use: Do NOT use to scaffold an entire web application project (use ink_create_base instead), nor for 3D WebGL scenes (use ink_build_threejs_experience instead), nor for non-visual state stores (use ink_generate_script_logic instead).

  • Alternatives: Use ink_create_base for full application scaffolding; use ink_build_threejs_experience for 3D canvas experiences.

RETURNS: ResultEnvelope containing semantic 'html' markup, scoped 'css' rules using logical properties and OKLCH tokens, tactile 'js' interaction logic, and accessibility notes.

Inputs: title, direction, description, componentType, +1 more. Returns: data, status, summary, evidence, +2 more

ink_create_baseScaffold Web Application FoundationA
Read-onlyIdempotent

PURPOSE: Scaffold a complete, production-grade semantic web application foundation featuring OKLCH color token architecture, fluid typography scales, modern CSS logical properties, and bilingual Arabic RTL/LTR layout balance.

BEHAVIOR: Generates complete in-memory application files (index.html, styles.css, main.js) within the structured result envelope. Operates purely in-memory with zero direct filesystem side effects; callers receive the code ready to be written to disk. Requires no external credentials or elevated permissions.

USAGE GUIDELINES:

  • When to use: Call at the start of a web project to establish root HTML semantics, CSS custom property foundations, viewport meta tags, and font configurations.

  • When NOT to use: Do NOT use to craft isolated UI widgets (use ink_craft_component instead) or to synthesize standalone color variables without project markup (use ink_generate_palette_tokens instead).

  • Alternatives: Use ink_craft_component for individual components; use ink_generate_palette_tokens for standalone CSS color tokens.

RETURNS: ResultEnvelope containing structured 'files' dictionary (index.html, styles.css, main.js), OKLCH tokensOverview, contrast verification analysis, and typography scales.

Inputs: language, direction, arabicFont, designStyle, +3 more. Returns: data, status, summary, evidence, +2 more

ink_generate_palette_tokensGenerate OKLCH Color Palette & Design TokensA
Read-onlyIdempotent

PURPOSE: Generate bespoke OKLCH color token ramps, layered shadow elevations, and fluid clamp() typography scales tailored to a creative aesthetic mood and base hue.

BEHAVIOR: Synthesizes CSS custom property tokens and typography steps purely in-memory. Zero filesystem writes and zero external network access. Guarantees WCAG AAA contrast compliance across all text/surface pairings with mathematical delta-E verification.

USAGE GUIDELINES:

  • When to use: Use when creating or refining a design system's color foundation, fluid typographic scales, or dark/light mode surface tokens.

  • When NOT to use: Do NOT use to extract colors from an existing live website (use ink_inspect_website_style instead) or to scaffold an entire project skeleton (use ink_create_base instead).

  • Alternatives: Use ink_inspect_website_style to reverse-engineer design tokens from existing sites; use ink_create_base for full-page scaffolding.

RETURNS: ResultEnvelope containing semantic OKLCH token map, computed contrast analysis, fluid typography scales, and a ready-to-use CSS :root variable stylesheet string.

Inputs: mood, baseHue, includeTypography, includeArabicTokens. Returns: data, status, summary, evidence, +2 more

ink_generate_script_logicGenerate Modular Architecture LogicA
Read-onlyIdempotent

PURPOSE: Generate zero-dependency, memory-safe JavaScript and TypeScript architectural modules (State Store, Event Bus, Intersection Scroll Observer, Theme Switcher, Form Validator) with production error boundaries.

BEHAVIOR: Synthesizes modular ES6+ JavaScript and optional TypeScript declarations purely in-memory. Zero filesystem modifications. All generated code enforces memory cleanup paradigms (explicit unsubscribe functions, WeakMap caching, EventTarget/listener teardown).

USAGE GUIDELINES:

  • When to use: Use when creating application state management, event-driven decoupled messaging, viewport scroll animators, theme togglers, or accessible form validation.

  • When NOT to use: Do NOT use to render UI elements or write component styling (use ink_craft_component instead) or WebGL graphics (use ink_build_threejs_experience instead).

  • Alternatives: Use ink_craft_component for visual UI components; use ink_build_threejs_experience for 3D canvas rendering.

RETURNS: ResultEnvelope containing zero-dependency ES module 'code', optional 'typescriptTypes', architectural pattern documentation, and executable 'usageExample'.

Inputs: pattern, moduleName, typescript. Returns: data, status, summary, evidence, +2 more

ink_import_custom_assetsImport & Configure Web Fonts and AssetsA
Read-onlyIdempotent

PURPOSE: Dynamically configure and generate Google Fonts preconnect tags, CSS @import rules, optical line-height variables, and accessible font fallbacks for multilingual Arabic and Latin projects.

BEHAVIOR: Generates HTML link tags, CSS @import rules, and stylesheet font-family declarations purely in-memory. Does not download font binaries or write files to disk directly. Formulates tailored optical line-height variables (1.7-1.85 for Arabic, 1.5-1.6 for Latin) to eliminate clipping.

USAGE GUIDELINES:

  • When to use: Call when setting up web fonts, adding Arabic typographic scales, or loading bespoke font families into a project.

  • When NOT to use: Do NOT use to synthesize fluid clamp font-size scales (use ink_generate_palette_tokens instead) or to scaffold an entire project (use ink_create_base instead).

  • Alternatives: Use ink_generate_palette_tokens for fluid typography size scales; use ink_create_base for full HTML document scaffolding.

RETURNS: ResultEnvelope containing 'htmlLinkTags', 'cssImportRule', 'cssVariables' with font-family definitions, and an accessible 'fallbackStack'.

Inputs: weights, displayFont, primaryFont, includeArabic. Returns: data, status, summary, evidence, +2 more

ink_inspect_website_styleInspect & Reverse-Engineer Website StyleA
Read-onlyIdempotent

PURPOSE: Deconstruct existing live websites or HTML/CSS templates to reverse-engineer color palettes, typography scales, elevation shadows, and layout DNA into modern OKLCH tokens.

BEHAVIOR: Fetches public website markup over HTTPS or parses local HTML/CSS code strings in-memory. Strictly read-only with zero disk modifications. Remote network requests enforce a 10s timeout, safe redirect limits, and private subnet IP blocking. Converts extracted HEX/RGB values into perceptual OKLCH color variables.

USAGE GUIDELINES:

  • When to use: Use when analyzing a reference website or mockup to extract its visual hierarchy, typography system, and color ramps.

  • When NOT to use: Do NOT use to generate novel color tokens from scratch (use ink_generate_palette_tokens instead) or to evaluate code for anti-slop compliance (use ink_validate_design instead).

  • Alternatives: Use ink_generate_palette_tokens to synthesize new design tokens; use ink_capture_viewport to capture visual screenshots.

RETURNS: ResultEnvelope containing detected 'archetype', extracted 'colors' (with HEX and OKLCH conversions), 'typography' hierarchy, 'shadows', 'layoutDna', and an actionable recommended OKLCH palette stylesheet.

Inputs: urlOrCode (required), extractOklchPalette. Returns: data, status, summary, evidence, +2 more

ink_run_python_testsRun Python AST & Contrast Verification SuiteA
Read-onlyIdempotent

PURPOSE: Execute the external Python verification suite for deep AST static analysis, mathematical contrast matrix calculation, and headless layout audits.

BEHAVIOR: Spawns the local Python 3 ink_verifier engine in a sandboxed subprocess. Purely read-only; does not mutate source files or modify disk state unless 'capture' is specifically invoked. Requires Python 3.10+ installed in the environment PATH. Returns comprehensive structured test metrics.

USAGE GUIDELINES:

  • When to use: Use when running deep multi-pass Python AST analysis, mathematical APCA/WCAG contrast calculation, or comprehensive verification across an entire codebase.

  • When NOT to use: Do NOT use for fast in-memory CSS validation without Python (use ink_validate_design instead) or for standalone client-side security audits (use ink_audit_security instead).

  • Alternatives: Use ink_validate_design for fast TypeScript-native design verification; use ink_audit_security for native security scanning.

RETURNS: ResultEnvelope containing structured test outcomes from the Python verifier engine according to the invoked action ('contrast', 'security', 'visual', 'audit', 'full', 'bidi', 'inspect', or 'capture').

Inputs: code, action, target, backgroundHex, +1 more. Returns: data, status, summary, evidence, +2 more

ink_validate_designValidate Design Craft & Contrast ComplianceA
Read-onlyIdempotent

PURPOSE: Evaluate HTML and CSS code against anti-AI-slop design heuristics (detecting generic AI purple gradients, hardcoded pixel font sizes, missing semantic tags), verify WCAG AAA color contrast ratios, and audit Arabic RTL/LTR logical properties.

BEHAVIOR: Executes in-memory static AST and regex analysis on the supplied code strings. Completely read-only with zero filesystem writes, no network requests, and deterministic score computation. Emits a letter grade (S, A, B, C, F), numerical score (0-100), and specific remediation diff advice.

USAGE GUIDELINES:

  • When to use: Call after creating or modifying web layouts, components, or stylesheets to verify craft quality, contrast compliance, and bidi readiness before committing.

  • When NOT to use: Do NOT use for JavaScript security vulnerability scanning (use ink_audit_security instead) or for capturing real-browser screenshots (use ink_capture_viewport instead).

  • Alternatives: Use ink_audit_security for security/XSS checks; use ink_capture_viewport for visual multi-viewport screenshot verification.

RETURNS: ResultEnvelope containing 'craftScore', 'craftGrade', 'isHighCraft' boolean, 'antiSlopChecks' results, computed 'contrast' analysis, 'bidiAndAlignment' report, and prioritized 'remediationAdvice'.

Inputs: code (required), checkBidi, backgroundHex, foregroundHex, +1 more. Returns: data, status, summary, evidence, +2 more

Tool Schema Changelog

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

Loading tool schema changelog…

    TDQS

    A4.3/5.0

    Scored across 11 tools

    Disambiguation3/5

    Most tools have clearly distinct resources (project, component, palette, fonts, security, design validation), and the usage guidance reinforces those boundaries. However, ink_run_python_tests can be invoked with actions like 'contrast', 'security', 'inspect', and 'capture', which overlaps with ink_validate_design, ink_audit_security, ink_inspect_website_style, and ink_capture_viewport.

    Naming Consistency5/5

    All tools follow the same ink_ + verb + object snake_case convention, such as create_base, generate_palette_tokens, craft_component, and capture_viewport. The naming pattern is highly predictable and reinforces the purpose of each tool.

    Tool Count5/5

    11 tools is a well-scoped size for a design and verification toolkit, covering generation, component crafting, 3D, script logic, fonts, inspection, validation, security, and capture. Each tool maps to a meaningful stage in the design workflow without feeling bloated.

    Completeness5/5

    The toolset covers the full design lifecycle: scaffolding, palette token generation, font setup, component creation, 3D experiences, script logic, style inspection, design validation, security auditing, deep verification, and viewport capture. There are no obvious missing core operations for the stated semantic web design purpose.

    Maintenance

    ActivitySlowing
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      B
      quality
      D
      maintenance
      Enables comprehensive UI/UX development workflows through integrated tools for component development with Storybook, Tailwind CSS styling, Framer Motion/GSAP animations, Playwright testing, and automated design system generation. Provides end-to-end automation for visual regression testing, accessibility compliance, and UX optimization analysis.
      12
      2
      MIT
    • A
      license
      Not graded
      quality
      C
      maintenance
      Converts any rendered web page into a complete, LLM-readable design specification—including block screenshots, distilled computed CSS, design tokens, responsive deltas, and alpha-channel-analyzed assets—so models can accurately reproduce the design.
      MIT
    • A
      license
      A
      quality
      C
      maintenance
      Enables AI assistants to architect and build Awwwards-level websites with spring physics, design systems, React 19 templates, and HD visual inspection.
      10
      MIT
    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables AI coding assistants to generate bespoke design systems by synthesizing OKLCH color palettes, chamfer highlights and spring physics, teaching layout composition grammar, and returning micro-interaction primitives and component blueprints. Also audits JSX/TSX/HTML through a senior design director's lens to score and critique UI quality.
      1
      MIT