Fanqie Publisher Skill
Playwright-powered Fanqie novel publishing skill with guides and thin adapters for OpenClaw, Hermes Agent, Claude Code, Codex CLI, and Cline.
Install: git clone https://github.com/amm10090/fanqie-publisher-skill
Works with Claude Code, Codex · 24 GitHub stars
Install
git clone https://github.com/amm10090/fanqie-publisher-skillInstall command taken from the project's README or registry entry. Always review code before running it.
README excerpt
Read full README on GitHub →Fanqie Publisher Skill
通过浏览器自动化(Playwright + CDP),将本地 Markdown 章节发布到番茄小说网作者后台。
本工具并非官方番茄小说 SDK 或公开 API 封装。后台改版可能导致自动化中断;正式发布前请务必使用安全模式验证。
🌐 简体中文 · English
功能特性
- 解析 Markdown 章节,自动拆分章节编号、标题和正文
- 支持单章或批量发布本地目录中的章节
- 对中文、Emoji 及 Unicode 字符提供可靠的输入支持(基于重新设计的番茄编辑器及往返读取验证)
- 会话过期时引导二维码登录,支持浏览器会话复用
- 即时发布及平台原生定时发布
- 拦截并处理错词警告、内容风险检测及最终发布设置弹窗
- 发布后返回章节管理页面,确认状态为「审核中」或「已发布」
- 安全的
--fill-only模式——仅填写编辑器字段,不提交任何内容 - 清晰的阶段区分:预览(preview-only)→ 仅填写(fill-only)→ 到达最终弹窗(at-final-modal)→ 已提交未验证(submitted-but-unverified)→ 已验证发布(verified publication)
平台支持
| 平台 | 状态 | 入口文件 | 说明 |
|---|---|---|---|
| OpenClaw | ✅ 已验证 | SKILL.md |
原生技能格式,含 YAML 前置元数据、命令和规则。注入的提示文件:AGENTS.md、SOUL.md、TOOLS.md。 |
| Hermes Agent | ✅ 已验证 | SKILL.md(复用) |
复用同一份 SKILL.md。通过 hermes claw migrate(官方迁移路径)导入。详见 Hermes Agent 教程。 |
| Claude Code | ✅ 已验证 | CLAUDE.md |
薄适配层——引用共享的 SKILL.md 和 references/ 获取业务逻辑。 |
| OpenAI Codex CLI | ✅ 已验证 | AGENTS.md |
薄适配层。所有业务逻辑来源于 SKILL.md、references/ 和 scripts/。 |
| Cline | ✅ 已验证 | .clinerules |
薄适配层。所有业务逻辑来源于 SKILL.md、references/ 和 scripts/。 |
除 OpenClaw/Hermes 外,每个薄适配层仅作为轻量入口。业务逻辑、选择器和安全规则均位于
SKILL.md、references/和scripts/中。任何适配层均不重复实现发布逻辑。
环境要求
- Node.js 及 npm
- Python 3
- Chromium/Chrome 浏览器(可通过 Playwright CDP 控制)
- 一个具备后台访问权限的番茄小说作者账号
- 首次使用前在仓库根目录执行
npm install
请勿声称可以自动安装依赖或假定这些环境已自动就绪。每个依赖均需手动安装或配置。
快速开始
git clone https://github.com/amm10090/fanqie-publisher-skill.git
cd fanqie-publisher-skill
npm install
基本工作流程:
- 将章节准备为
.md文件(一个文件 = 一个章节) - 预览解析结果:
python3 scripts/prepare_chapters.py --dir "/path/to/chapters" --preview - 通过 CDP 连接已登录的浏览器:
node scripts/login_fanqie.js --cdp http://127.0.0.1:9222 - 安全填充测试:
node scripts/publish_fanqie.js --cdp http://127.0.0.1:9222 --file "/path/to/chapter.md" --mode immediate --fill-only - 验证内容和页面状态无误后,先获得用户当轮明确确认,再**移除
--fill-only**并添加--confirm-publish进行真实发布
章节格式
每个 .md 文件代表一个章节:
第001章_标题.md
# 第001章 标题
正文第一段。
第二段。
解析器会将第一个 Markdown 标题从正文中剥离,将 第001章 标题 拆分为序号 1 和显示标题 标题,并填入番茄编辑器对应字段。序号中的前导零在实际数值输入时会被移除。
平台教程
OpenClaw
将克隆后的仓库目录放入 OpenClaw 工作区的 skills 文件夹中,或将 OpenClaw 指向此目录。SKILL.md 文件作为完整的技能定义,包含:
- YAML 前置元数据(
name、description),用于自动技能发现 - 完整的
commands部分,涵盖所有入口点 rules部分,包含安全上限、登录处理和平台限制- 经过验证的逐步发布工作流
OpenClaw 还会在工作区级别注入 AGENTS.md、SOUL.md 和 TOOLS.md 作为全局提示文件。
# 技能加载后,可用的命令:
python3 scripts/prepare_chapters.py --dir "/path/to/chapters" --preview
node scripts/login_fanqie.js --cdp http://127.0.0.1:9222
node scripts/publish_fanqie.js --cdp http://127.0.0.1:9222 --file "/path/to/chapter.md" --mode immediate --fill-only
关于批量发布、定时发布、分卷选择和重试,请阅读 SKILL.md。
Hermes Agent
Hermes Agent 使用与 OpenClaw 相同的 SKILL.md 文件。通过官方迁移命令导入。
前提条件
- 已安装 Hermes Agent(官方仓库:NousResearch/hermes-agent)
- 已在本地检出此仓库
迁移路径(官方方式)
Hermes 提供 hermes claw migrate 命令,用于将 OpenClaw 技能导入到 ~/.hermes/skills/openclaw-imports/。其 --source 选项需要一个 OpenClaw 根目录,而非直接指向此仓库。
Similar plugs
Makes your AI agent think like the laziest senior dev in the room. The best code is the code you never wrote.
Turn any codebase, with its docs, SQL schemas, configs, and PDFs, into a queryable knowledge graph. A /graphify skill for Claude Code, Cursor, Codex, and Gemini CLI: local…
Why use many token when few token do trick. Viral skill + proxy for coding agents that cuts 65% of tokens by talking like a caveman.
Production-grade engineering skills for AI coding agents.
The 1st Collaborative AI Design Agent Workspace. Local-first and open source. Create prototypes, websites, apps, dashboards, presentations, images, and videos with your team…