rulemorph AGENTS.md

rulemorph AGENTS.md is an instructions file for Codex, OpenCode from vinhphatfsg/rulemorph. It costs 1,663 tokens per session, scanned A, original, MIT.

A repository instruction file named AGENTS.md. It tells coding agents which language and writing rules to follow, where project parts are located, and which checks to run after changes.

In plain words
What is it for?
Use it to guide work in the RuleMorph repository, including Rust, its web interface, documentation, releases, and end-to-end tests.
Why use it?
It gives agents the project’s working rules in one place, reducing changes that conflict with the repository’s tests, documentation, or release process.

Instructions file for CodexOpenCode

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.

agentmods
npx agentmods add instructions/vinhphatfsg/rulemorph/agents-md
Clone the repo
git clone --depth 1 https://github.com/vinhphatfsg/rulemorph

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

README.md
[![agentmods](https://agentmods.dev/badge/instructions/vinhphatfsg/rulemorph/agents-md.svg)](https://agentmods.dev/instructions/vinhphatfsg/rulemorph/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/vinhphatfsg/rulemorph/agents-md"><img src="https://agentmods.dev/badge/instructions/vinhphatfsg/rulemorph/agents-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 1,663 This file is loaded in full into every session.
When invoked 1,663 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
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 $0.01663 $0.01663
Opus 5 $0.00831 $0.00831
Sonnet 5 $0.00333 $0.00333
Haiku 4.5 $0.00166 $0.00166

Measured 3d ago against content hash 312f5f132f5b, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

rulemorph 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 3d 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 · 82 lines

How it starts

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

Repository Guidelines

Language

  • 返答、docs、plans は日本語 first。英語は明示された場合だけ使う。
  • 用語は docs/glossary.md を優先する。
  • ユーザー向け docs / README / spec では、MVP、内部フェーズ名、実装計画上の呼び名など、ユーザーに関係しない表現を使わない。現状の仕様事実、使い方、制約だけを書く。

Always

  • 既存の仕様、fixtures、tests、README と矛盾する変更をしない。
  • Rust 実装を変更したら必ず cargo fmtcargo test を実行する。
  • release workflow / packaging / version bump / embedded-ui を変更したら scripts/verify-release-build.sh を実行する。
  • UI を変更したら npm --prefix crates/rulemorph_ui/ui run test とブラウザ確認を実行する。
  • UI の end-to-end behavior / Trace Console / import flow を変更したら npm --prefix crates/rulemorph_ui/ui run test:e2e も実行する。
  • 大きい挙動変更では、先に該当 guide を読み、必要な invariant と tests を確認する。
  • docs-only 変更では、実装・tests・workflow の挙動を変えない。

Project Map

  • crates/rulemorph: core library。rule parsing、validation、normalization、transform engine。
  • crates/rulemorph_cli: CLI binary。
  • crates/rulemorph_mcp: MCP stdio server。tools、resources、prompts。
  • crates/rulemorph_endpoint: endpoint/network rule engine。HTTP endpoint 変換、network request 実行、trace graph 生成。
  • crates/rulemorph_server: local/API server と UI 配信。
  • crates/rulemorph_trace: trace bundle の永続化、import/export、storage/query helper。
  • crates/rulemorph_ui: embedded-ui 用 frontend assets。
  • docs/: rule specs、design docs、roadmap、agent guides。
  • crates/*/tests: crate ごとの integration tests と fixtures。

Coding Style

  • Rust は rustfmt default に従う。手動で独自整形しない。
  • 命名は Rust 慣例を優先する。functions/modules は snake_case、types は CamelCase、constants は SCREAMING_SNAKE_CASE
  • rule specs、examples、fixtures は docs/ の仕様と矛盾させない。

Design & Code Organization

  • code は simple and direct に保つ。clever abstraction より、小さく読める関数と明示的な control flow を優先する。
  • file が読みにくくなる前に責務を分割する。parsing、validation、execution、tracing、persistence、presentation が同じ module に混ざる場合は、明確な名前の focused submodule へ抽出する。
  • file length は maintainability signal として扱う。通常の source file は実用上 200-400 行程度を目安にし、400 行を超えたら責務分割を積極的に検討する。600 行超は、cohesive ownership、generated/schema-like content、tests/fixtures などの理由がある場合だけ例外とする。
  • file hierarchy は実装上の偶然ではなく domain responsibility に合わせる。reader が feature / concept 名から owning module を見つけられる構成にする。
  • broad utility modules や catch-all files を避ける。shared helper は narrow purpose にし、真に cross-cutting でない限り primary caller の近くに置く。
  • abstraction は、実際の重複を減らす、ownership を明確にする、public/internal boundary を安定させる場合だけ追加する。generalized に見せるための layer は追加しない。
  • public API surface は小さく保つ。internal seam は pub(crate) を優先し、user や他 crate 向けに意図した型・関数だけを expose する。
  • large file refactor では、可能な限り mechanical move と behavior change を分ける。split 後も既存 semantics を証明する tests を維持する。

Read the full file on GitHub · 82 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. 3d ago First seen · 82 lines · 1,663 tokens per session scan A 312f5f132f5b

Subscribe to this mod's changes

rulemorph AGENTS.md is an instructions file published in the GitHub repository vinhphatfsg/rulemorph (2 stars, last pushed 2mo ago), licensed MIT. It adds 1,663 tokens to every session, about $0.0083 per session on Opus 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.