Clean Text Formatter
/install clean-text-formatter
Clean Text Formatter
Name
clean-text-formatter
Description
Removes Markdown formatting characters and excessive whitespace from AI-generated text. Produces clean, publication-ready plain text.
Capabilities
1. Markdown Stripping
Strips the following while preserving content:
- Headers:
#,##,###(removes markers, keeps text) - Bold/italic markers:
**,__,*,_(removes markers, keeps text) - Links:
[text](url)→ keepstext - Images:
→ keepsalt - Blockquotes:
>lines (removed) - Code blocks: backticks removed, code content preserved
- List markers:
-,*,1.(removed, list content preserved) - Horizontal rules:
---,***(removed) - Footnotes:
[^1](removed)
2. Whitespace Cleaning Around Numbers
Fixes common AI spacing issues:
100 %→100%¥ 100→¥100USD 50→USD 50(currency symbols kept with numbers)- Numbers with leading/trailing spaces trimmed
- Thousand separators
,preserved:1,000,000
3. Punctuation Spacing
- Removes spaces before punctuation:
,。!? - Removes spaces inside parentheses:
( 文本 )→(文本) - Normalizes multiple spaces to single space
- Trim leading/trailing whitespace from each line
4. Unicode Normalization
- Normalizes quotes:
"text"→"text",'text'→'text' - Normalizes dashes:
—–→-
Triggers
- User pastes text and asks to "clean" or "remove Markdown"
- User shares AI-generated content and asks to "format for publication"
- Any content containing visible Markdown syntax
Workflow
- Receive raw text input (paste, file upload, or document content)
- Detect content type and Markdown density
- Apply cleaning rules in order: a. Structural (headers, lists, blockquotes) b. Inline formatting (links, images, emphasis) c. Whitespace normalization d. Punctuation spacing fix
- Return clean text + optional export
Input
- Plain text paste
.txt,.md,.docx,.htmlfiles- Direct document content
Output
- Clean plain text (ready to copy/paste)
- Optional:
.txtfile export
Limitations
- Does not preserve Markdown intended for re-use (strips permanently)
- Complex nested formatting may require manual review
- LaTeX math expressions:
$$...$$and$...$are preserved
Dependencies
- Python 3.8+ (for regex processing)
- No external packages required
- Make sure OpenClaw is installed (local or Docker)
- Run the install command in chat:
/install clean-text-formatter - After installation, invoke the skill by name or use
/clean-text-formatter - Provide required inputs per the skill's parameter spec and get structured output
What is Clean Text Formatter?
Removes Markdown formatting and excess whitespace from text to produce clean, publication-ready plain text with normalized punctuation and spacing. It is an AI Agent Skill for Claude Code / OpenClaw, with 131 downloads so far.
How do I install Clean Text Formatter?
Run "/install clean-text-formatter" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.
Is Clean Text Formatter free?
Yes, Clean Text Formatter is completely free, licensed under MIT-0. You can download, install and use it at no cost.
Which platforms does Clean Text Formatter support?
Clean Text Formatter is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).
Who created Clean Text Formatter?
It is built and maintained by zihaowyt5525-max (@zihaowyt5525-max); the current version is v1.0.0.