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/superops-team/okf/agents-mdgit clone --depth 1 https://github.com/superops-team/okfWhat 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.02221 | $0.02221 |
| Opus 5 | $0.01111 | $0.01111 |
| Sonnet 5 | $0.00444 | $0.00444 |
| Haiku 4.5 | $0.00222 | $0.00222 |
Grade A, and why
okf 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 2d 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 — 73 lines — stays where its author put it; the contents beside it link to each section on GitHub.
AGENTS.md — OKF 项目开发规范
项目概述
okf 是 Go 实现的 OKF(Open Knowledge Format)v0.2 知识库工具链,包含 CLI(cmd/okf)、解析/校验/查询核心(pkg/parser、pkg/lint、pkg/query、pkg/okf)、Git 集成(pkg/git)、MCP 服务器(pkg/mcp)。知识库以 Markdown 概念文件 + frontmatter 组织,遵循「一切皆 .md 概念」心智模型。当前开发分支为 main,变更管理走 openspec/changes/<change-id>/(SDD)。
常用命令
- 构建:
go build ./... - 静态检查:
go vet ./...、staticcheck ./... - 全量测试:
go test ./...、并发检测go test ./... -race、随机序go test -shuffle=on ./... - 单测:
go test ./pkg/convert -run TestConvertPDF -v - 知识库校验:
okf lint(docs/knowledge应 0 errors) - MCP 端到端:
python3 test_mcp.py - 环境硬约束:Go
1.26.0(toolchain go1.26.7);文档转换依赖 downmark v0.10.0 精确锁定(go.mod 非浮动) - 约束栈总入口(合入前置门槛):
tools/gauntlet.sh(build/vet/gofmt/staticcheck/test -race/覆盖率≥60%/shuffle/变异 4-4/真实执行,fail-on-first)
开发工作流(SDD → TDD → 覆盖 → 一致性)
任何需求变更必须按以下流程,缺一不可:
- SDD:在
openspec/changes/<change-id>/编写proposal.md/design.md/spec.md(spec 用 Requirement+Scenario 表述);tasks.md按 P0-P4 拆解;P0-P4 仅表依赖顺序,全部完成才算完成 - TDD:先写测试(red)→ 最小实现(green)→ 重构(refactor)
- 接线与覆盖:每个 Requirement 必须有实现入口 + 测试用例;spec 每个 Scenario 映射到测试(覆盖矩阵逐项打勾);未接线/未测试的需求不计入完成
- 一致性对照:落地后输出
conformance.md(spec ↔ 实现 ↔ 测试 对齐度 fully/aligned/partial/gap),作为合入前置门槛 - 回归:
go build/vet/test ./...+python3 test_mcp.py全绿
19 维开发规范(验收标准,全部强制)
- 上下文逻辑连贯:改动必须与既有代码路径/主链路一致(先核对实际实现,不凭印象),避免误导实现
- 杜绝空谈:每个需求/场景有落地依据与可执行验收点;无据可依的内容不得写入 spec
- 消除歧义:默认值/命名/识别优先级/错误类型等必须定案并写入 spec,不留 Open Question
- 语义精准:术语、错误类型、边界条件表述无多义,避免大模型/实现者理解偏差
- SDD/TDD 适配:测试可先行(fixtures/golden 先备齐、测试顺序明确),TDD red 阶段不被阻塞
- 最小化实现:只改必要文件,不侵入核心。示例:文档导入 = cmd_add 前置转换层,不改
CollectFiles/SmartImportSource/ImportResult/watch 配置 - 向下兼容:Go 版本升级、依赖引入必须评估存量影响并文档化(README/Release Notes 标注最低版本、行为变更)
- 破坏性影响梳理:行为变更(如
okf add <非md>由静默跳过变自动转换)必须在 CLI 帮助与 README 声明 - 风险预判:临时目录清理(
defer RemoveAll)、输入超限/转换超时/损坏/扫描文件等异常路径必须有明确处理与测试 - 可行性评估:先本地验证核心链路(编译/转换/解析),再定方案;技术不可行及时暴露而非绕过
- 分层任务/测试/排期:任务依赖清晰、测试规划完整;排期仅表先后顺序,不构成交付边界
- 可扩展性:扩展成本低(如加格式只增映射 + downmark 包);关键前置决策(如身份/重导入语义)在方案阶段定案
- 拒绝过度设计:不引入空转开关、冗余抽象、多余字段/错误类型(用既有机制,如
Patternsglob、downmark 错误透传) - 小而高效:用最少代码变更实现核心收益;改动面控制在必要文件
- 持续优化:代码逻辑优雅直观,避免绕路与重复
- 架构统一:风格一致、不割裂;新增能力走前置管道,不塞进核心导入逻辑
- 全需求接线与覆盖测试:每个需求必须有实现函数/入口 + 对应测试;没有接线和测试的开发不算完成
- 排期仅表依赖:不得只开发 P0 就宣称完成;全量落地、全测试绿、一致性对照通过才算完成
- spec-实现一致性对照:落地后逐条核对 spec Scenario 与实现/测试,输出
conformance.md;partial/gap必须给出原因与后续任务
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.
- 2d ago First seen · 73 lines · 2,221 tokens per session scan A 18a70114b40b
okf AGENTS.md is an instructions file published in the GitHub repository superops-team/okf (22 stars, last pushed 2d ago), licensed Apache-2.0. It adds 2,221 tokens to every session, about $0.0111 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
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.
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).
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).
next.js AGENTS.md
Instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.