Borrowing it
Nothing to install: this file belongs to wxkingstar/SpecFusion. 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/wxkingstar/SpecFusion/main/AGENTS.mdgit clone --depth 1 https://github.com/wxkingstar/SpecFusionWrote 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/wxkingstar/specfusion/agents-md)<a href="https://agentmods.dev/instructions/wxkingstar/specfusion/agents-md"><img src="https://agentmods.dev/badge/instructions/wxkingstar/specfusion/agents-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/wxkingstar/specfusion/agents-md"><img src="https://agentmods.dev/badge/instructions/wxkingstar/specfusion/agents-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.00717 | $0.00717 |
| Opus 5.5 | $0.00287 | $0.00287 |
| Sonnet 5.5 | $0.00143 | $0.00143 |
| Haiku 4.5 | $0.00072 | $0.00072 |
Grade A, and why
SpecFusion 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 1mo 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
SpecFusion
多源 API 文档融合搜索 Skill — 云端检索,零安装,即问即答
项目结构
SpecFusion/
├── api/ # API 服务(Fastify + SQLite)
├── scrapers/ # 文档抓取/同步脚本(仅本地使用,不部署到服务器)
├── scripts/ # 部署脚本
├── specfusion/ # Skill 文件(SKILL.md)
├── dsh-plugin/ # DeepSeek Harness 插件(@wxkingstar/specfusion-dsh)
├── data/ # SQLite 数据库(specfusion.db)
├── Makefile # K8s 部署 + 全量同步命令(make help 查看)
开发命令
# 安装依赖
npm install
# 启动 API 服务(开发模式,热重载)
npm run dev
# 运行文档同步
npm run sync -- --source feishu
# 构建
npm run build
部署
支持 Docker 和 Kubernetes 部署,详见 README.md 中的自部署指南。
官网
官网代码目录:/Users/wangxin/work/node/specfusion-web,部署在 Vercel 上。
技术栈
- API:Node.js + Fastify + better-sqlite3 + FTS5
- 中文分词:nodejieba
- Scraper:Node.js + TypeScript + cheerio + playwright
- 构建:tsup + tsx
关键设计
- 所有公开 API 返回
text/markdown格式(非 JSON),health 端点除外返回 JSON - 中文搜索使用 jieba 预分词 + FTS5 unicode61
- 数据库仅使用 SQLite,不引入其他存储
- tsup 将 API 打包为单文件
dist/index.js,代码中用resolve(__dirname, '../../db/schema.sql')定位 schema,Docker 和旧 VPS 部署均通过 symlink 解决路径 - 详细设计见 SPECFUSION_PLAN.md
数据库路径
项目统一使用 data/specfusion.db(项目根目录)。dev 服务和 K8s 部署共用同一个文件,scraper 同步后可直接上传,无需合并。
Playwright Scraper 编码规范
编写使用 Playwright 的 scraper 时,注意以下性能陷阱:
- 禁止在循环中用高 timeout 的 click/waitFor 探测元素是否存在:
page.click('text=xxx', { timeout: 2000 })在元素不存在时会白等 2 秒。如果在每页导航后都尝试多次,累积开销巨大(N 页 × M 次 × timeout)。应只在首次加载时探测,或用page.locator().count()零等待判断 fetchContent循环中用domcontentloaded而非networkidle:SPA 页面可能有持续的后台请求导致 networkidle 永远等不到。正确做法是waitUntil: 'domcontentloaded'+waitForSelector等待目标内容出现- 单页面串行导航时,并发度必须设为 1:Playwright 同一 page 实例不能并行 goto
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.
- 1mo ago First seen · 68 lines · 717 tokens per session scan A 5633c626f4b8
SpecFusion AGENTS.md is an instructions file published in the GitHub repository wxkingstar/SpecFusion (74 stars, last pushed 1mo ago), licensed MIT. It adds 717 tokens to every session, about $0.0029 per session on Opus 5.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
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).
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.
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, cache eligibility and rollout and applying the notice (cutover).
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 copilot-instructions.md
Copilot instructions for microsoft/vscode, covering vs code copilot instructions, project overview, root folders, core architecture (src/ folder) and built-in extensions (extensions/ folder).
vscode model-prompts.instructions.md
Model-specific prompt authoring and registry guidelines.