ShapeWords MCP

io.github.kirrrr-2423由 GitHub 帳號 kirrrr-2423 發布v0.2.2更新於 Oct 24, 2026

Generate ShapeWords word clouds as SVG, PNG, or JSON from text or weighted words.

已驗證STDIO僅桌面開發者工具媒體與設計

概覽

AI 產生的概覽

ShapeWords MCP 讓助理依文字或加權詞彙產生 SVG、PNG 或 JSON 文字雲,可使用託管的 ShapeWords 服務,也可在本機以 Skia 引擎算繪。

可以做什麼
一次呼叫即可從原始文字或明確的加權詞彙產生文字雲,回傳成品連結、工作中介資料,以及可選的圖片內容。以非同步方式建立算繪工作,之後依工作 ID 查詢狀態。選擇輸出格式(SVG、PNG 或 JSON 版面資料)、畫布尺寸、背景、品質、調色盤、配色方式、字型與字級。從內建形狀、品牌形狀或自訂 SVG 路徑中挑選遮罩形狀,並控制旋轉、螺旋、填滿方式,以及可重現結果的版面種子。使用 Skia 引擎在本機算繪,而不走託管服務。
適用情境
適合讓助理把筆記、提示詞、研究片段或關鍵詞清單直接變成可分享的文字雲圖片或版面資料,不必離開對話。既適合單次出圖,也適合輪詢工作完成的非同步批次流程。
執行需求
以本機 stdio 程序執行,通常透過 npx 或複製的 Node.js 專案啟動。預設經由網路呼叫託管的 ShapeWords Render API,可用 SHAPEWORDS_API_BASE_URL 指向其他位址。只有受保護的部署才需要選用的 SHAPEWORDS_RENDER_API_KEY(或別名 SHAPEWORDS_API_KEY)。逾時可透過 SHAPEWORDS_POLL_TIMEOUT_MS 與 SHAPEWORDS_REQUEST_TIMEOUT_MS 設定。
安裝前請注意
送出的文字與加權詞彙預設會傳到託管的 ShapeWords 服務,除非改用本機 Skia 引擎,否則不要送出機密內容。託管成品連結因工作暫存於記憶體而有效期限很短。選用的 API 金鑰屬於機密,透過環境變數傳入。此伺服器只提供算繪選項,不含完整的 ShapeWords 編輯器或檔案匯入功能。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 ShapeWords MCP,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

ShapeWords MCP

Universal MCP server for generating word clouds with ShapeWords.

It exposes ShapeWords rendering tools through the Model Context Protocol, so any MCP-capable client can create SVG, JSON, or PNG word clouds from text, workshop notes, prompts, research snippets, or agent output. By default it uses the hosted ShapeWords Render API; with engine: "skia" it renders locally inside the MCP server with the shared layout core and CanvasKit/Skia.

Tools

All tools use stdio MCP transport.

render_word_cloud

Creates a ShapeWords render job, polls until it is finished, and returns:

  • public artifact URL for hosted renders, or a local inline artifact for engine: "skia";
  • job metadata;
  • optional image content for MCP clients that support image results.

Use this tool for one-shot generation when the caller wants the final artifact.

create_word_cloud_job

Starts a render job and returns the job/status/artifact URLs without waiting.

Use this tool for asynchronous workflows where the client will poll later.

get_word_cloud_job

Checks a render job by ID.

Use this tool with the jobId returned by create_word_cloud_job or render_word_cloud.

Input Schema

render_word_cloud accepts all render options below. create_word_cloud_job accepts the hosted options only: engine: "skia" is local-only and is supported by render_word_cloud.

