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/juanjitech/jframe/claude-mdgit clone --depth 1 https://github.com/juanjiTech/jframeWhat 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.02842 | $0.02842 |
| Opus 5 | $0.01421 | $0.01421 |
| Sonnet 5 | $0.00568 | $0.00568 |
| Haiku 4.5 | $0.00284 | $0.00284 |
Grade A, and why
jframe CLAUDE.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 — 243 lines — stays where its author put it; the contents beside it link to each section on GitHub.
CLAUDE.md — jframe 项目 Agent 开发指南
项目概述
jframe 是一个基于模块化内核的 Go 应用脚手架框架。所有功能以 kernel.Module 为单位组织,通过依赖注入容器 (inject/v2) 在模块间传递依赖,实现零耦合。
仓库: github.com/juanjiTech/jframe
Go 版本: 1.23+
入口: main.go → cmd.Execute() → Cobra 子命令
核心架构
模块系统
所有功能都封装为 kernel.Module(定义在 core/kernel/module.go)。
Module 接口:
Name() string — 唯一标识符,同时作为配置 YAML key
Config() any — 返回配置结构体指针,nil 表示无配置
PreInit(*Hub) / Init(*Hub) / PostInit(*Hub) / Load(*Hub) — 4 个顺序初始化阶段
Start(*Hub) — 在独立 goroutine 中运行(长驻任务)
Stop(*sync.WaitGroup, context.Context) — 优雅关闭(并发执行,必须 defer wg.Done())
生命周期执行顺序:
- Config 反序列化(遍历所有模块)
- PreInit(遍历所有模块)— 创建资源,Map 到 DI 容器
- Init(遍历所有模块)— 校验依赖
- PostInit(遍历所有模块)— 跨模块装配
- Load(遍历所有模块)— 注册路由、启用插件
- Start(每个模块一个 goroutine)— 长驻服务
所有模块必须嵌入 kernel.UnimplementedModule,这是 gRPC 风格的前向兼容模式(mustEmbedUnimplementedModule() 未导出方法强制嵌入)。
依赖注入 (DI)
基于 github.com/juanjiTech/inject/v2,一个反射驱动的类型映射容器。
Hub 结构体(core/kernel/module.go:10)包装了 inject.Injector + *zap.SugaredLogger,传入每个生命周期方法。
核心 DI 操作:
hub.Map(&value)— 注册依赖(按指针类型作为 key),一个类型只能存一个值hub.Load(&variable)— 获取依赖(必须检查 error)hub.Invoke(func(dep Type) { ... })— 函数参数自动注入hub.Value(reflect.Type)— 底层按类型直接查找
重要规则:
- Map 总是传指针:
hub.Map(&db)不是hub.Map(db) - Load 只能获取已被其他模块 Map 过的类型
- 同类型只能存一个值,需要多个相同类型用包装结构体区分
- 内核在所有模块之前 Map 了
*net.Listener和cmux.CMux
配置系统
全局配置: conf/vars.go 的 GlobalConfig 结构体,通过 conf.Get() 获取。
模块配置: 每个模块的 Config() 返回自定义结构体指针。内核使用 reflect.StructOf 动态构建包含 mapstructure tag 的结构体,由 Viper 按 Name() 自动映射:
// 内核内部操作 (kernel.go:69-85)
structType := reflect.StructOf([]reflect.StructField{{
Name: "Config",
Type: reflect.TypeOf(moduleConfig),
Tag: reflect.StructTag(`mapstructure:"moduleName"`),
}})
instance := reflect.New(structType)
instance.Elem().Field(0).Set(reflect.ValueOf(moduleConfig))
viper.Unmarshal(instance.Interface())
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 · 243 lines · 2,842 tokens per session scan A 97f7ead92adb
jframe CLAUDE.md is an instructions file published in the GitHub repository juanjiTech/jframe (5 stars, last pushed 2mo ago), licensed Apache-2.0. It adds 2,842 tokens to every session, about $0.0142 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-31.
Other instructions, from other repositories
no-mistakes AGENTS.md
AGENTS.md instructions for kunchenguid/no-mistakes, covering agents.md and maintaining this file.
trpc-agent-go AGENTS.md
AGENTS.md instructions for trpc-group/trpc-agent-go, covering agents.md, project overview, engineering principles, go design conventions and implementation workflow.
azure-sdk-for-go go-code.instructions.md
Instructions for Azure/azure-sdk-for-go: All code should follow the guidelines from the Azure Go SDK Guidelines. This document is a summary of the most important guidelines to follow when contributing to the Azure Go SDK.
goai AGENTS.md
Instructions for zendev-sh/goai, covering agents.md - goai, commands, architecture, key rules and adding providers.
unraid-management-agent copilot-instructions.md
Instructions for ruaan-deysel/unraid-management-agent, covering copilot instructions, copilot workflow, path-specific instructions, reusable prompts and quick commands.
coral CLAUDE.md
Instructions for cdknorow/coral, covering claude.md - coral go, mission, testing, go unit tests and legacy parity tools (historical reference).