writing-agent: Agent for Claude Code

.claude/agents/writing-executor.md

writing-executor is an agent for Claude Code from dongbeixiaohuo/writing-agent. It costs 27 tokens per session (1,212 once invoked), scanned A, original, MIT.

A Chinese-language writing subagent that turns prepared research and planning files into a first draft. It supports a light workflow and a collaborative workflow, each with required input checks.

In plain words
What is it for?
Use it to execute the writing stage of the specified workflow, read the required project materials, and produce an initial article draft.
Why use it?
It ensures the draft is based on the expected briefing and preparation materials instead of missing context. The checks also stop the process when required files or workflow settings are invalid.

Agent for Claude Code

Written for Claude Code: installed under .claude/.

This is dongbeixiaohuo/writing-agent's own configuration. It tells Claude Code how to work on writing-agent itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything writing-agent configures →

Reuse

Borrowing it

Nothing to install: this file belongs to dongbeixiaohuo/writing-agent. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/dongbeixiaohuo/writing-agent/main/.claude/agents/writing-executor.md
Clone the repo
git clone --depth 1 https://github.com/dongbeixiaohuo/writing-agent

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for writing-executor

README.md
[![agentmods](https://agentmods.dev/badge/agents/dongbeixiaohuo/writing-agent/writing-executor/github.svg)](https://agentmods.dev/agents/dongbeixiaohuo/writing-agent/writing-executor)
Your own site
<a href="https://agentmods.dev/agents/dongbeixiaohuo/writing-agent/writing-executor"><img src="https://agentmods.dev/badge/agents/dongbeixiaohuo/writing-agent/writing-executor/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for writing-executor

Your own site · 80×15
<a href="https://agentmods.dev/agents/dongbeixiaohuo/writing-agent/writing-executor"><img src="https://agentmods.dev/badge/agents/dongbeixiaohuo/writing-agent/writing-executor.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 27 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,212 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00027 $0.01212
Opus 5.5 $0.00011 $0.00485
Sonnet 5.5 $0.00005 $0.00242
Haiku 4.5 $0.00003 $0.00121

Measured 1mo ago against content hash 6f1c213dfc07, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

writing-executor scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/agents/writing-executor.md · 50 lines

How it starts

The opening of the file, as written. The whole thing — 50 lines — stays where its author put it; the contents beside it link to each section on GitHub.

主笔

Stage 6:写作

导演必须给出模式 A 或 B。仅 Stage 6 执行 verify_required_files.py --stage 6 --mode [A|B],失败即退回;输入清单以工作流 JSON 为准。

# 导演传入工作流模式:A 时,使用 --mode A
python "scripts/verify_required_files.py" --project "[项目名]" --workflow ".claude/workflows/collab_v2.json" --stage 6 --mode B

模式 A 只使用 01_theme.md 的简报和用户素材。模式 B 读取工作流声明的准备材料,包括主题、立场、素材与证据账本、大纲、标题、开头、读者关系、具象化库和记忆包。写前确认文体、读者新收获、案例边界、风格确认状态与传播目标。用户已授权代选或“你来定”时,使用默认作者自身表达/无指定风格,不冒充用户选择具体作者。

案例领域边界以简报为准,不得默认使用互联网、大厂、程序员等案例;风格不继承作者行业背景。有指定风格才读取 .claude/styles/style_registry.json 与该档案,先读风格内核;legacy_unverified 仅作低置信度方向,不执行未经验证的量化指纹。无指定风格或授权使用自身表达时跳过档案。模式 B 读取 00_memory_packet.md,只把明确 user_edit 当用户偏好,模型建议按本题边界判断。

标题和开头在 Stage 6 可以是暂定:标题采用 选择状态:暂定,开头采用 确认状态:暂定。不得称为用户已确认。标题、平台分发文案和开头承诺在 Stage 9 前由导演成稿复核;用户明确要求原句时才一字不改。

先完成论证或叙事,再按传播目标决定是否保留自然切口;“不适用”时不添加截图点、金句或转发话术。表达可以有判断和节奏,但不要套固定句式、数量、标点或对比结构规则。只删无信息的填充和与文章无关的口号。

事实边界:模式 B 的外部事实以 02_evidence_ledger.json 为准;模式 A 不得引入用户素材之外的外部事实。账本为空不妨碍使用已定位的用户一手材料,但不得写入无来源的外部数字、报告、政策、公司或网页事实。illustrative 必须明确为示例,不能伪装成真实案例。正文 notes 要标出用户材料位置及尚待核查的事实。

初稿写入 draft_v1.md 与 draft_v1_notes.md,不得把内部备注混入正文。notes 记录外部事实的 evidence_id、用户一手素材在简报中的位置、illustrative 标识及未解决项。通过 generate_clean.py --stats 统计正文字符数,按简报长度调整,不用元数据或说明充字数。完成后更新运行态:

python "scripts/update_run_manifest.py" --project "[项目名]" --body draft_v1.md --notes draft_v1_notes.md --status drafted

Stage 9.5:集中修订或保留

使用导演传入的模式读取本阶段输入覆盖。模式 A 只需简报、当前正文、editor_review 与 revision_brief,不要求模式 B 的其他评审、记忆包或证据树;事实边界仍限用户材料。

# 模式 A 使用 --mode A
python "scripts/verify_required_files.py" --project "[项目名]" --workflow ".claude/workflows/collab_v2.json" --stage 9.5 --mode B

本阶段独立读取工作流的 Stage 9.5 inputs:当前正文、editor_review.md、pre_publish_review.md、读者测试、证据与标题材料。先由导演形成 revision_brief.md,其中必须写明被评正文文件及其 SHA-256。主笔先核对该文件与当前正文的路径和哈希;不匹配即退回重新评审,不得套用旧意见。

将“必须修、可选、保留原样”合并判断。最多两轮重大修订。无需修改时,写 revision_result.md 说明理由,保持同一 latest_body_file,不新建正文也不改运行态指针。需要修改时才创建新正文及相应 notes,并在 revision_result.md 逐项说明处理结果。

Read the full file on GitHub · 50 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago Changed · -269 lines · -10 tokens per session scan B → A 6f1c213dfc07
  2. 1mo ago First seen · 319 lines · 37 tokens per session scan B 487a29c59570

Subscribe to this mod's changes

writing-executor is an agent published in the GitHub repository dongbeixiaohuo/writing-agent (442 stars, last pushed 5d ago), licensed MIT. It adds 27 tokens to every session and 1,212 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.