FieldTypeDefaultLimitsDescription
renderProfileenumcanvascanvas, apiDefault option profile. canvas matches the main ShapeWords canvas; api keeps the older compact Render API defaults.
textstringoptional1-100,000 charsSource text for the word cloud. Required unless words is provided.
wordsobject[]optional1-1000 itemsExplicit weighted words. Use when the caller already tokenized, lemmatized, or scored text.
localeenumenen, ru, ar, es, fr, zhRender/UI locale passed to ShapeWords.
formatenumsvgsvg, png, jsonArtifact format. SVG is the fastest default. JSON returns layout data. PNG is rasterized from the same shared layout.
widthinteger800240-4096Canvas width in pixels.
heightinteger600240-4096Canvas height in pixels.
backgroundenumwhitetransparent, white, darkOutput background.
qualityenumhqsq, hqStandard or high-quality render. hq matches the main canvas export scale and is slower.
engineenumautoauto, browser, browserless, skiaRenderer engine. skia uses the local MCP shared-core + CanvasKit renderer without server-side Chromium.
returnLayoutbooleanfalsetrue/falseInclude layout metadata when supported.
shapeTypestringcloud1-80 charsShape id. Use a built-in id or custom with customShapeDefinition.
customShapeDefinitionobjectomittedsee belowCustom SVG path shape. Required when shapeType is custom.
maxWordsinteger7001-1000Maximum number of words to place.
seedinteger00-4294967295Unsigned 32-bit layout seed for reproducible browserless renders. Same input, options, and seed produce the same SVG/layout.
fontFamilystringMontserrat1-80 charsShapeWords font family name, for example Inter, Roboto, Montserrat, Noto Sans.
minFontSizeinteger184-400Minimum word font size.
maxFontSizeinteger968-700Maximum word font size.
paddinginteger30-100Pixel padding used by collision detection.
rotationPresetenumorthogonalsee belowRotation preset matching the main ShapeWords canvas.
rotationsinteger[]omitted-90 to 90, max 64 valuesExplicit rotation angles. When provided, these override rotationPreset.
spiralTypeenumarchimedeanarchimedean, rectangularPlacement spiral algorithm.
fillModeenumfillfill, frequencyShape filling strategy.
palettestring[]service defaultup to 12 colorsHex colors: #rgb, #rrggbb, or #rrggbbaa.
colorModeenumservice defaultsequential, random, byFrequencyHow palette colors are assigned to words.
returnImagebooleanfalserender_word_cloud onlyDownload the finished SVG/PNG artifact and return it as MCP image content.
pollIntervalMsintegerenv/default250-10,000Polling interval for render_word_cloud.
pollTimeoutMsintegerenv/default1,000-180,000Maximum wait time for render_word_cloud.

get_word_cloud_job accepts:

FieldTypeLimitsDescription
jobIdstring6-64 charsShapeWords render job id.

words items use this shape:

FieldTypeDefaultLimitsDescription
textstringrequired1-120 charsDisplay word or emoji.
valueinteger11-100,000Weight/frequency used for sizing.
kindenumwordword, emojiWord type. Emoji are kept horizontal by the renderer.
sizeScalenumberomitted0.1-5Optional extra size multiplier used by the ShapeWords layout core when available.
repeatbooleantruetrue/falseWhether the layout may repeat this word to improve shape filling.

Rotation presets:

text
horizontal, vertical, orthogonal, crossing, crossingVoids, dancing,positiveSlope, negativeSlope, random, custom, mixed, angled, free

renderProfile: "canvas" sends the same practical defaults as the main editor canvas: shapeType: "cloud", width: 800, height: 600, quality: "hq", maxWords: 700, seed: 0, fontFamily: "Montserrat", minFontSize: 18, maxFontSize: 96, padding: 3, rotationPreset: "orthogonal", spiralType: "archimedean", and fillMode: "fill".

Use renderProfile: "api" only when you need the older compact Render API defaults: circle shape, 1024x640, SQ quality, and 120 max words.

Text Input

The MCP server can send either raw text, explicit words, or both:

  • repeated words increase frequency, for example cloud cloud cloud render render API;
  • words[] preserves caller-provided weights and avoids differences in tokenization, stop words, or lemmatization;
  • when both text and words[] are present, ShapeWords renders from words[] and keeps text as source context;
  • paragraphs, meeting notes, workshop notes, prompts, research snippets, and keyword lists are valid;
  • files such as CSV, Excel, or Google Sheets are not uploaded through this MCP server; paste or generate the text content first.

Example weighted text:

json
{  "text": "MCP MCP MCP ShapeWords ShapeWords word cloud word cloud render API agents tools",  "shapeType": "cloud",  "format": "svg",  "seed": 12345}

Example explicit weighted words:

json
{  "words": [    { "text": "ShapeWords", "value": 12 },    { "text": "MCP", "value": 9 },    { "text": "canvas", "value": 7 },    { "text": "layout", "value": 6 },    { "text": "render", "value": 5 }  ],  "shapeType": "cloud",  "format": "svg"}

Shapes

Use shapeType to choose the word-cloud mask.

Stable built-in shape ids accepted by the production renderer include:

