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.
npx agentmods add instructions/guokaigdg/react-seed/agents-mdgit clone --depth 1 https://github.com/guokaigdg/react-seedWhat 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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.05007 | $0.05007 |
| Opus 5 | $0.02504 | $0.02504 |
| Sonnet 5 | $0.01001 | $0.01001 |
| Haiku 4.5 | $0.00501 | $0.00501 |
Grade A, and why
react-seed 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.
How it starts
The opening of the file, as written. The whole thing — 404 lines — stays where its author put it; the contents beside it link to each section on GitHub.
AGENTS.md
本文档面向 AI 编码助手(Claude / Cursor / Comate / Copilot 等),用于在最短时间内建立对本仓库的准确认知,并在生成 / 修改代码时遵守一致的工程约定。人类读者请优先阅读
README.md与docs/README.en.md。
目录
1. 项目概览
react-seed 是一套企业级 React SPA 前端模板,目标是为新业务直接复用其工程化基建(Vite / TS / 路由 / 状态 / 请求 / 规范)。
- 类型:单页应用(SPA),构建产物为静态文件,可通过
gh-pages一键发布 - 入口:
src/index.tsx→src/App.tsx→src/router/index.tsx - 在线 Demo:https://guokaigdg.github.io/react-seed/
- 姊妹分支:移动端版
本仓库不是业务项目;新增内容时优先思考是否对模板"通用"。
2. 技术栈
| 分类 | 选型 | 版本 / 备注 |
|---|---|---|
| 框架 | React + ReactDOM | 19.x(启用 react-jsx 自动 JSX 运行时,无需 import React) |
| 语言 | TypeScript | 5.x,strict: true,并启用 noUnusedLocals / noUnusedParameters |
| 构建 | Vite 8 + @vitejs/plugin-react |
配置位于 vite.config.ts(根目录,Vite 8 默认 Rolldown 打包) |
| 开发服务 | vite 内置 dev server |
端口 3000;server.host: true |
| 路由 | react-router |
v7,从 react-router 导入(不是 react-router-dom) |
| 状态管理 | MobX + mobx-react-lite |
mobx 6 / lite 4,enforceActions: 'always' |
| 网络请求 | axios + axios-retry |
全局封装见 src/api/request.ts |
| 样式 | Less + CSS Modules | Vite 内置,*.module.less 自动开启 CSS Modules |
| 图标 | @phosphor-icons/react + 本地 svg as React 组件(vite-plugin-svgr) |
svg 资源:src/assets/icons/svg/ |
| 代码质量 | ESLint 9(flat config)+ Prettier + Stylelint + husky + lint-staged + commitlint | 配置:eslint.config.mjs |
| 环境变量 | Vite .env.[mode] |
三套环境:development / qa / production,通过 import.meta.env 访问 |
| Node | ≥ 22.22.1;npm ≥ 7;volta 固定 22.22.3 | 见 package.json#engines / volta |
3. 目录结构
react-seed/
├── vite.config.ts # Vite 配置(alias / plugins / build / server)
├── index.html # Vite 入口 HTML(根目录,引用 /src/index.tsx)
├── public/
│ └── favicon.ico # 静态资源(不参与构建处理)
├── src/
│ ├── index.tsx # ReactDOM.createRoot 挂载
│ ├── App.tsx # 根组件,BrowserRouter + useRoutes
│ ├── vite-env.d.ts # Vite 类型与 import.meta.env 声明
│ ├── router/
│ │ ├── index.tsx # 集中式路由表(React.lazy + SuspenseLazy)
│ │ └── README.md
│ ├── api/
│ │ ├── request.ts # axios 实例 + 拦截器 + 重试封装
│ │ ├── home-two/ # 按页面拆分接口目录
│ │ │ ├── index.ts
│ │ │ └── types/home-two.ts
│ │ ├── home-order/
│ │ └── README.md
│ ├── store/ # MobX
│ │ ├── index.ts # configure + stores 聚合 + Context + useStores
│ │ ├── global/index.ts
│ │ └── about/index.ts
│ ├── components/ # 通用组件(每个组件一个目录 + barrel 导出)
│ │ ├── Button/ # 含 buttonHelpers.tsx
│ │ ├── Card/
│ │ ├── SuspenseLazy/ # 懒加载高阶
│ │ └── index.ts # 统一 export
│ ├── view/ # 页面级组件
│ │ ├── Home/ # 含 7 个子页面(One/Two/Three/Four/Mobx/Icon/Order)
│ │ ├── Dashboard/
│ │ ├── About/ # 演示 index.module.less(CSS Modules)
│ │ ├── Tab/ # 顶部导航
│ │ └── NotFound/
│ ├── constants/ # 常量与枚举(enum.ts)
│ ├── interface/ # 业务 TS 类型说明(含 index.md)
│ ├── types/ # 全局 .d.ts:api / file / style
│ ├── utils/
│ │ ├── useHook/useRequest.ts # 自研 hook:请求 + loading + 错误
│ │ ├── validate.ts
│ │ └── variable.ts
│ ├── assets/ # 图片、svg(icons/svg/* 通过 ?react 后缀作为 React 组件引入)
│ └── styles/index.less # 全局样式入口
├── docs/ # 设计文档(含 ui.md / data.md / README.en.md)
├── .env.development # 开发环境变量
├── .env.qa # QA 环境变量
├── .env.production # 生产环境变量
├── eslint.config.mjs # ESLint 9 flat config
├── tsconfig.json # path alias + 严格模式
├── package.json
└── README.md
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.
- 3d ago First seen · 404 lines · 5,007 tokens per session scan A a009970d9d1a
react-seed AGENTS.md is an instructions file published in the GitHub repository guokaigdg/react-seed (530 stars, last pushed 24d ago), licensed MIT. It adds 5,007 tokens to every session, about $0.0250 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.
Other instructions, from other repositories
Kokoro-Engine CLAUDE.md
Instructions for chyinan/Kokoro-Engine, covering claude.md, git 规范, 项目概述, 常用命令 and 安装依赖.
weaverse copilot-instructions.md
Instructions for Weaverse/weaverse, covering copilot instructions, coding standards, typescript guidelines, react guidelines and error handling.
patternfly-react-seed AGENTS.md
Instructions for patternfly/patternfly-react-seed, covering agent instructions (patternfly react seed), what this project is, stack, commands to run before you consider work done and repository layout.
lovable-boilerplate development.instructions.md
Instructions for chihebnabil/lovable-boilerplate, covering development workflow & commands, essential commands, critical workflow rules, before shipping and never ship.
forklift-console-plugin AGENTS.md
Instructions for kubev2v/forklift-console-plugin, covering ai assistant guidelines for forklift console plugin, code style & conventions, typescript, react and patternfly components.
react-fetch-streams AGENTS.md
Instructions for rolandjitsu/react-fetch-streams, covering agents.md, workflow, writing: code, comments, docs, commits, commits and tests.