baoyu-format-markdown
Formats plain text or markdown files with frontmatter, titles, summaries, headings, bold, lists, and code blocks. Use when user asks to "format markdown", "beautify article", "add formatting", or improve article layout. Outputs to {filename}-formatted.md.
Author
Category
Document ProcessingInstall
Hot:3
Download and extract to your skills directory
Copy command and send to OpenClaw for auto-install:
Download and install this skill https://openskills.cc/api/download?slug=jimliu-skills-baoyu-format-markdown&locale=en&source=copy
Skill Overview
Automatically convert plain text or Markdown files into structured documents by adding frontmatter, optimizing heading levels, and fixing spacing between Chinese and English, making the article formatting more规范 and visually appealing.
Use Cases
Automatically generate the YAML frontmatter required by the blog, including title, summary, slug, and cover image path. With one click, export a Markdown file that conforms to static blog standards such as Hugo and Jekyll.
Convert scattered plain-text notes into structured Markdown. Automatically detect parallel content to turn it into lists, extract code blocks, and optimize heading levels—making technical documents easier to read.
Automatically fix spacing between Chinese, English, and numbers; standardize the use of full-width quotation marks; normalize CJK emphasis symbols to match Chinese typography conventions.
Core Features
Automatically detect or generate the article title and create YAML frontmatter including title, slug, summary, and featureImage. Supports inferring the slug from the file path, intelligently generates an engaging 100–150 character summary, and automatically detects cover images in the same directory.
Automatically analyze the article content. Convert parallel items into unordered or ordered lists, identify commands and code and add code block markers, extract key statements for bold emphasis, and use blockquote markers for quotes or important notes.
Integrate tools such as remark-cjk-friendly and autocorrect to automatically fix CJK emphasis punctuation issues, add spacing between Chinese and English and between Chinese and numbers. Optionally replace ASCII quotation marks with full-width quotation marks.
FAQ
Will baoyu-format-markdown change my original content?
The skill follows the principle of “only add formatting, do not modify content.” The original text and viewpoints are fully preserved. The processing is limited to adding Markdown formatting markers (e.g., bold, lists, code blocks) and performing typography fixes (e.g., spacing between Chinese and English). If the file is already in Markdown format, you will be asked to choose between “Optimize formatting,” “Keep original format and only fix typography,” or “Only typography processing.”
How can I customize formatting options?
Configure preferences via the EXTEND.md file. First check the project-level
.baoyu-skills/baoyu-format-markdown/EXTEND.md, then check the user-level $HOME/.baoyu-skills/baoyu-format-markdown/EXTEND.md. Supports configuring default formatting options and summary-length preferences. When running the script, command-line arguments can also control whether to enable quotation replacement, spacing adjustments, and emphasis symbol fixes.Will the processed file overwrite the original file?
No. The processed content is saved as a new file named
{original filename}-formatted.md, leaving the original unchanged. If the target file already exists, it will be automatically backed up as {filename}-backup-{timestamp}.md. Only when you choose the “Only typography processing” option will the script modify the original file directly.