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/chenxiachan/thoughtdag/agents-mdgit clone --depth 1 https://github.com/chenxiachan/thoughtdagWhat 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.00585 | $0.00585 |
| Opus 5 | $0.00293 | $0.00293 |
| Sonnet 5 | $0.00117 | $0.00117 |
| Haiku 4.5 | $0.00059 | $0.00059 |
Grade A, and why
thoughtdag 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 3d 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.
What it actually says
AGENTS.md
ThoughtDAG:把 LLM 对话变成无限画布上可编辑的思维 DAG(节点=一轮问答,边=上下文流)。React 19 + Vite + TypeScript 前端,Express 代理后端。状态:活跃开发中的开放原型(github.com/chenxiachan/thoughtdag)。
常用命令
npm run dev # Vite 前端 (默认 5173)
npm run server # LLM 代理 server.mjs (端口 3001,前端默认指向它)
npm run build # tsc -b && vite build
npm run smoke # scripts/smoke.mjs 冒烟测试
npm run lint
需要 .env(见 .env.example):至少一把 LLM key(ZHIPU_API_KEY 免费档 glm-4.5-flash,或 DASHSCOPE_API_KEY 付费)。
架构
server.mjs— 唯一后端文件:Express 代理,用 Vercel AI SDK(ai+@ai-sdk/openai-compatible+zhipu-ai-provider)调 LLM;含 agentic 网页搜索 + 行内引用(搜索后保证有综合回答)。src/store/— zustand 全局状态;持久化用 idb-keyval(IndexedDB)。src/components/— 画布基于@xyflow/react(React Flow):ThoughtNode、ThoughtEdgeView、SelectionToolbar(圈选对齐,对齐前有确认提示)、focus-panel/。src/lib/api.ts— 前端到 server.mjs 的调用层。src/i18n/— 中英双语。- Markdown 渲染:react-markdown + KaTeX + highlight.js;PDF 附件用 pdfjs-dist。
约定
- 布局必须遵守箭头(上下文流)顺序,同一对话链节点竖向对齐——这是用户明确要求过的行为,改布局逻辑时不要破坏。
- 与用户交流用中文;代码标识符和注释保持英文。
- UI 文案(i18n、tooltip、toast、placeholder)不出现第三方品牌名。功能性标识除外:环境变量名、导入格式的身份(如 ChatGPT 导出文件)、实际数据源(arXiv、Semantic Scholar)。举例、推荐、宣传式的品牌提及一律用通称("外部 OCR 工具""其他助手")或扩展名(.docx)替代。
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.
- 3d ago First seen · 31 lines · 585 tokens per session scan A f55f6eb0bbf4
thoughtdag AGENTS.md is an instructions file published in the GitHub repository chenxiachan/thoughtdag (313 stars, last pushed 3d ago), licensed MIT. It adds 585 tokens to every session, about $0.0029 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
agentic-context-engine AGENTS.md
Instructions for kayba-ai/agentic-context-engine, covering agents.md, repository guidelines, pipeline-first development (mandatory), core code protection and documentation maintenance.
githits-cli AGENTS.md
Instructions for githits-com/githits-cli, covering githits agent instructions, general, architecture, testing and development workflow (docs-driven).
raytsystem-public-os CLAUDE.md
Instructions for romarayt/raytsystem-public-os, covering compatibility pointer and documentation synchronization.
raytsystem-public-os AGENTS.md
Instructions for romarayt/raytsystem-public-os, covering raytsystem — agent routing, invariants, commands, skill routing and documentation.
ChatCrystal AGENTS.md
Instructions for ZengLiangYi/ChatCrystal, covering agents.md, project overview, commands, development (server port 3721 + client port 13721) and build for production.
navigator CLAUDE.md
Claude Code instructions for alekspetrov/navigator, covering navigator: finish what you start, why this exists, how you'll use it, understanding context efficiency and core principle.