codex-docs: Instructions file for Codex

AGENTS.md

codex-docs AGENTS.md is an instructions file for Codex, OpenCode from chenrui333/codex-docs. It costs 1,283 tokens per session, scanned A, original, MIT.

Repository instructions for a project that periodically mirrors Codex documentation and related reference files.

In plain words
What is it for?
They help run setup, linting, tests, synchronization, idempotence checks, and feature-flag validation with the project's preferred commands.
Why use it?
They clarify which files are generated, where to fix synchronization problems, and how to validate changes safely.

Instructions file for CodexOpenCode

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

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

Reuse

Borrowing it

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

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 codex-docs AGENTS.md

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

Your own site · 80×15
<a href="https://agentmods.dev/instructions/chenrui333/codex-docs/agents-md"><img src="https://agentmods.dev/badge/instructions/chenrui333/codex-docs/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 1,283 This file is loaded in full into every session.
When invoked 1,283 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.01283 $0.01283
Opus 5.5 $0.00513 $0.00513
Sonnet 5.5 $0.00257 $0.00257
Haiku 4.5 $0.00128 $0.00128

Measured 19d ago against content hash a41305365f92, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

codex-docs 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 19d 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 · 66 lines

How it starts

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

AGENTS Notes

Scope

  • This repository is a periodic mirror for Codex-related docs and references.
  • Keep changes focused on sync automation, output quality, and release hygiene.

Generated content boundaries

  • Treat docs/codex_capabilities.json, docs/codex_cli_surface.json, docs/cli-surface/**, docs/codex_models.json, docs/docs_manifest.json, docs/sync_summary.json, docs/source_coverage.json, docs/freshness.json, docs/developers.openai.com/**, docs/learn.chatgpt.com/**, docs/feature-flags/**, docs/github.openai.com/**, docs/platform.openai.com/**, dot_codex/skills/dot_system/**, system_prompts/codex-cli/**, weekly/events/**, and weekly/YYYY-MM-DD.md as generated output.
  • Do not hand-edit mirrored docs, skills, or prompts unless doing a temporary emergency fix.
  • Fix the responsible generator and regenerate affected output. scripts/fetch_codex_docs.py coordinates sync; scripts/model_catalog.py, scripts/cli_observations.py, and scripts/semantic_history.py own the pure model, platform, and event transformations. scripts/collect_cli_surface.py collects help observations; scripts/snapshot_feature_flags.py builds feature snapshots.

Local workflow

  1. Preferred command runner: use just.
  2. Setup environment:
    • just setup
  3. Run offline quality checks:
    • just lint
    • just test
  4. Run sync:
    • just sync for full source discovery, or just sync-release for strict release-only generation using a verified existing web mirror.
  5. Validate local idempotence + scope:
    • just check-strict for two full strict syncs, freshness, idempotence, and changed-file scope. just check is the non-strict local variant.
  6. For feature-flag snapshot changes:
    • just feature-flags
    • just check-feature-flags

Validation expectations

  • After changing sync logic, run sync twice and confirm second run is idempotent (no new diffs).
  • Verify docs/docs_manifest.json and docs/sync_summary.json are updated consistently, including Codex CLI version metadata for CLI-backed changes.
  • The manifest fails closed when invalid (or missing while coverage exists) and is the transaction's commit point: write it last and atomically, and advance summary and coverage only after it. A rerun must reconcile every managed file to the plan.
  • Verify docs/source_coverage.json updates consistently and includes expected counts, including complete ChatGPT Learn discovery and mirror coverage.
  • Preserve existing events in weekly/events/YYYY-MM-DD.json; daily Markdown is their deterministic rollup. Repeated identical syncs must add neither events nor timestamp-only changes. Do not rewrite older daily reports during migration.
  • Keep web content provenance independent of CLI releases. Existing web-page CLI-version lists are frozen historical observations; new web pages must not acquire them.
  • Model catalogs and feature snapshots must match the CLI release tag and immutable source commit. Model provenance mismatches fail freshness even inside the release-lag grace period.
  • CLI removals require a newer descendant release on every previously observed platform. Unknown/divergent ancestry or an unavailable collector must retain last-known-good evidence; semantic history must not report false removals.
  • Run CLI introspection in temporary isolated homes with sanitized subprocess environments; never capture real credentials, sessions, history, or inherited GitHub tokens.
  • Keep the repository otherwise unchanged while just check-strict runs: its scope check snapshots the whole working tree.
  • For feature-flag automation or source-input changes, verify docs/feature-flags/** with just check-feature-flags; snapshots must use the source commit resolved from the CLI release tag.

Read the full file on GitHub · 66 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. 19d ago Changed · +1 lines · +50 tokens per session a41305365f92
  2. 2mo ago Changed · +9 lines · +484 tokens per session 4bf15008a7da
  3. 2mo ago First seen · 56 lines · 749 tokens per session scan A a69162d0c8b0

Subscribe to this mod's changes

codex-docs AGENTS.md is an instructions file published in the GitHub repository chenrui333/codex-docs (5 stars, last pushed today), licensed MIT. It adds 1,283 tokens to every session, about $0.0051 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

codex-docs AGENTS.md compared with instructions from other repositories

codex-docs AGENTS.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
codex-docs AGENTS.mdchenrui333/codex-docsInstructions file5todayMITA1,283Codex, OpenCode
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
deepseek-harness AGENTS.mddeepseek-ai/deepseek-harnessInstructions file275k3d agoMITA4,313Codex, OpenCode