text
rectangle, circle, heart, star, cloud, diamond, tree, triangle, arrow,square, pentagon, hexagon, octagon, cross, plus, moon, sun, drop,flame, leaf, flower, mountain, apple, house, book, camera, music,chat, location, trophy, rocket, plane, car, shield, lightning, check,infinity, tag

Built-in brand shape ids include:

text
brand-product-hunt, brand-y-combinator, brand-hacker-news,brand-indie-hackers, brand-github, brand-figma, brand-notion,brand-stripe, brand-vercel, brand-linear, brand-supabase,brand-railway, brand-netlify, brand-firebase, brand-cloudflare,brand-airtable, brand-replit, brand-anthropic

The production renderer may also accept additional generated ShapeWords ids. For portable automation, prefer the stable ids above or pass a custom SVG shape.

The local engine: "skia" path currently supports rectangle, square, circle, diamond, triangle, star, heart, cloud, custom SVG shapes, and vendored Font Awesome shape ids such as fa-cat. Unsupported local shape ids are rejected instead of silently changing the requested shape.

Custom Shapes

Set shapeType to custom and provide customShapeDefinition:

FieldTypeRequiredLimitsDescription
pathstringyes1-100,000 charsSVG path data used as the mask.
viewBoxstringyes1-120 charsSVG viewBox, for example 0 0 100 100.
fillRuleenumnononzero, evenoddSVG fill rule. Defaults to renderer behavior when omitted.
namestringno1-80 charsOptional human-readable name.
nameEnstringno1-80 charsOptional English name.

Custom heart example:

json
{  "text": "love love design care product community team support",  "shapeType": "custom",  "customShapeDefinition": {    "name": "Heart",    "path": "M 50 90 C 25 70, 0 50, 0 30 A 25 25 0 0 1 50 30 A 25 25 0 0 1 100 30 C 100 50, 75 70, 50 90 Z",    "viewBox": "0 0 100 100",    "fillRule": "nonzero"  },  "format": "svg"}

Output

render_word_cloud returns:

  • text content with the completed job id and artifact location;
  • structuredContent.job with normalized job metadata;
  • structuredContent.artifactUrl for hosted renders;
  • structuredContent.localArtifact for engine: "skia";
  • structuredContent.siteUrl;
  • optional MCP image content when returnImage is true and format is svg or png.

For engine: "skia", render_word_cloud always returns inline MCP image content for format: "png" or format: "svg" because there is no hosted artifact URL.

create_word_cloud_job returns the same metadata immediately after job creation, without waiting for completion.

get_word_cloud_job returns the latest job status and artifact URL.

Generated artifact URLs are short-lived because the ShapeWords Render API stores render jobs in memory.

Format and Engine Notes

  • svg is the recommended automation format: it is fast, compact, and works with the browserless shared-core renderer.
  • json returns layout data from the same shared-core placement.
  • png is rasterized from the same generated SVG/layout, so word placement matches SVG/JSON for the same input and options.
  • engine: "auto" is recommended unless you need to force a specific path.
  • engine: "browserless" supports svg, json, and png.
  • engine: "browser" supports svg and png, not json.
  • engine: "skia" is local-only and supported by render_word_cloud. It does not create pollable hosted jobs. Layout is generated by the vendored ShapeWords shared core; PNG is drawn directly with CanvasKit/Skia.
  • seed is honored by browserless/shared-core renders. Use engine: "auto" or engine: "browserless" for reproducible API/MCP output.
  • Non-zero seed with forced engine: "browser" is rejected by the Render API because the browser fallback does not use the deterministic shared-core seed path.

Quick Start

Run directly from GitHub:

bash
npx -y github:kirrrr-2423/shapewords-mcp

Or clone locally:

bash
git clone https://github.com/kirrrr-2423/shapewords-mcp.gitcd shapewords-mcpnpm installnpm start

Client Configuration

Use stdio transport in any MCP-compatible client.

json
{  "mcpServers": {    "shapewords": {      "command": "npx",      "args": ["-y", "github:kirrrr-2423/shapewords-mcp"],      "env": {        "SHAPEWORDS_API_BASE_URL": "https://shapewords.fun"      }    }  }}

For a local clone:

json
{  "mcpServers": {    "shapewords": {      "command": "node",      "args": ["/absolute/path/to/shapewords-mcp/src/index.js"],      "env": {        "SHAPEWORDS_API_BASE_URL": "https://shapewords.fun"      }    }  }}

Environment

