Borrowing it
Nothing to install: this file belongs to xinvxueyuan/NovelAI-Image-MCP. 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/xinvxueyuan/NovelAI-Image-MCP/main/AGENTS.mdgit clone --depth 1 https://github.com/xinvxueyuan/NovelAI-Image-MCPWrote 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/xinvxueyuan/novelai-image-mcp/agents-md)<a href="https://agentmods.dev/instructions/xinvxueyuan/novelai-image-mcp/agents-md"><img src="https://agentmods.dev/badge/instructions/xinvxueyuan/novelai-image-mcp/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/xinvxueyuan/novelai-image-mcp/agents-md"><img src="https://agentmods.dev/badge/instructions/xinvxueyuan/novelai-image-mcp/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.06414 | $0.06414 |
| Opus 5.5 | $0.02566 | $0.02566 |
| Sonnet 5.5 | $0.01283 | $0.01283 |
| Haiku 4.5 | $0.00641 | $0.00641 |
Grade A, and why
NovelAI-Image-MCP 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 15d 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 — 307 lines — stays where its author put it; the contents beside it link to each section on GitHub.
AGENTS.md
面向 AI agent 的仓库级上下文索引。完整开发者文档见
CONTRIBUTING.md与 docs 站。 本文件只沉淀"约束 + 指针",避免与 docs 站重复。
项目是什么
NovelAI Image MCP —— 一个基于 fastmcp 4
(fastmcp>=4.1.0,<5,底层运行在 MCP SDK v2 mcp>=2.3.0 上)的模型上下文协议
服务器,把 NovelAI 图像生成 API 暴露为 11 个 MCP 工具、2 个 prompt、3 个资源 +
1 个资源模板,供 Claude Desktop / Cline / 自研 agent 调用。Python 3.13,MIT 协议。
仓库布局(uv + pnpm monorepo,Turbo 编排)
apps/server/ → 可安装的 MCP 服务器包(PyPI: novelai-image-mcp)
src/novelai_image_mcp/
nai/ # NovelAI HTTP 客户端(必须走 create_http_client())
tools/ # 11 个 MCP 工具(模块级 @mcp.tool 装饰器)
resources.py # novelai://models / samplers / defaults / outputs/{name}
prompts.py # novelai_prompt_writer / novelai_image_workflow
middleware.py# 工具调用日志 + 分路审计 + 实验性工具双闸门控
mcp_auth.py # 可选 HTTP Bearer Token(MCP_AUTH_TOKEN / MCP_ROUTE_TOKENS)
deps.py # AppContext + Depends 依赖提供者(含 insiders / routing providers)
insiders.py # X-MCP-Insiders 头解析(纯逻辑,无 I/O)
features.py # INSIDERS_FEATURES 特性注册表 + resolve_features
routing.py # 声明头 → RoutingContext(route 白名单 + 头脱敏)
audit.py # append-only JSONL 审计(单次 os.write + O_APPEND)
schemas.py # 结构化输出模型(AnlasEstimate / TagSuggestion)
server.py # FastMCP 实例 + lifespan + 组件导入
cli.py # typer CLI(同步入口)
tests/
mcp_server.py # fastmcp run/dev 入口(绕开相对导入问题)
pyproject.toml # 版本号唯一权威源 + ruff/pyright/pytest 配置
fastmcp.json (根或 member) → fastmcp run 的声明式配置(source 指向 mcp_server.py)
apps/docs/ → Sphinx 文档站(Furo + MyST)
.github/ → workflows (ci/release/docs) + detect-changes composite action
pyproject.toml (根) → uv workspace 虚拟根(不可安装)
uv.lock → 全仓库唯一锁文件
常用命令
uv sync # 同步 Python workspace
uv run --directory apps/server poe check # format-check + lint + typecheck + test
uv run reuse lint # REUSE 合规
uv run --directory apps/server poe serve # 启动 stdio 服务器
uv run --directory apps/server poe serve-http # 启动 HTTP 服务器
uv run fastmcp run fastmcp.json # 标准 FastMCP 入口(仓库根)
uv run --directory apps/server poe inspect # 组件/版本一览(fastmcp inspect)
uv run --directory apps/server poe dev # MCP Inspector(交互调试)
pnpm docs:serve # sphinx-autobuild 实时预览
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.
- 15d ago Changed · +71 lines · +1,695 tokens per session 224137933e46
- 19d ago Changed · -3 lines · -15 tokens per session 3a9186f60e2c
- 23d ago Changed · +31 lines · +751 tokens per session 88357c0e381e
- 2mo ago First seen · 208 lines · 3,983 tokens per session scan A f5f78c33f8e4
NovelAI-Image-MCP AGENTS.md is an instructions file published in the GitHub repository xinvxueyuan/NovelAI-Image-MCP (12 stars, last pushed yesterday), licensed MIT. It adds 6,414 tokens to every session, about $0.0257 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-31.
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).
generative-ai-for-beginners AGENTS.md
AGENTS.md instructions for microsoft/generative-ai-for-beginners, covering agents.md, project overview, setup commands, initial repository setup and clone the repository.