String

io.github.rog0x由 GitHub 帳號 rog0x 發布v1.0.2更新於 Oct 27, 2026

String analyzer, diff, templates for AI agents

已驗證STDIO僅桌面開發者工具資料與分析

概覽

AI 產生的概覽

本機 MCP 伺服器,為助理提供文字分析、轉換、差異比對、範本渲染與 slug 產生等字串工具。

可以做什麼
  • 分析文字:統計字元、詞、句子與段落數量,估算閱讀時間、Flesch-Kincaid 可讀性等級、不重複詞與高頻詞、最長單字
  • 轉換文字:移除重複行、合併多餘空白、擷取電子郵件、網址與電話號碼、遮蔽敏感資料、依詞邊界截斷、依欄寬換行
  • 比對兩個字串,支援字元、詞、行三種差異模式,顯示新增、刪除與未變更片段
  • 渲染範本:變數替換、條件判斷、迴圈與巢狀屬性存取
  • 產生網址友善的 slug,支援音標轉寫、自訂分隔符、最大長度與可選小寫
適用情境
適合助理需要在本機量測、清理、比對或重排文字的情況,例如檢查可讀性、移除重複行、在分享前遮蔽電子郵件與卡號、比對兩段字串差異,或為網址產生 slug。
執行需求
以本機 stdio 程序在桌面端執行;需安裝 npm 套件並建置,再以 node 指向建置後的進入點檔案。未宣告帳號、API 金鑰或環境變數。
安裝前請注意
遮蔽僅是文字轉換;擷取出的電子郵件、網址與電話號碼會回傳給助理,分享前請檢查輸出。未宣告寫入、網路或憑證存取。

安裝

在 SourceWeft 中

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

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

其他 MCP 客戶端

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

README

@rog0x/mcp-string-tools

Advanced string manipulation tools for AI agents, served over the Model Context Protocol (MCP).

Tools

analyze_string

Analyze text to get detailed metrics:

  • Character count (with and without spaces)
  • Word, sentence, and paragraph counts
  • Estimated reading time
  • Flesch-Kincaid reading level score and grade
  • Unique word count and most common words
  • Longest word

transform_string

Transform text with various operations:

  • remove_duplicate_lines - Remove duplicate lines from text
  • remove_extra_whitespace - Collapse extra whitespace and blank lines
  • extract_emails - Extract all email addresses from text
  • extract_urls - Extract all URLs from text
  • extract_phone_numbers - Extract phone numbers from text
  • mask_sensitive_data - Mask emails, phone numbers, and credit card numbers
  • truncate - Truncate text with ellipsis at word boundaries
  • wrap_text - Wrap text at a specified column width

diff_strings

Compare two strings and see the differences:

  • character mode - Character-by-character diff
  • word mode - Word-by-word diff (default)
  • line mode - Line-by-line diff
  • Shows additions, deletions, and unchanged segments with positions

render_template

Simple template engine:

  • Replace {{variables}} with values from a JSON data object
  • Conditionals: {{#if var}}...{{#else}}...{{/if}}
  • Loops: {{#each arr}}...{{this}}...{{@index}}...{{/each}}
  • Nested property access: {{user.name}}

generate_slug

Generate URL-friendly slugs:

  • Transliterates accented characters (e.g., cafe from cafe)
  • Removes special characters
  • Configurable separator (default: -)
  • Optional max length with clean truncation
  • Optional lowercase toggle

Setup

bash
npm installnpm run build

Usage with Claude Desktop

Add to your claude_desktop_config.json:

json
{  "mcpServers": {    "string-tools": {      "command": "node",      "args": ["D:/products/mcp-servers/mcp-string-tools/dist/index.js"]    }  }}

License

MIT

來源:README.md,提交 29a699e

工具

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

版本歷史

1
  1. v1.0.2最新Sep 16, 2026

評分

已滿足適用檢查項的 40%

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

  • 近 30 天內可連通25 分

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

  • 已宣告認證方式10 分

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

  • 已列出工具15 分

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

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

    請在儲存庫或註冊中心條目中宣告授權條款。