geekjourneyx/md2wechat-skill / skills/md2wechat
md2wechat
VerifiedConvert Markdown to WeChat Official Account HTML. Use this whenever the user wants WeChat article formatting, article preview, WeChat draft upload, image generation for articles, cover or infographic generation, image-post creation, writer-style drafting, title suggestions, AI trace removal, or current discovery of supported providers, themes, prompts, and layout modules. Also use for unpublished Zhihu, CSDN, Toutiao, or Tencent Cloud Developer Community drafts through a browser. Use for product introductions, encyclopedia articles or entry drafts, and writing tailored to platforms or search targets.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 14.8 KB |
| references/sync/csdn.md | markdown | 963 B |
| references/sync/tencent-cloud.md | markdown | 2.6 KB |
| references/sync/toutiao.md | markdown | 1.4 KB |
| references/sync/workflow.md | markdown | 4.2 KB |
| references/sync/zhihu.md | markdown | 854 B |
| references/writing/baidu-baike.md | markdown | 1.6 KB |
| references/writing/forms.md | markdown | 1.6 KB |
| references/writing/platforms.md | markdown | 1.8 KB |
| references/writing/search-strategies.md | markdown | 2.0 KB |
| references/writing/toutiao-baike.md | markdown | 1.8 KB |
| references/writing/workflow.md | markdown | 4.4 KB |
references/sync/workflow.md
View on GitHub# 跨平台草稿流程
复用用户已登录的浏览器,以 DOM 或可访问性定位操作正常编辑器;此流程仅保存草稿,不截图、不调用内部业务接口。
## 准备
1. 已取得本次未变更原稿的成功准备结果时直接复用;否则通过 `md2wechat capabilities --json` 确认 `sync prepare` 可用,再运行 `md2wechat sync prepare <article.md> --output <new-dir> --json`。失败先处理返回的问题,不开始远端写入。`action_required` 只表示本地准备完成。
2. 读取结果中的 `title`、`body_html`、`images`、`heading_levels`,以及目标平台说明:`md2wechat skills read md2wechat references/sync/<platform>.md`,其中 `<platform>` 为 `zhihu`、`csdn`、`toutiao` 或 `tencent-cloud`。只读本次目标。
3. 按平台说明检查输入限制。标题计数不确定时,在上传正文前填写标题并检查页面校验;不自动截断或改写原稿。
4. 按下方“浏览器选择”确认现有会话、页面读取、正常 HTML 粘贴;有图片时还需文件上传。
5. 核对指定账号。已有本次草稿地址时恢复同稿;新开标签从当前列表取得。账号或草稿归属不明时先澄清。
## 浏览器选择
优先使用当前 Agent 的 Computer Use/浏览器工具,通过 DOM 或可访问性结构完成操作。文件上传工具不可用时,可用宿主支持的系统文件窗口。
仅在宿主缺少必要能力且允许使用替代工具时,运行 `agent-browser --version` 检查备选工具,并依据该版本的 `--help` 确认连接和操作方式。优先连接用户已登录的浏览器;`--auto-connect` 需要浏览器提供可用的远程调试连接,安装工具不等于能连接现有会话。
未安装时告知可用 `npm install -g agent-browser` 安装,按用户授权和环境权限执行。`agent-browser install` 用于下载自动化浏览器,仅在需要独立浏览器且用户接受首次登录时使用,不作为默认步骤。
使用备选前确认能读取页面、正常粘贴富文本、上传所需图片并重新打开核验;仅有文本输入或截图能力不足以执行本流程。缺项未解决时报告具体阻碍并交接该步骤。权限拒绝不能通过换工具绕过;账号登录或平台内容限制也不能靠换工具解决。
切换工具后先恢复并核对原草稿,再执行未完成步骤;保存结果不明时按下方恢复流程检查,不重新创建。两种工具共用同一平台说明和核验要求。
## 写入
先确认目标平台是否规定不同的图文写入顺序。腾讯云按 `tencent-cloud.md` 先粘贴正文、再逐处原生插图,跳过下方图片地址回填与整体替换步骤;其余平台沿用下方流程。
控件必须在正文区域或当前弹层内唯一匹配;结构不符时停止该步骤,不猜位置。不同工具句柄须指向同一草稿。
有图片时,先在本次草稿中逐张正常上传并插入,等正文图片加载后读取实际地址。每个不同源文件上传一次;不同平台分别上传。
用 HTML 解析器处理 `body_html` 的平台副本:将 `img src` 的 URL 路径解码一次,与 `images` 的绝对路径匹配,再把所有对应出现位置替换为该平台已上传的地址并正确序列化。不要全局替换字符串或跨平台复用图片地址。
聚焦正文并全选该区域,用正常 HTML 粘贴替换临时内容;iframe 编辑器须在框架内聚焦。快捷键按宿主文档和操作系统选择,不通过脚本修改 DOM。立即回读,确认正文完整替换、无旧内容或重复图片。随后填写并回读标题。
## 保存与恢复
按平台说明保存,保留唯一草稿编辑地址;通用写作入口不能用于恢复。结果不明时先查同稿或草稿箱,结合标题、时间和正文识别,不盲目重建。
重新打开唯一地址,对照准备内容核对标题、完整正文及顺序、标题层级、列表、代码与空白、表格单元格、图片位置和加载状态。图片组件的重复展示节点不算多张图片。出现缺失在同稿修正并重验;无法保留内容时停止该目标,不自动删改源稿。
报告已核验的草稿地址和未解决差异;保存提示或地址本身不能证明内容完整。
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis. | Stars: 472k | Updated | Claude CodeCodex | Verified | Install |
| diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness. | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependencies | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |