Agent skill

Codex Rules Reference

by code-yeongyu in code-yeongyu/oh-my-openagent

Explains how the Codex Rules plugin injects project instructions and file-specific rules into a session, which rule files it reads and which settings control it.

Custom licenceAuto-check passedAgent Workflows

Install Codex Rules Reference

skills CLI
$ npx skills add code-yeongyu/oh-my-openagent --skill rules -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install code-yeongyu/oh-my-openagent rules --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/code-yeongyu/oh-my-openagent.git skills-src && mkdir -p .claude/skills && cp -r skills-src/packages/omo-codex/plugin/components/rules/skills/rules .claude/skills/rules && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
rules
GitHub stars
70k
Token cost
~269 tokens
SKILL.md length
80 words
Files
1
Skills in repo
45
Repo updated
First seen
Licence
Custom licence

At a glance

Explains how the Codex Rules plugin injects project instructions and file-specific rules into a session, which rule files it reads and which settings control it.

  • Finding out which rule files Codex Rules reads
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md
  • Turning rule injection off or limiting it with environment variables
  • Working out why a file-specific rule did or did not appear after a patch

What it does

Once the plugin is enabled, Codex Rules works automatically. It injects static project instructions at `SessionStart` and `UserPromptSubmit`, and by default adds matching file-specific rules after a Codex `apply_patch`. Dynamic `PostToolUse` output is passed in as extra context and deduplicated per plugin data session. The plugin does not rewrite tool output.

Rules are read from `CONTEXT.md`, `.omo/rules`, `.claude/rules`, `.cursor/rules`, `.github/instructions` and `.github/copilot-instructions.md`. Behavior is tuned with `CODEX_RULES_` variables: one to disable the plugin, a mode with the values both, static, dynamic or off, limits on rule and result length, and a list of enabled sources. Older `PI_RULES_` variables still work as fallbacks for people moving from `pi-rules`.

When your agent uses it

  • Finding out which rule files Codex Rules reads
  • Turning rule injection off or limiting it with environment variables
  • Working out why a file-specific rule did or did not appear after a patch

Example prompts

  • “Which folders does Codex Rules read project rules from?”
  • “Set Codex Rules to static mode so rules are only injected at session start.”
  • “Why wasn't my .cursor rule injected after the last apply_patch?”

Requirements

  • The Codex Rules plugin, enabled

What it can do on your machine

Read from SKILL.md and the folder at commit ab81169. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md.

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Codex Rules Reference loads about 269 tokens when it runs. Until then it costs about 38 tokens; SKILL.md has 80 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~38
When it runs · the whole SKILL.md, loaded when a task matches
~269

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

Its licence (Custom licence) doesn't allow us to republish the file, so here is its outline and opening line. It has 80 words (~269 tokens).

“Codex Rules is automatic once the plugin is enabled. It injects:”

— opening of SKILL.md by code-yeongyu, Custom licence
name
rules

Read the full SKILL.md on GitHub

Files

Just SKILL.md in packages/omo-codex/plugin/components/rules/skills/rules of code-yeongyu/oh-my-openagent.

Open the folder on GitHubat commit ab81169

Used in 1 other repository

We found 2 copies of this SKILL.md (exact, near-identical or edited) in other folders. This page covers the copy in code-yeongyu/oh-my-openagent, which our catalogue first saw on October 7, 2026.

Compare with similar skills

Codex Rules Reference next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Codex Rules Reference compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Codex Rules Reference this skillcode-yeongyu/oh-my-openagent70k—~269Automated safety check: PassCustom licence
Agent Setup Health Audittw93/Waza7.2k—~5.2kAutomated safety check: NotesMIT
Working With Claude Code Docsobra/superpowers-developing-for-claude-code142—~1.5kAutomated safety check: PassNone
Directional Promptingkingbootoshi/directional-prompting143—~2.3kAutomated safety check: PassMIT
Agenticashibing624/agentica352—~1.8kAutomated safety check: NotesApache-2.0
Claude Code Mastery Squadohmyjahh/xquads-squads276—~1.1kAutomated safety check: PassMIT

Similar skills

  • Audits a project's agent configuration, instruction drift, hooks, MCP and AI maintainability, then reports prioritized findings with evidence and next actions.

    7.2k GitHub stars~5.2k tokensUpdated yesterday
    Agent WorkflowsAuto-check: notes
  • Working With Claude Code Docs

    obra/superpowers-developing-for-claude-code

    Looks up official Claude Code documentation stored as reference files instead of guessing about CLI commands, configuration, or plugin APIs.

    142 GitHub stars~1.5k tokensUpdated 10 mo ago
    Agent WorkflowsAuto-check passed
  • Directional Prompting

    kingbootoshi/directional-prompting

    Write prompts, system instructions, agent directives, slash commands, and skill descriptions using two stacked layers — outcome-first (define the destination, success criteria, stopping condition)…

    143 GitHub stars~2.3k tokensUpdated 4 mo ago
    Agent WorkflowsAuto-check passed
  • Agentica

    shibing624/agentica

    How to answer questions about the agentica product you are running inside — CLI flags, config.yaml profiles, API keys, models, sessions, resume, workspace, AGENTS.md standing rules, skills, logs…

    352 GitHub stars~1.8k tokensUpdated 15 days ago
    Agent WorkflowsAuto-check: notes
  • Claude Code Mastery Squad

    ohmyjahh/xquads-squads

    Routes a request to one of eight specialist agents covering hooks, skills, subagents, MCP integration and context engineering for Claude Code.

    276 GitHub stars~1.1k tokensUpdated 9 days ago
    Agent WorkflowsAuto-check passed
  • Vault Setup

    earlyaidopters/second-brain

    Interactive Obsidian vault configurator. An agent skill from earlyaidopters/second-brain.

    193 GitHub stars~1.4k tokensUpdated 6 mo ago
    Agent WorkflowsAuto-check passed

More from code-yeongyu/oh-my-openagent

All 45 skills in this repo
  • Browser Control with Omowright

    code-yeongyu/oh-my-openagent

    Drives a real browser through the omowright library, either the user's own signed-in browser or a separate browser the code launches, for forms, QA, screenshots and scraping.

    70k GitHub starsUsed in 1 repo~2.2k tokens
    Auto-check passed
  • Codex Plugin QA

    code-yeongyu/oh-my-openagent

    Tests the omo Codex plugin in an isolated CODEX_HOME with a local mock model, proving hooks fired through app-server notifications without touching ~/.codex.

    70k GitHub starsUsed in 1 repo~1.9k tokens
    Auto-check passed
  • Coding Agent Session Finder

    code-yeongyu/oh-my-openagent

    Finds, reads and reconstructs past coding-agent sessions across Codex, Claude, OpenCode, Senpi and many other local agent logs.

    70k GitHub starsUsed in 1 repo~2.8k tokens
    Auto-check passed
  • ast-grep Structural Search

    code-yeongyu/oh-my-openagent

    Searches and rewrites code by syntax-tree shape across 25 languages with ast-grep, for codemods, structural queries and YAML lint rules, using a Python wrapper script.

    70k GitHub stars~3.3k tokensUpdated today
    Auto-check passed
  • LSP Setup

    code-yeongyu/oh-my-openagent

    Detects which languages a project uses, installs the matching language server, writes its config and checks it with a real call so diagnostics and go-to-definition work.

    70k GitHub stars~1.4k tokensUpdated today
    Auto-check: notes
  • OpenCode QA Toolkit

    code-yeongyu/oh-my-openagent

    Tests the opencode coding agent itself: its CLI, server, plugin hooks and events, the terminal UI under tmux, and its SQLite session database, using tested helper scripts.

    70k GitHub stars~2.9k tokensUpdated today
    Auto-check passed

Categories

Questions about Codex Rules Reference

What does Codex Rules Reference do?

Explains how the Codex Rules plugin injects project instructions and file-specific rules into a session, which rule files it reads and which settings control it. Once the plugin is enabled, Codex Rules works automatically. It injects static project instructions at `SessionStart` and `UserPromptSubmit`, and by default adds matching file-specific rules after a Codex `apply_patch`.

When should I use Codex Rules Reference?

Codex Rules Reference fits situations like: finding out which rule files Codex Rules reads; turning rule injection off or limiting it with environment variables; working out why a file-specific rule did or did not appear after a patch.

How do I install Codex Rules Reference in Claude Code?

Run `npx skills add code-yeongyu/oh-my-openagent --skill rules -a claude-code`. Or copy the skill folder (packages/omo-codex/plugin/components/rules/skills/rules in code-yeongyu/oh-my-openagent) into .claude/skills/rules in your project. Claude Code loads it when a task matches its description.

How do I install Codex Rules Reference in Codex?

Run `npx skills add code-yeongyu/oh-my-openagent --skill rules -a codex`. Or copy the skill folder (packages/omo-codex/plugin/components/rules/skills/rules in code-yeongyu/oh-my-openagent) into .agents/skills/rules in your project. Codex loads it when a task matches its description.

Can I use Codex Rules Reference in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add code-yeongyu/oh-my-openagent --skill rules -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/rules, .gemini/skills/rules, .github/skills/rules and .opencode/skills/rules in your project.

What does Codex Rules Reference need to run?

SKILL.md names no scripts, command-line tools or credentials: Codex Rules Reference is instructions for the agent only. Our summary lists: The Codex Rules plugin, enabled.

Does Codex Rules Reference access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Codex Rules Reference safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Codex Rules Reference use?

Codex Rules Reference has a licence file (the repository's licence) that doesn't match a standard licence. Read it on GitHub before reusing the skill.

How many tokens does Codex Rules Reference use?

About 269 tokens (SKILL.md is roughly 1.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Codex Rules Reference?

Skills that share tags, products or a category with Codex Rules Reference: Agent Setup Health Audit (tw93/Waza, 7.2k stars), Working With Claude Code Docs (obra/superpowers-developing-for-claude-code, 142 stars), Directional Prompting (kingbootoshi/directional-prompting, 143 stars) and Agentica (shibing624/agentica, 352 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Codex Rules Reference?

code-yeongyu (a GitHub user) maintains it in code-yeongyu/oh-my-openagent, which has 69,882 GitHub stars. The repository holds 45 skills in this directory. The repository was last updated on October 8, 2026.

Source: code-yeongyu/oh-my-openagent on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.