← 开源
xiaohuailabs

xiaohu-wechat-format

Claude Code 公众号一键排版+发布技能 | Markdown → 微信兼容 HTML → 推送草稿箱 | 30 套主题 + 可视化画廊

AI EngineeringGive agent toolsBring agent to usersPython
在 GitHub 打开
增长势头
+024 小时新增 Star0.0%
700
Star
95
Fork
+1
本周
1
贡献者
创建于 2026-03-08 · 更新于 2026-10-11 · 今日第 14838 名
主要开发者
xiaohuailabs

xiaohuailabs/xiaohu-wechat-format 排名第 14,838,有 700 个星标。

同类别比较

xiaohuailabs/xiaohu-wechat-format 排名第 14,838,此处有 8 个同类条目;usail-hkust/LLM-MM-Agent 排名第 14,837。

同类别比较
名称排名指标
taranjeet/unofficial-chatgpt-api14,823
语言:
Python
星标数:
701
分叉数:
136
简介:
This repo is unofficial ChatGPT api. It is based on Daniel Gross's WhatsApp GPT
arklexai/Agent-First-Organization14,829
语言:
Python
星标数:
700
分叉数:
100
简介:
The official Python library for Arklex framework
realrossmanngroup/no_ai_slop_writing_rules14,836
星标数:
700
分叉数:
77
简介:
Claude Code reference: write in Louis Rossmann's voice, never like AI slop. Portable CLAUDE.md plus skills.
usail-hkust/LLM-MM-Agent14,837
语言:
Python
星标数:
700
分叉数:
56
简介:
🔥🔥🔥 [NeurIPS2025] MM-Agent: LLM as Agents for Real-world Mathematical Modeling Problem
Picovoice/speech-to-text-benchmark14,839
语言:
Python
星标数:
699
分叉数:
73
简介:
speech to text benchmark framework
alfianlosari/ChatGPTSwift14,841
语言:
Swift
星标数:
699
分叉数:
136
简介:
Access ChatGPT API using Swift
mlabonne/llm-autoeval14,844
语言:
Python
星标数:
699
分叉数:
109
简介:
Automatically evaluate your LLMs in Google Colab
if-ai/ComfyUI-IF_AI_tools14,854
语言:
Python
星标数:
698
分叉数:
55
简介:
ComfyUI-IF_AI_tools is a set of custom nodes for ComfyUI that allows you to generate prompts using a local Large Language Model (LLM) via Ollama. This tool enables you to enhance your image generation workflow by leveraging the power of language models.
关键参数与规格
关键参数与规格
参数值
语言Python
类别AI Engineering
子类别Give agent tools,Bring agent to users
关键词Automation, Claude Code, Client integration, Document understanding
星标数700
分叉数95
贡献者1
创建日期2026-03-08
更新日期2026-10-11
1 天星标数0
7 天星标数1
排名14,838
上次排名14,680
排名变化-158
7 天星标排名10,898
上次 7 天星标排名10,954
7 天星标排名变化56
总星标排名14,900
上次总星标排名14,869
总星标排名变化-31
README 摘录