VariableDefaultDescription
SHAPEWORDS_API_BASE_URLhttps://shapewords.funShapeWords app URL.
SHAPEWORDS_RENDER_API_KEYemptyOptional bearer token if your Render API requires one.
SHAPEWORDS_API_KEYemptyBackward-compatible alias for SHAPEWORDS_RENDER_API_KEY.
SHAPEWORDS_POLL_INTERVAL_MS1500Polling interval for completed renders.
SHAPEWORDS_POLL_TIMEOUT_MS90000Render wait timeout.
SHAPEWORDS_REQUEST_TIMEOUT_MS30000Per-request timeout for hosted API and artifact requests.
SHAPEWORDS_MAX_IMAGE_BYTES8388608Max downloaded artifact size when returnImage is true.

Example Prompt

text
Create a fast SVG word cloud about MCP, universal tools, word cloud generation, AI agents, and ShapeWords. Use the default ShapeWords canvas profile and return the artifact URL.

Example tool input:

json
{  "text": "MCP MCP MCP Model Context Protocol word cloud word cloud ShapeWords tools resources prompts stdio server client universal integration connector API render PNG SVG artifact agents automation context protocol schema",  "locale": "en",  "format": "svg",  "width": 800,  "height": 600,  "background": "white",  "quality": "hq",  "engine": "auto",  "returnLayout": false,  "shapeType": "cloud",  "seed": 12345,  "palette": ["#7c3aed", "#ddd6fe", "#14b8a6", "#111827"],  "returnImage": false}

More Examples

Transparent PNG

json
{  "text": "launch launch startup product customers retention growth metrics roadmap",  "format": "png",  "engine": "auto",  "shapeType": "rocket",  "width": 1200,  "height": 900,  "background": "transparent",  "quality": "hq",  "returnImage": true}

Local Skia PNG

json
{  "words": [    { "text": "MCP", "value": 12 },    { "text": "ShapeWords", "value": 10 },    { "text": "Skia", "value": 8 },    { "text": "CanvasKit", "value": 7 },    { "text": "local", "value": 6 },    { "text": "renderer", "value": 5 }  ],  "format": "png",  "engine": "skia",  "shapeType": "cloud",  "width": 800,  "height": 600,  "quality": "sq",  "seed": 12345}

JSON Layout

json
{  "text": "design system tokens components variants accessibility contrast typography layout",  "format": "json",  "engine": "browserless",  "shapeType": "diamond",  "returnLayout": true,  "seed": 7,  "maxWords": 80}

Reproducible SVG

json
{  "text": "MCP shared core browserless renderer reproducible seed deterministic layout",  "format": "svg",  "engine": "browserless",  "shapeType": "cloud",  "returnLayout": true,  "seed": 12345}

Custom Palette and Font

json
{  "text": "research synthesis interview persona journey insight opportunity experiment",  "format": "svg",  "shapeType": "book",  "fontFamily": "Roboto",  "palette": ["#111827", "#2563eb", "#14b8a6", "#f59e0b"],  "colorMode": "byFrequency",  "maxWords": 160}

Development

bash
npm installnpm run smokenpm run smoke:skianpm run inspect

The server uses stdio and writes protocol messages to stdout. Diagnostics are written to stderr.

Notes

  • Set returnImage: true in render_word_cloud when the MCP client supports image content and needs hosted-render bytes inline. Local Skia image renders are inline automatically.
  • For automation-heavy use, prefer SVG or JSON layout artifacts; request PNG only when the caller needs raster pixels.
  • Set seed when the caller needs repeatable SVG/JSON/PNG placement across MCP runs. engine: "skia" is deterministic by default.
  • Local Skia PNG output is capped at 40,000,000 pixels after quality scaling to avoid excessive local memory use.
  • Local Skia font rendering currently supports bundled Montserrat and OpenDyslexic only. Hosted renders may support more font families.
  • The MCP schema currently exposes rendering and style options only. It does not expose ShapeWords UI-only workflows such as the advanced word editor, 2D/3D view switching, CSV/Excel upload, Google Sheets import, or live room controls.
  • padding, rotationPreset, rotations, spiralType, and fillMode are exposed so MCP callers can match the main ShapeWords canvas more closely.

See THIRD_PARTY_NOTICES.txt for bundled Font Awesome and font asset notices.

來源:README.md,提交 93b207b

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

1
  1. v0.2.2最新Sep 16, 2026

評分

已滿足適用檢查項的 50%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分