一键导入
document-writer
// 多风格文档写作技能。支持乔木、小红书、Dankoe、微信公众号、Twitter等5种写作风格。Claude 根据内容智能选择风格,按规范撰写文章。
// 多风格文档写作技能。支持乔木、小红书、Dankoe、微信公众号、Twitter等5种写作风格。Claude 根据内容智能选择风格,按规范撰写文章。
| name | document-writer |
| description | 多风格文档写作技能。支持乔木、小红书、Dankoe、微信公众号、Twitter等5种写作风格。Claude 根据内容智能选择风格,按规范撰写文章。 |
| allowed-tools | Bash, Read, Write, Edit, Glob, Grep, TodoWrite |
将任意主题或素材转化为指定风格的文章。
illustration-generator# 指定风格写作
/document-writer "秦军消失之谜" --style wechat
# 从素材改写
/document-writer source.md --style qiaomu
# 风格转换
/document-writer convert article.md --to xiaohongshu
| 风格 | 字数 | 特点 | 适用场景 |
|---|---|---|---|
qiaomu | 8000-10000 | 口语化、对话感、生活化类比 | 技术论文解读、深度科普 |
xiaohongshu | 800-1200 | 情绪化、去爹味、emoji点缀 | 种草文、干货分享 |
dankoe | 5000-8000 | 挑衅开场、反常识、长短句交替 | 深度思考、观点输出 |
wechat | 3000-6000 | 短段落、重点加粗、结尾互动 | 公众号文章、行业分析 |
twitter | 100-280 | 钩子开头、精炼有力 | Twitter帖子、知识卡片 |
Claude 执行:
如果用户指定了 --style:
如果用户未指定风格:
调用 shared-lib 获取可用风格:
import sys
sys.path.insert(0, str(Path.home() / '.claude' / 'skills' / 'shared-lib'))
from writing import list_styles
print(list_styles()) # ['qiaomu', 'xiaohongshu', 'dankoe', 'wechat', 'twitter']
调用 shared-lib 获取风格提示词:
from writing import get_style_prompt, get_style_info
# 获取风格详情
info = get_style_info('wechat')
print(f"风格: {info['display_name']}")
print(f"字数: {info['word_count']['min']}-{info['word_count']['max']}")
# 获取完整风格指南(给 Claude 用)
prompt = get_style_prompt('wechat')
print(prompt)
Claude 按风格规范撰写:
阅读风格指南中的:
按规范撰写文章:
输出完整 Markdown 文章
Claude 根据风格执行自检:
qiaomu 风格检查:
wechat 风格检查:
xiaohongshu 风格检查:
发现问题 → 静默修复 → 继续
创建输出目录和文件:
{output_dir}/
├── {title}.md # Markdown文章
└── metadata.json # 元数据
metadata.json 格式:
{
"title": "文章标题",
"style": "wechat",
"word_count": 3500,
"source": "source.md 或 null",
"created_at": "2026-01-26T10:00:00",
"generator": "document-writer"
}
✅ 文章生成完成!
📄 文件: {title}.md
📝 风格: 微信公众号风格 (wechat)
📊 字数: 3500字
✓ 质量检查: 通过
下一步建议:
- 调用 /illustration-generator 生成配图
- 调用 /wechat-article-formatter 格式化为微信HTML
将已有文章转换为其他风格。
使用:
/document-writer convert article.md --to xiaohongshu
转换流程:
get_conversion_guide(from_style, to_style) 获取转换指南| 顺序 | Skill | 功能 |
|---|---|---|
| 1 | document-writer | 生成 Markdown 文章 |
| 2 | illustration-generator | 为文章生成配图 |
| 3 | md-to-pdf | 转换为 PDF |
| 4 | wechat-article-formatter | 格式化为微信 HTML |
| 5 | wechat-publisher | 发布到微信公众号 |
模块路径: ~/.claude/skills/shared-lib/writing/
| 函数 | 用途 |
|---|---|
list_styles() | 返回可用风格列表 |
get_style_info(style) | 返回风格详情(字数、特点等) |
get_style_prompt(style) | 返回完整风格指南(给 Claude 用) |
get_conversion_guide(from, to) | 返回风格转换指南 |
注意: 内容类型判断由 Claude 完成,不依赖关键词匹配。
用户:
/document-writer "客家新论:秦军消失之谜" --style wechat
Claude 执行:
客家新论:秦军消失之谜.md用户:
/document-writer source.md --style xiaohongshu
Claude 执行:
用户:
/document-writer convert long-article.md --to twitter
Claude 执行:
知识漫画生成器,支持多种风格(Ligne Claire/漫画教程风/武侠风等)。将文章/教程/人物传记转换为漫画形式。
统一配图技能,支持文章配图、封面生成、小红书图片系列、单图修改/添加/删除、3变体风格预览。20种风格×多种布局。
Convert markdown documents to PDF with optional illustrations. Can automatically call illustration-generator if images are missing. Supports Chinese fonts and custom styling.
生成自然真实的双人访谈播客,使用共享TTS模块支持3种引擎(Edge TTS / IndexTTS2 / MiniMax)和情感控制
生成专业 PPT 演示文稿,支持 22 种风格,自动根据内容选择最佳风格,输出到 ~/ppt-output/
Intelligently compress and rewrite documents into TTS-friendly scripts. Uses Claude AI to analyze content, compress to target duration, convert to spoken style with emotional language, and auto-segment. Perfect for video narration.