Borrowing it
Nothing to install: this file belongs to shenjingnan/xiaozhi-client. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/shenjingnan/xiaozhi-client/main/AGENTS.mdgit clone --depth 1 https://github.com/shenjingnan/xiaozhi-clientWrote 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.
[](https://agentmods.dev/instructions/shenjingnan/xiaozhi-client/agents-md)<a href="https://agentmods.dev/instructions/shenjingnan/xiaozhi-client/agents-md"><img src="https://agentmods.dev/badge/instructions/shenjingnan/xiaozhi-client/agents-md.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.05523 | $0.05523 |
| Opus 5 | $0.02762 | $0.02762 |
| Sonnet 5 | $0.01105 | $0.01105 |
| Haiku 4.5 | $0.00552 | $0.00552 |
Grade A, and why
xiaozhi-client 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 8d 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 — 514 lines — stays where its author put it; the contents beside it link to each section on GitHub.
CLAUDE.md
本文件为 Claude Code (claude.ai/code) 在此代码仓库中工作时提供指导。
开发理念
核心原则
- 功能驱动:如无必要勿增实体,需要什么功能就实现什么功能
- 优雅实现:代码要清晰、可维护、结构合理
- 避免过度设计:不提前考虑竞态、并发、互斥锁、缓存等复杂概念
- 架构合理:整体架构要有逻辑性,但不引入不必要的抽象层
- 确认优先:当不确认时询问用户,不做自作主张的决策
开发哲学
- 先实现,后优化:先把功能做好,再考虑性能优化
- 实用主义:解决实际问题比理论完美更重要
- 简单直接:避免为了工程化而工程化
- 渐进改进:遇到问题再优化,不过度预防
开发命令
构建和测试
pnpm build- 构建项目(包括 Web 构建和 TypeScript 编译)pnpm dev- 开发模式(带监视功能)pnpm test- 运行一次测试pnpm test:coverage- 运行测试并生成覆盖率报告
代码质量
pnpm lint- 运行 Biome linterpnpm lint:fix- 运行 Biome linter 并自动修复(包括格式化)pnpm typecheck- 运行 TypeScript 类型检查pnpm check:all- 运行所有质量检查(lint、typecheck、spellcheck、duplicate check)
其他质量工具
pnpm spellcheck- 使用 cspell 检查拼写pnpm check:cpd- 使用 jscpd 检查重复代码pnpm dev:docs- 启动文档开发服务器
Git Hooks(Pre-commit)
项目配置了 husky + lint-staged + commitlint,在 git commit 时自动执行以下检查:
- pre-commit: 对暂存的文件自动执行 lint 和格式化
*.{ts,tsx,json}→biome check --write(自动修复并重新暂存)*.{md,mdx}→cspell拼写检查
- commit-msg: 校验 commit message 符合 Conventional Commits 规范
注意: 紧急情况下可使用
git commit --no-verify跳过 hooks,但不建议日常使用。
发布
项目使用 release-it 进行版本发布,配合 @release-it/conventional-changelog 自动生成 CHANGELOG。
标准发布流程
# 发布指定版本(正式版)
pnpm release 2.4.0 --ci
# 发布 Beta 版本
pnpm release:beta
# 或指定预发布版本号
pnpm release 2.4.0-beta.0 --preRelease=beta --ci
# 快捷发布(自动 bump patch/minor/major)
pnpm release:patch # 2.3.0 → 2.3.1
pnpm release:minor # 2.3.0 → 2.4.0
pnpm release:major # 2.3.0 → 3.0.0
自动执行
- 验证工作目录是否干净
- 更新 package.json 版本号
- 生成/更新 CHANGELOG.md(基于 Conventional Commits)
- 创建 Git commit 和 tag
- 推送代码和 tag 到远程仓库(
--ci模式) - 创建 GitHub Release
- GitHub Actions 自动执行 npm publish
预演模式
# 预演发布流程(不实际执行任何操作)
pnpm release:dry
仅本地更新(不推送)
# 显式关闭 push 和 GitHub release,避免交互过程中误推送
pnpm release 2.4.0 --git.push=false --github.release=false
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.
- 8d ago First seen · 514 lines · 5,523 tokens per session scan A a988139de0f4
xiaozhi-client AGENTS.md is an instructions file published in the GitHub repository shenjingnan/xiaozhi-client (337 stars, last pushed 4d ago), licensed MIT. It adds 5,523 tokens to every session, about $0.0276 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
codex AGENTS.md
AGENTS.md instructions for openai/codex, covering rust/codex-rs, the codex-core crate, code review rules, crate api surface and model visible context.
vscode buildNext.instructions.md
Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).
next.js AGENTS.md
AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.
langchain AGENTS.md
AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, applying the notice (cutover) and fallback chain (never fail the build).
spec-kit AGENTS.md
AGENTS.md instructions for github/spec-kit, covering agents.md, about spec kit and specify, quickstart — add a new integration in 5 steps, integration architecture and integrationmanifest — file tracking.