writing-for-agents

writing-for-agents is a skill for Claude Code, Codex from byheaven/byheaven-skills. It costs 40 tokens per session (2,726 once invoked), scanned A, a copy of writing-for-agents, MIT.

A writing guide for documents that coding agents read and follow, including skills, agent definitions, AGENTS.md, and CLAUDE.md files. It explains how to make instructions predictable and how references to extra context should work.

In plain words
What is it for?
Use it when creating or editing agent instructions, skills, rules, directives, briefs, or documents linked from them.
Why use it?
Poorly worded instructions can make an agent miss important material or follow the wrong branch of a task. The guide helps keep agent instructions clear and reliably triggered.

Skill for Claude CodeCodex

Written for Claude Code and Codex: shipped in a Claude Code plugin, but also agents/openai.yaml present. Also seen: mentions subagents.

Part of the byworkflow plugin — 10 skills, 2 agents shipped together

Good fit Use it when creating or editing agent instructions, skills, rules, directives, briefs, or documents linked from them.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/byheaven/byheaven-skills/writing-for-agents
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add byheaven/byheaven-skills --skill writing-for-agents
Clone the repo
git clone --depth 1 https://github.com/byheaven/byheaven-skills

Made for: Claude Code, Codex.

Or install byworkflow, the plugin that ships this one along with the rest of its 10 skills, 2 agents.

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-for-agents

README.md
[![agentmods](https://agentmods.dev/badge/skills/byheaven/byheaven-skills/writing-for-agents/github.svg)](https://agentmods.dev/skills/byheaven/byheaven-skills/writing-for-agents)
Your own site
<a href="https://agentmods.dev/skills/byheaven/byheaven-skills/writing-for-agents"><img src="https://agentmods.dev/badge/skills/byheaven/byheaven-skills/writing-for-agents/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-for-agents

Your own site · 80×15
<a href="https://agentmods.dev/skills/byheaven/byheaven-skills/writing-for-agents"><img src="https://agentmods.dev/badge/skills/byheaven/byheaven-skills/writing-for-agents.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 40 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,726 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 98% copy Near-identical to another mod 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.00040 $0.02726
Opus 5.5 $0.00016 $0.01090
Sonnet 5.5 $0.00008 $0.00545
Haiku 4.5 $0.00004 $0.00273

Measured today against content hash 0ce5990af53d, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

writing-for-agents 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 today.

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.

Origin

This is a copy

98% identical to writing-for-agents — 22 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

plugins/byworkflow/skills/writing-for-agents/SKILL.md · 83 lines

How it starts

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

Reference for writing any document an agent consumes: a skill, the project instruction file, a doc reached by a pointer, a directive or brief. The packaging differs; the writing does not. Each one tells the agent the outcome, why it matters, who judges it, and the facts it cannot find by looking, and leaves method, tools, format, and depth to the agent; a constraint belongs in it only while it carries the user's decision or guards a concrete risk. The levers below decide how reliably that reaches the agent.

When the document you're writing is a skill, read SKILL-MECHANICS.md for frontmatter, invocation choice, and router skills.

Context pointers

A context pointer is a reference held in the agent's context that names some out-of-context material and encodes the condition for reaching it. A skill's description is one; a line in the project instruction file naming a doc is the same object. The pointer's wording, not its target, decides when the agent reaches the material, and how reliably. A must-have target behind a weakly worded pointer is a variance bug: sharpen the wording first, and inline the material only if sharpening fails. Wording cannot fix placement, which follows who must act on the rule, when, and how long it must hold: a rule only one role acts on loads with that role's definition. A rule that holds for the whole session sits in always-loaded content, since a trigger such as "at task start" never fires in a standing conversation and material read once is gone after compaction. A rule that acts on a given action may sit in an on-demand file only when its pointer is always loaded and names that action as a condition the agent can detect. A rule that contradicts a platform default the user may override is always loaded and says it overrides that default, since the default sits in context every turn and outweighs a rule read on demand; placement makes the rule present, it does not lift it above a higher-priority instruction.

A pointer does two jobs: state what the material is, and list the branches that should trigger reaching it (a branch is a distinct case the document handles, so different runs take different paths through it). Every word of an always-loaded pointer costs on every turn, so it earns even harder pruning than the body:

  • Front-load the leading word: the pointer is where it does its triggering work.
  • One trigger per branch. Synonyms that rename a single branch are one branch written twice; collapse them and keep only genuinely distinct branches.
  • Cut identity the body already carries.

Read the full file on GitHub · 83 lines

Files

What ships with it

4 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. today Changed · +1 lines 0ce5990af53d
  2. 19d ago Changed f655c41c3cfe
  3. 23d ago Changed c3e3269c1121
  4. 1mo ago Changed fff3a08c285a
  5. 1mo ago Changed · -4 tokens per session 9c829dafc574
  6. 1mo ago Changed c2a160350ea6
  7. 1mo ago First seen · 82 lines · 44 tokens per session scan A 8b4390e32c3a

Subscribe to this mod's changes

writing-for-agents is a skill published in the GitHub repository byheaven/byheaven-skills (2 stars, last pushed today), licensed MIT. It adds 40 tokens to every session and 2,726 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. It is 98% identical to writing-for-agents, differing in 22 lines, and is treated as a copy.

Related

writing-for-agents compared with skills from other repositories

writing-for-agents next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
writing-for-agentsbyheaven/byheaven-skillsSkill2todayMITA40Claude Code, Codex
reviewSethGammon/CitadelSkill9436d agoMITA17Claude Code
wenlan-handoffwenlan-app/wenlanSkill502todayApache-2.0A46Claude Code, Codex
system-upgradealivecontext/aliveSkill13215d agoMITA55Claude Code
pr-reviewnitinjain999/platform-skillsSkill743d agoApache-2.0A81Claude Code
apex-skillifytonone-ai/tononeSkill85yesterdayMITA41Claude Code
voice-notesgtapps/hermitdSkill88yesterdayMITA34Claude Code