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/chinawsb/daofy/agents-mdgit clone --depth 1 https://github.com/chinawsb/daofyWrote 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/chinawsb/daofy/agents-md)<a href="https://agentmods.dev/instructions/chinawsb/daofy/agents-md"><img src="https://agentmods.dev/badge/instructions/chinawsb/daofy/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 | $0.07024 | $0.07024 |
| Opus 5 | $0.03512 | $0.03512 |
| Sonnet 5 | $0.01405 | $0.01405 |
| Haiku 4.5 | $0.00702 | $0.00702 |
Grade A, and why
daofy AGENTS.md scanned grade A with 1 finding 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 4d 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.
Runs shell commandslowCapability
Expected in a hook, worth knowing in a rule or an instructions file.
| 1.1 | 命令/Shell 注入 | `subprocess`/`Popen`/`os.system` 参数拼接用户输入 → 必须用列表参数 `["cmd", arg]`,禁用 `shell=True` 传参 | How it starts
The opening of the file, as written. The whole thing — 429 lines — stays where its author put it; the contents beside it link to each section on GitHub.
AGENTS.md - Agent Coding Guidelines
Daofy — Python 3.10-3.14, Windows, pytest.
Quick Command Reference
| Action | Command |
|---|---|
| Install deps | pip install -r requirements.txt && pip install -e ".[dev]" |
| Install file watcher | pip install daofy-for-delphi[watcher] (可选,自动增量 KB) |
| Install embedding | pip install daofy-for-delphi[embedding] (可选,语义搜索) |
| Run all tests | pytest (or python tests/run_all_tests.py for basic) |
| Run one test | pytest tests/test_validator.py -v |
| Lint/type | mypy src/ |
| Environment | Always set $env:PYTHONIOENCODING='utf-8' on Windows |
| Run server | python src/server.py |
Project Structure
src/
├── server.py # MCP entry point
├── plugins/ # Language plugin system (base, registry, delphi/, lazarus/, core/)
├── tools/ # MCP tool implementations (delphi_file, code_hosting, delphi_project, delphi_kb, ...)
├── services/ # Business logic
│ ├── compiler_service.py, config_manager.py, process_manager.py, args_generator.py
│ ├── automation_service.py # Delphi GUI/Console 自动化测试服务
│ ├── copyright_service.py # 软著文档生成服务
│ ├── delphi_edit_guard.py # Delphi 文件编辑保护(脏标记检测)
│ ├── experience_service.py # AI 经验记忆管理服务
│ ├── ocr_service.py # 图像分析服务
│ ├── rtti_bridge.py # Delphi RTTI 桥接服务
│ └── knowledge_base/ # KB modules (schema, smart_cache, project, thirdparty, scan, embedding, async_task_manager)
├── models/ # Pydantic/dataclass models
└── utils/ # Utilities (delphi_env, dproj_parser, lpi_parser, validator, logger, parser)
知识库自动生命周期
项目知识库(.delphi-kb/)有以下自动化机制:
| 机制 | 触发时机 | 说明 |
|---|---|---|
| 启动时自动构建 | MCP Server 启动 | 自动检测 CWD 下的 .dproj,提交后台增量 KB 构建(不阻塞 MCP 就绪) |
| 热切换重建 | 用户手动 rebuild | 构建到临时目录 .delphi-kb-tmp-{ts}/,旧 KB 在构建期间保持可查,构建完成原子 swap |
| 文件变更监听 | 用户保存 .pas/.dfm/.dproj 等 |
需要 pip install daofy-for-delphi[watcher],3秒去抖后自动触发增量更新 |
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.
- 4d ago First seen · 429 lines · 7,024 tokens per session scan A 895d3dc322be
daofy AGENTS.md is an instructions file published in the GitHub repository chinawsb/daofy (101 stars, last pushed yesterday), licensed MIT. It adds 7,024 tokens to every session, about $0.0351 per session on Opus 5. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other instructions, from other repositories
wisp-science AGENTS.md
AGENTS.md instructions for xuzhougeng/wisp-science, covering agents.md, project orientation, repository layout, engineering rules and verification commands.
Cerebro AGENTS.md
Instructions for AgenticFirst/Cerebro, covering cerebro — agent context, read before touching integrations, project layout, conventions a fresh agent would otherwise miss and running locally.
delphi-spec-kit AGENTS.md
Instructions for delphicleancode/delphi-spec-kit, covering delphi ai spec-kit — agents.md, language and stack, naming conventions — pascal guide, general rule and mandatory prefixes.
discoclaw CLAUDE.md
Instructions for DiscoClaw/discoclaw, covering discoclaw, safety, context loading (strict), identity and workspace file ownership.
nextjs-skills CLAUDE.md
Instructions for mohamed-hossam1/nextjs-skills: All contribution rules — style, naming, file layout, verification — live in AGENTS.md. Read that first.
coworker CLAUDE.md
Instructions for Array-Ventures/coworker: This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.