**Visual Gallery**: Preview 34 curated themes (10 categories) with your actual article, switch font size (15/16/17px) and font family (serif / Song / Kai / rounded) live, then pick one 4. **One-Click Publish**: Uploads images to WeChat CDN and pushes the article to your drafts Quick Start Using with Claude Code Just say: Claude will: 1. Auto-enhance content (add dialogue containers, callout blocks, etc. Open the theme gallery in your browser 4. You pick a theme, tell Claude the

name 5. It calls the Gemini Image API (or compatible third-party gateways) to produce WeChat cover images (2. Generate a cover: Or with Claude Code, just say: See for the full prompt template and workflow details. How WeChat Compatibility Works WeChat's editor strips tags and CSS classes. This tool: **CJK spacing fix**: Auto-adds spaces between Chinese and English/numbers **Bold punctuation fix**: Moves Chinese punctuation outside bold markers ( → ) Writes all styles as inline attributes on every element Converts

to + flexbox (WeChat mangles native lists) Transforms external links into footnotes (WeChat blocks external links) Processes Obsidian wiki-links and standard references Renders callout blocks ( , , ) with distinct colors Converts dialogue blocks into chat-bubble layouts Requirements Python 3 library library (for publishing) License MIT

常见问题

记录了多少星标和分叉?

xiaohuailabs/xiaohu-wechat-format 有 700 个星标和 95 个分叉。

仓库排名是多少?

xiaohuailabs/xiaohu-wechat-format 排名第 14,838。

记录的语言和类别是什么?

xiaohuailabs/xiaohu-wechat-format 有 700 个星标,语言为 Python,类别为 AI Engineering。

哪个仓库排名最接近?

xiaohuailabs/xiaohu-wechat-format 与 usail-hkust/LLM-MM-Agent 比较,后者排名第 14,837,有 700 个星标。

README

xiaohu-wechat-format

A Claude Code skill for the full WeChat Official Account (公众号) publishing pipeline: Format → Cover (optional) → Publish — with 85 themes, a visual gallery picker, AI content enhancement, and one-click publishing to drafts.

中文说明

What It Does

  1. Markdown → WeChat HTML: Converts standard Markdown into inline-styled HTML that works in WeChat's editor (no `` tags, no classes — everything inline)
  2. 85 Themes: From newspaper-style serif to neon cyberpunk — card, timeline, and hero layouts included
  3. Visual Gallery: Preview 34 curated themes (10 categories) with your actual article, switch font size (15/16/17px) and font family (serif / Song / Kai / rounded) live, then pick one
  4. AI Content Enhancement: Auto-detects dialogue, key quotes, and image sequences — wraps them in styled containers; explicit ::: container syntax (byline / stat / gallery / longimage / dialogue) also supported
  5. One-Click Publish: Uploads images to WeChat CDN and pushes the article to your drafts

Quick Start

# Install
cd ~/.claude/skills/
git clone https://github.com/xiaohuailabs/xiaohu-wechat-format.git
cp xiaohu-wechat-format/config.example.json xiaohu-wechat-format/config.json
pip3 install markdown requests

# Format an article (opens gallery in browser)
python3 scripts/format.py --input article.md --gallery

# Format with a specific theme
python3 scripts/format.py --input article.md --theme newspaper

# Publish to WeChat drafts
python3 scripts/publish.py --dir /tmp/wechat-format/article-name/ --cover cover.jpg

Using with Claude Code

Just say:

排版这篇文章 /path/to/article.md

Claude will:

  1. Read and analyze your article
  2. Auto-enhance content (add dialogue containers, callout blocks, etc.)
  3. Open the theme gallery in your browser
  4. You pick a theme, tell Claude the name
  5. Claude formats and optionally publishes to WeChat

Themes (30)

Standalone Styles (9)

Theme ID Style
Terracotta terracotta Warm orange, rounded headers
ByteDance bytedance Blue-teal gradient, modern tech
Chinese chinese Vermillion red, classical
Newspaper newspaper NYT-style serif, serious
GitHub github Developer-friendly, light code blocks
SSPAI sspai Chinese tech media red
Bauhaus bauhaus Primary colors, geometric
Ink ink Pure black, minimal whitespace
Midnight midnight Dark background, neon accents

Curated Styles (7)

Theme ID Style
Sports sports Gradient stripes, energetic
Mint mint-fresh Mint green, fresh
Sunset sunset-amber Warm amber tones
Lavender lavender-dream Purple dreamy
Coffee coffee-house Brown warm tones
WeChat Native wechat-native WeChat green
Magazine magazine Extra whitespace, editorial

Template Series (14)

4 layouts (Minimal / Focus / Elegant / Bold) × multiple color variants (Gold / Blue / Red / Green / Navy / Gray)

Container Syntax

Enhance your Markdown with these containers before formatting:

:::dialogue[Interview Title]
Alice: Hello there
Bob: Hi, how are you?
:::

:::gallery[Screenshots]
![](img1.jpg)
![](img2.jpg)
![](img3.jpg)
:::

> [!important] Key Insight
> This is the important takeaway

> [!tip] Pro Tip
> A useful tip for readers

Configuration

Edit config.json:

{
  "output_dir": "/tmp/wechat-format",
  "vault_root": "/path/to/your/obsidian/vault",
  "settings": {
    "default_theme": "newspaper",
    "auto_open_browser": true
  },
  "wechat": {
    "app_id": "YOUR_APP_ID",
    "app_secret": "YOUR_APP_SECRET",
    "author": "Author Name"
  },
  "cover": {
    "output_dir": "~/Documents/covers",
    "image_generation_script": ""
  }
}
  • wechat section is only needed for publishing; formatting works without it
  • cover section is only needed for cover image generation
  • Get AppID/AppSecret from: WeChat Official Account Admin → Settings → Basic Configuration
  • Important: Add your public IP to the WeChat IP whitelist, otherwise API calls will fail with error 40164

Cover Image Generation

This repo includes a complete cover image generator in cover/. It calls the Gemini Image API (or compatible third-party gateways) to produce WeChat cover images (2.35:1 ratio, Notion illustration style).

Setup

  1. Copy cover/config.example.json → cover/config.json
  2. Fill in your API credentials:
{
  "output_dir": "~/Documents/covers",
  "settings": {
    "base_url": "https://YOUR_PROVIDER/v1",
    "model": "gemini-3-pro-image-preview"
  },
  "secrets": {
    "api_key": "YOUR_API_KEY"
  }
}
  1. Generate a cover:
python3 scripts/generate.py \
  --config cover/config.json \
  --prompt-file prompt.md \
  --out cover.jpg

Or with Claude Code, just say: 给这篇文章配个封面

See cover/SKILL.md for the full prompt template and workflow details.

How WeChat Compatibility Works

WeChat's editor strips `` tags and CSS classes. This tool:

  • CJK spacing fix: Auto-adds spaces between Chinese and English/numbers
  • Bold punctuation fix: Moves Chinese punctuation outside bold markers (**text,** → **text**,)
  • Writes all styles as inline style="..." attributes on every element
  • Converts / to `` + flexbox (WeChat mangles native lists)
  • Transforms external links [text](url) into footnotes (WeChat blocks external links)
  • Processes ![[image.jpg]] Obsidian wiki-links and standard ![](image) references
  • Renders callout blocks ([!tip], [!important], [!warning]) with distinct colors
  • Converts dialogue blocks into chat-bubble layouts

Requirements

  • Python 3
  • markdown library
  • requests library (for publishing)

License

MIT

排名相邻
同类项目