clearmode: Instructions file for Codex

AGENTS.md

clearmode AGENTS.md is an instructions file for Codex, OpenCode from eugeniughelbur/clearmode. It costs 1,110 tokens per session, scanned A, original, MIT.

A repository instruction file for the clearmode project, which defines the CLEAR-100 writing standard and its checker. It explains the source files, generated files, project layout, and required steps for changing rules.

In plain words
What is it for?
Maintaining CLEAR-100 rules, regenerating instruction targets, running the test suite, and understanding the project’s file structure.
Why use it?
It prevents contributors from editing generated files directly or changing the writing standard without rebuilding and testing its outputs.

Instructions file for CodexOpenCode

Written for Codex and OpenCode: the file is AGENTS.md. Also seen: mentions AGENTS.md.

This is eugeniughelbur/clearmode's own configuration. It tells Codex and OpenCode how to work on clearmode 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 clearmode configures →

Reuse

Borrowing it

Nothing to install: this file belongs to eugeniughelbur/clearmode. 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/eugeniughelbur/clearmode/main/AGENTS.md
Clone the repo
git clone --depth 1 https://github.com/eugeniughelbur/clearmode

Made for: Codex, OpenCode.

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 clearmode AGENTS.md

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

Your own site · 80×15
<a href="https://agentmods.dev/instructions/eugeniughelbur/clearmode/agents-md"><img src="https://agentmods.dev/badge/instructions/eugeniughelbur/clearmode/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 1,110 This file is loaded in full into every session.
When invoked 1,110 The same file — it is already loaded in full.
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.01110 $0.01110
Opus 5.5 $0.00444 $0.00444
Sonnet 5.5 $0.00222 $0.00222
Haiku 4.5 $0.00111 $0.00111

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

Security

Grade A, and why

clearmode AGENTS.md 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 2mo 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.

AGENTS.md · 99 lines

How it starts

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

AGENTS.md

clearmode is the CLEAR-100 writing standard, 43 rules on 4 axes, plus the checker that scores them. These are the rules for any agent editing this repo.

The one rule that matters

rules/clear-100.json is the single source of truth. Every other rule-bearing file in this repo is generated from it.

Generated, never hand-edited:

  • SKILL.md
  • CLEAR-100.md
  • references/rules.md
  • references/lexicons.md
  • everything under targets/

To change a rule, a threshold, a word list, or a gloss:

  1. Edit rules/clear-100.json.
  2. Run python3 scripts/compile_targets.py.
  3. Run python3 -m unittest discover tests -v.
  4. Commit the JSON and the regenerated targets together.

A pull request that edits a generated file by hand gets closed.

Layout

Path What it is
rules/clear-100.json every rule, threshold, and lexicon
rules/preamble.md hand-written intro that heads CLEAR-100.md
scripts/clearcheck.py the checker, stdlib only
scripts/compile_targets.py rule pack in, 18 targets out
commands/ slash commands
tests/ unittest suite and fixtures
install.sh detects your agents and installs the right target

Constraints

  • Stdlib only. No pip, no npm, no lockfile. If a feature needs a dependency, the feature is wrong.
  • Python 3.10+. Type hints welcome, not required.
  • Deterministic. Same input, same score, every run. No model calls in the checker.
  • No em-dashes in prose. The standard bans them, so this repo cannot use them. tests/fixtures/bad.md is the exception: it exists to contain tells.
  • No emoji. Anywhere.
  • Every rule states its failure mode. A rule with no why and no fix does not ship.

Adding a rule

  1. Add the object to rules.rules[] in the JSON: id, axis, title, severity, detector, weight, why, fix, and a bad and good pair.
  2. If the detector is regex, that is all. Otherwise add a _detector method on Checker and dispatch it from run().
  3. Add a fixture case that the rule catches and one it must not.
  4. Recompile and test.

Read the full file on GitHub · 99 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. 2mo ago First seen · 99 lines · 1,110 tokens per session scan A 320a27e6804d

Subscribe to this mod's changes

clearmode AGENTS.md is an instructions file published in the GitHub repository eugeniughelbur/clearmode (3 stars, last pushed 2mo ago), licensed MIT. It adds 1,110 tokens to every session, about $0.0044 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-31.

Related

clearmode AGENTS.md compared with instructions from other repositories

clearmode AGENTS.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
clearmode AGENTS.mdeugeniughelbur/clearmodeInstructions file32mo agoMITA1,110Codex, OpenCode
ai-agent-rules-generator ui-design.instructions.mdsavedpixel/ai-agent-rules-generatorInstructions file86mo agoMITA701GitHub Copilot
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA9,719GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143ktodayMITA7,461Codex, OpenCode
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA5,516GitHub Copilot
langchain AGENTS.mdlangchain-ai/langchainInstructions file149ktodayMITA4,680Codex, OpenCode
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA3,093GitHub Copilot