rsdoctor AGENTS.md

rsdoctor AGENTS.md is an instructions file for Codex, OpenCode from web-infra-dev/rsdoctor. It costs 1,348 tokens per session, scanned A, original, MIT.

A project guide for Rsdoctor, a Node.js and TypeScript monorepo—a repository containing multiple related packages—with its tools, commands, structure, and dependency order.

In plain words
What is it for?
It helps with installing dependencies, building packages in order, running lint checks, formatting code, unit testing, and browser-based end-to-end testing.
Why use it?
It gives an AI coding assistant the project’s expected versions, build process, testing commands, and code-quality checks in one place.

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/web-infra-dev/rsdoctor/agents-md
Clone the repo
git clone --depth 1 https://github.com/web-infra-dev/rsdoctor

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

README.md
[![agentmods](https://agentmods.dev/badge/instructions/web-infra-dev/rsdoctor/agents-md.svg)](https://agentmods.dev/instructions/web-infra-dev/rsdoctor/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/web-infra-dev/rsdoctor/agents-md"><img src="https://agentmods.dev/badge/instructions/web-infra-dev/rsdoctor/agents-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 1,348 This file is loaded in full into every session.
When invoked 1,348 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.01348 $0.01348
Opus 5 $0.00674 $0.00674
Sonnet 5 $0.00270 $0.00270
Haiku 4.5 $0.00135 $0.00135

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

Security

Grade A, and why

rsdoctor 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 · 113 lines

How it starts

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

AGENTS.md

Stack

  • Node.js 22.18+, package manager pnpm 11.0+ (enable via corepack enable)
  • pnpm workspace monorepo (topological build ordering)
  • TypeScript strict mode; target node 16 for library output
  • Build toolchain: Rslib (based on Rsbuild/Rspack)
  • Lint/format: Rstack CLI (rs lint backed by Rslint, rs fmt based on Prettier)
  • Test runner: Rstest (pnpm test), E2E: Playwright (pnpm e2e)

Commands

# ── bootstrap ────────────────────────────────────────────────
pnpm install                # install all deps + build all packages (prepare hook)

# ── quality checks ───────────────────────────────────────────
pnpm lint                   # rs lint (error-level only)
pnpm format                 # rs fmt + heading-case
pnpm test                   # unit tests via rstest (single worker, NODE_OPTIONS=--max-old-space-size=8192)
pnpm e2e                    # playwright e2e (requires chromium: cd e2e && npx playwright install chromium)

# ── build ────────────────────────────────────────────────────
pnpm run build                                # build all package targets in topological order
pnpm --filter '@rsdoctor/core...' run build   # build one package and its workspace dependencies

# ── focused dev ──────────────────────────────────────────────
pnpm --filter @rsdoctor/core run build     # build one package
pnpm --filter @rsdoctor/core run test      # test one package
pnpm -C packages/client build              # alternative: use directory path

Project structure

packages/
  types/              # shared TypeScript type definitions
  utils/              # shared utilities (build / common / error / logger / ruleUtils)
  graph/              # module / chunk / package graph data structures
  sdk/                # server SDK: data collection, socket.io transport, report serving
  core/               # core analysis engine: build-utils, plugins, rules
  rspack-plugin/      # Rspack plugin (peerDep: @rspack/core)
  webpack-plugin/     # Webpack 5 plugin (peerDep: webpack 5.x)
  cli/                # `rsdoctor` CLI binary
  agent-cli/          # `@rsdoctor/agent-cli` — agent CLI tooling
  client/             # web client (Rsbuild SPA, serves analysis report and report UI)
  document/           # documentation site (Rspress)
  proto/              # protocol buffer / schema definitions
  test-helper/        # test utilities shared across packages
scripts/
  rslib.base.config.ts  # shared Rslib build config (CJS + ESM dual-package)
  rstest.setup.ts       # rstest global setup (snapshot serializer)
  tsconfig/             # shared tsconfig presets
e2e/                    # Playwright E2E tests (cases/ per bundler)
examples/               # runnable example projects (rspack / rsbuild / webpack / rspress)

Read the full file on GitHub · 113 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 · 113 lines · 1,348 tokens per session scan A 0e293c12efd1

Subscribe to this mod's changes

rsdoctor AGENTS.md is an instructions file published in the GitHub repository web-infra-dev/rsdoctor (1,139 stars, last pushed 4d ago), licensed MIT. It adds 1,348 tokens to every session, about $0.0067 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-30.