baoyu-format-markdown
Formats plain text or markdown files with frontmatter, titles, summaries, headings, bold, lists, and code blocks.
Skill by JimLiu
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/jimliu-baoyu-format-markdown
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: documents, writing
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
- Runs as
- Node.js package
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/baoyu-format-markdown
What's inside
- Skill name
baoyu-format-markdown- Description
- 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.
- License
- MIT
- Instructions
- 344 lines in SKILL.md · view on GitHub
Before installing
- Ships executable scripts
- Instructions read files in your home folder (~/.ssh, ~/.aws…)
Files (8)
- SKILL.md
- title-formulas.md · references/
- autocorrect.ts · scripts/
- bun.lock · scripts/
- main.ts · scripts/
- package-lock.json · scripts/
- package.json · scripts/
- quotes.ts · scripts/
SKILL.md (first lines)
# Markdown Formatter
Transforms plain text or markdown into well-structured, reader-friendly markdown. The goal is to help readers quickly grasp key points, highlights, and structure — without changing any original content.
**Core principle**: Only adjust formatting and fix obvious typos. Never add, delete, or rewrite content.
## User Input Tools
When this skill prompts the user, follow this tool-selection rule (priority order):
1. **Prefer built-in user-input tools** exposed by the current agent runtime — e.g., `AskUserQuestion`, `request_user_input`, `clarify`, `ask_user`, or any equivalent.
2. **Fallback**: if no such tool exists, emit a numbered plain-text message and ask the user to reply with the chosen number/answer for each question.
3. **Batching**: if the tool supports multiple questions per call, combine all applicable questions into a single call; if only single-question, ask them one at a time in priority order.
Concrete `AskUserQuestion` references below are examples — substitute the local equivalent in other runtimes.
## Script Directory
Scripts in `scripts/` subdirectory. `{baseDir}` = this SKILL.md's directory path. Resolve `${BUN_X}` runtime: if `bun` installed → `bun`; if `npx` available → `npx -y bun`; else suggest installing bun. Replace `{baseDir}` and `${BUN_X}` with actual values.
| Script | Purpose |
|--------|---------|
| `scripts/main.ts` | Main entry point with CLI options (uses remark-cjk-friendly for CJK emphasis) |
| `scripts/quotes.ts` | Replace ASCII quotes with fullwidth quotes |
| `scripts/autocorrect.ts` | Add CJK/English spacing via autocorrect |
## Preferences (EXTEND.md)
Check EXTEND.md in priority order — the first one found wins:
| Priority | Path | Scope |
|----------|------|-------|
| 1 | `.baoyu-skills/baoyu-format-markdown/EXTEND.md` | Project |
| 2 | `${XDG_CONFIG_HOME:-$HOME/.config}/baoyu-skills/baoyu-format-markdown/EXTEND.md` | XDG |
| 3 | `$HOME/.baoyu-skills/baoyu-format-markdown/EXTEND.md` | User home |
If none found, use defaults — no first-time setup required for this skill.
**EXTEND.md supports**:
| Setting | Values | Default | Description |
|---------|--------|---------|-------------|
| `auto_select` | `true`/`false` | `false` | Skip both title and summary selection, auto-pick best |
| `auto_select_title` | `true`/`false` | `false` | Skip title selection only |
| `auto_select_summary` | `true`/`false` | `false` | Skip summary selection only |
| Other | — | — | Default formatting options, typography preferences |
## Usage
The workflow has two phases: **Analyze** (understand the content) then **Format** (apply formatting). Claude performs content analysis and formatting (Steps 1-5), then runs the script for typography fixes (Step 6).
## Workflow
### Step 1: Read & Detect Content Type
Read the user-specified file, then detect content type:
| Indicator | Classification |
|-----------|----------------|
| Has `---` YAML frontmatter | Markdown |
| Has `#`, `##`, `###` headings | Markdown |
| Has `**bold**`, `*italic*`, lists, code blocks, blockquotes | Markdown |
| None of above | Plain text |
**If Markdown detected, use `AskUserQuestion` to ask:**
```
Detected existing markdown formatting. What would you like to do?
1. Optimize formatting (Recommended)
- Analyze content, improve headings, bold, lists for readability
- Run typography script (spacing, emphasis fixes)
- Output: {filename}-formatted.md
2. Keep original formatting
- Preserve existing markdown structure
- Run typography script only
- Output: {filename}-formatted.md
3. Typography fixes only
- Run typography script on original file in-place
- No copy created, modifies original file directly
```
**Based on user choice:**
- **Optimize**: Continue to Step 2 (full workflow)
- **Keep original**: Skip to Step 5, copy file then run Step 6
- **Typography only**: Skip to Step 6, run on original file directly
### Step 2: Analyze Content (Reader's Perspective)
Read the entire content carefully. Think from a reader's perspective: what would help them quickly understand and remember the key information?
Produce an analysis covering these dimensions:
**2.1 Highlights & Key Insights**
- Core arguments or conclusions the author makes
- Surprising facts, data points, or counterintuitive claims
- Memorable quotes or well-phrased sentences (golden quotes)
**2.2 Structure Assessment**
- Does the content have a clear logical flow? What is it?
- Are there natural section boundaries that lack headings?
- Are there long walls of text that could benefit from visual breaks?
**2.3 Reader-Important Information**
- Actionable advice or takeaways
- Definitions, explanations of key concepts
- Lists or enumerations buried in prose
- Comparisons or contrasts that would be clearer as tables
**2.4 Formatting Issues**
- Missing or inconsistent heading hierarchy
- Paragraphs that mix multiple topics
- Parallel items written as prose instead of lists
- Code, commands, or technical terms not marked as code
- Obvious typos or formatting errors
**Save analysis to file**: `{original-filename}-analysis.md`From JimLiu/baoyu-skills, MIT.
More from JimLiu/baoyu-skills
- 0.827score
baoyu-url-to-markdown
JimLiu
Fetch any URL and convert to markdown using baoyu-fetch CLI (Chrome CDP with site-specific adapters).
SkillBFreshness: B★ 26.9KClaude Code +9 - 0.827score
baoyu-image-gen
JimLiu
AI image generation with OpenAI GPT Image 2.5, Azure OpenAI, Google, OpenRouter, DashScope, Z.AI GLM-Image, MiniMax, Jimeng, Seedream, Replicate and Agnes APIs.
SkillBFreshness: B★ 26.9KClaude Code +9 - 0.770score
baoyu-xhs-images
JimLiu
Generates infographic image card series with 12 visual styles, 8 layouts, and 3 color palettes.
SkillCFreshness: C★ 26.9KClaude Code +9 - 0.770score
baoyu-article-illustrator
JimLiu
Analyzes article structure, identifies positions requiring visual aids, generates illustrations with Type × Style × Palette three-dimension approach.
SkillCFreshness: C★ 26.9KClaude Code +9 - 0.770score
baoyu-comic
JimLiu
Knowledge comic creator supporting multiple art styles and tones.
SkillCFreshness: C★ 26.9KClaude Code +9 - 0.770score
baoyu-compress-image
JimLiu
Compresses images to WebP (default) or PNG with automatic tool selection.
SkillCFreshness: C★ 26.9KClaude Code +9 - 0.770score
baoyu-danger-gemini-web
JimLiu
Generates images and text via reverse-engineered Gemini Web API.
SkillCFreshness: C★ 26.9KClaude Code +9 - 0.770score
baoyu-danger-x-to-markdown
JimLiu
Converts X (Twitter) tweets and articles to markdown with YAML front matter.
SkillCFreshness: C★ 26.9KClaude Code +9 - 0.770score
baoyu-diagram
JimLiu
Create professional, dark-themed SVG diagrams of any type — architecture diagrams, flowcharts, sequence diagrams, structural diagrams, mind maps, timelines…
SkillCFreshness: C★ 26.9KClaude Code +9 - 0.770score
baoyu-post-to-x
JimLiu
Posts content and articles to X (Twitter).
SkillCFreshness: C★ 26.9KClaude Code +9 - 0.770score
baoyu-infographic
JimLiu
Generate professional infographics with 21 layout types and 22 visual styles.
SkillCFreshness: C★ 26.9KClaude Code +9 - 0.770score
baoyu-post-to-wechat
JimLiu
Posts content to WeChat Official Account (微信公众号) via API or Chrome CDP.
SkillCFreshness: C★ 26.9KClaude Code +9
Signals
- Stars
- 26,925
- Forks
- 2,950
- Open issues
- 13
- Last commit (this folder)
- Apr 19, 2026 (6 months ago)
- Last release
- Jun 18, 2026 (4 months ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- MIT
- Repository
- github.com/JimLiu/baoyu-skills
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
Same skill elsewhere
Copies of this SKILL.md published by others; search shows only one of them.
- 0.358score
baoyu-format-markdown
EthanYoQ
Formats plain text or markdown files with frontmatter, titles, summaries, headings, bold, lists, and code blocks.
SkillBFreshness: B★ 11Claude Code +9 - 0.352score
baoyu-format-markdown
Hb-zzz-momo
Formats plain text or markdown files with frontmatter, titles, summaries, headings, bold, lists, and code blocks.
SkillAFreshness: A★ 1Claude Code +9 - 0.338score
baoyu-format-markdown
guanyang
Formats plain text or markdown files with frontmatter, titles, summaries, headings, bold, lists, and code blocks.
SkillCFreshness: C★ 980Claude Code +9 - 0.299score
baoyu-format-markdown
SassumiX
Formats plain text or markdown files with frontmatter, titles, summaries, headings, bold, lists, and code blocks.
SkillCFreshness: C★ 2Claude Code +9 - 0.259score
baoyu-format-markdown
makerjackie
Formats plain text or markdown files with frontmatter, titles, summaries, headings, bold, lists, and code blocks.
SkillDFreshness: D★ 1Claude Code +9 - 0.249score
baoyu-format-markdown
XX-Trader
Formats plain text or markdown files with frontmatter, titles, summaries, headings, bold, lists, and code blocks.
SkillDFreshness: DClaude Code +9 - 0.246score
baoyu-format-markdown
xfs96192
Formats plain text or markdown files with frontmatter, titles, summaries, headings, bold, lists, and code blocks.
SkillDFreshness: DClaude Code +9 - 0.246score
baoyu-format-markdown
chengyihua
Formats plain text or markdown files with frontmatter, titles, summaries, headings, bold, lists, and code blocks.
SkillDFreshness: DClaude Code +9
More from JimLiu
- 0.827score
baoyu-url-to-markdown
JimLiu
Fetch any URL and convert to markdown using baoyu-fetch CLI (Chrome CDP with site-specific adapters).
SkillBFreshness: B★ 26.9KClaude Code +9 - 0.827score
baoyu-image-gen
JimLiu
AI image generation with OpenAI GPT Image 2.5, Azure OpenAI, Google, OpenRouter, DashScope, Z.AI GLM-Image, MiniMax, Jimeng, Seedream, Replicate and Agnes APIs.
SkillBFreshness: B★ 26.9KClaude Code +9 - 0.770score
baoyu-article-illustrator
JimLiu
Analyzes article structure, identifies positions requiring visual aids, generates illustrations with Type × Style × Palette three-dimension approach.
SkillCFreshness: C★ 26.9KClaude Code +9 - 0.770score
baoyu-cover-image
JimLiu
Generates article cover images with 5 dimensions (type, palette, rendering, text, mood) combining 11 color palettes and 7 rendering styles.
SkillCFreshness: C★ 26.9KClaude Code +9 - 0.770score
baoyu-post-to-x
JimLiu
Posts content and articles to X (Twitter).
SkillCFreshness: C★ 26.9KClaude Code +9 - 0.770score
baoyu-comic
JimLiu
Knowledge comic creator supporting multiple art styles and tones.
SkillCFreshness: C★ 26.9KClaude Code +9
Cite this page
baoyu-format-markdown skill. Agent Mart. https://agentmart.dev/skills/jimliu-baoyu-format-markdown (last updated 2026-10-24)