Borrowing it
Nothing to install: this file belongs to rhett-lee/nim_duilib. 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/rhett-lee/nim_duilib/main/CLAUDE.mdgit clone --depth 1 https://github.com/rhett-lee/nim_duilibWrote 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/rhett-lee/nim_duilib/claude-md)<a href="https://agentmods.dev/instructions/rhett-lee/nim_duilib/claude-md"><img src="https://agentmods.dev/badge/instructions/rhett-lee/nim_duilib/claude-md/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/instructions/rhett-lee/nim_duilib/claude-md"><img src="https://agentmods.dev/badge/instructions/rhett-lee/nim_duilib/claude-md.svg" alt="Reviewed on agentmods" width="80" 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.01161 | $0.01161 |
| Opus 5 | $0.00580 | $0.00580 |
| Sonnet 5 | $0.00232 | $0.00232 |
| Haiku 4.5 | $0.00116 | $0.00116 |
Grade A, and why
nim_duilib 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 10d 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 — 98 lines — stays where its author put it; the contents beside it link to each section on GitHub.
nim_duilib - 跨平台 C++ UI 库
项目概述
nim_duilib 是基于 Skia 渲染引擎的跨平台 C++ UI 框架,采用 XML 描述界面布局 + C++ 控制逻辑的开发模式。
- 支持平台: Windows (7/10/11+), Linux, macOS (12+), FreeBSD
- 渲染引擎: Skia (CPU/OpenGL)
- 构建工具: CMake + Visual Studio / GCC / Clang
- C++ 标准: C++17+
项目结构
nim_duilib/
├── duilib/ # 核心库源码
│ ├── Core/ # 窗口、控件基类、事件、管理器
│ ├── Control/ # UI控件(Button, Label, RichEdit, TreeView...)
│ ├── Box/ # 容器控件(VBox, HBox, ListBox, TabBox...)
│ ├── Layout/ # 布局引擎(HLayout, VLayout, GridLayout...)
│ ├── Animation/ # 动画系统
│ ├── Image/ # 图片处理(PNG/SVG/GIF/WEBP/APNG/Lottie/PAG)
│ ├── Render/ # 渲染接口
│ ├── RenderSkia/ # Skia渲染实现
│ ├── Utils/ # 工具类(WindowImplBase, FilePath...)
│ ├── CEFControl/ # CEF浏览器集成
│ └── WebView2/ # WebView2控件
├── examples/ # 示例程序
├── docs/ # 完整文档
├── bin/resources/ # 主题资源(XML布局、图片、字体)
├── build/ # 构建脚本和解决方案
└── cmake/ # CMake配置
开发模式(XML + C++)
XML 布局文件
- 位置:
bin/resources/themes/default/<skin_folder>/<skin_file>.xml - 全局资源:
bin/resources/themes/default/global.xml(字体、颜色、通用样式) - 编码: UTF-8
C++ 代码三件套
每个窗口通常需要三个文件:
- MainThread - 继承
ui::FrameworkThread,负责初始化和创建窗口 - MainForm.h/cpp - 继承
ui::WindowImplBase,实现窗口逻辑 - XML布局文件 - 描述界面结构和样式
关键代码模式
初始化全局资源:
ui::FilePath resourcePath = ui::FilePathUtil::GetCurrentModuleDirectory();
resourcePath += _T("resources\\");
ui::GlobalManager::Instance().Startup(ui::LocalFilesResParam(resourcePath));
创建窗口:
MainForm* window = new MainForm();
window->CreateWnd(nullptr, ui::WindowCreateParam(_T("WindowTitle"), true));
window->PostQuitMsgWhenClosed(true);
window->ShowWindow(ui::kSW_SHOW_NORMAL);
查找控件:
ui::Button* btn = dynamic_cast<ui::Button*>(FindControl(_T("btn_name")));
事件绑定:
btn->AttachClick([this](const ui::EventArgs& args) {
// 处理点击事件
return true;
});
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.
- 10d ago First seen · 98 lines · 1,161 tokens per session scan A 6045ec2c0e21
nim_duilib CLAUDE.md is an instructions file published in the GitHub repository rhett-lee/nim_duilib (326 stars, last pushed 29d ago), licensed MIT. It adds 1,161 tokens to every session, about $0.0058 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
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.
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).
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).
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.
deepseek-harness AGENTS.md
AGENTS.md instructions for deepseek-ai/deepseek-harness, covering agents.md, pre-stable apis and released session data, repository layout, commands and host sandbox failures.