
danbooru-tag-mcp
io.github.BaixuanZhu由 GitHub 账号 BaixuanZhu 发布v0.5.0更新于 Nov 3, 2026
Danbooru MCP server for AI image generation: search, batch lookup, aliases, profiles, wiki, posts
概览
查询真实的 Danbooru 标签——名称、别名、分类、帖子数、共现统计与 wiki 文本,帮助助手写出准确的图像生成提示词。
- 可以做什么
- 按关键词搜索标签,并查询单个标签或一次最多 20 个标签的精确信息
- 把别名和拼写错误解析为规范标签,并读取标签的 wiki 页面与其中的关联标签
- 查找与某标签共现的标签,并从随机帖子样本生成标签分布画像
- 按标签组合搜索帖子,返回每篇帖子按分类拆分的完整标签列表
- 适用场景
- 适合助手在撰写或调整本地 AI 图像生成提示词时,需要核实 Danbooru 标签名称、别名和真实搭配,而不是凭猜测拼写。也适合检查 LoRA 说明中的标签是否仍存在或已被改名。
- 运行要求
- 以本地命令形式运行,需 Windows 10/11(x64 或 ARM64),按用户安装,无需 Node.js 或 Python 包。需要能访问 Danbooru API 的网络。可选环境变量 DANBOORU_LOGIN 与 DANBOORU_API_KEY 可提高速率上限;匿名使用也可,但限额较低。
安装
在 SourceWeft 中
- 打开 控制台中的 danbooru-tag-mcp,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
danbooru-tag-mcp
[CI] [Release] [Go] [License: MIT]
A Danbooru tag lookup MCP (Model Context Protocol) server for local AI image generation: your AI client resolves real Danbooru tags — exact names, aliases, categories, post counts, co-occurrence statistics, wiki descriptions, and the tag lists of real posts — before composing prompts, which noticeably improves tag accuracy in generated images.
Quick start
Install per-user (Windows 10/11, no admin rights):
Point your MCP client at the command:
That's it — the client picks up the eight tools below on its next session.
Features
- 8 MCP tools: tag search, exact tag info, batch tag lookup, related tags, alias resolution, wiki lookup, post search, and tag distribution profiles
- Batch tag lookup:
get_tags_inforesolves up to 20 exact tag names in a single request — one tool call instead of 20, with found/missing split and awd14verdict on every name - Tag distribution profiles, single or pair:
get_tag_profilesamples a page of a big tag's posts and answers what it actually renders as — co-occurring tags by in-sample frequency (corpus constants like1girl/solosplit intoubiquitous), combinations ranked by lift, and the sample's rating mix.withprofiles a tag pair over the 200 most recent joint posts (what doesarm_up+holding_weaponrender as?);order: score/favcountswitches to a top-post view (biased),rating:narrows either mode - Structured wiki pages:
get_tag_wikidistills the DText body intosummary,intro_tags(definition/appearance tag targets),rules(the "if X, use Y instead" disambiguation sentences),see_alsoandexample_posts— no raw body to re-parse;include_descriptionopts into the intro prose as plain text for character appearance descriptions - Tag lists back from post search:
search_postsreturns each post's full tag list split by category (copyright/artist/character/general/meta) plusscore/fav_count/large_file_url, so mining a few posts reveals which tags naturally go together - Tagger-era tag detection:
get_tag_infoclassifies every name against the pinned WD14 tagger vocabularies (wd14field:live/tagger_era— a tagger-era name Danbooru has since renamed, with the canonical name inrenamed_to/unknown), so LoRA card captions stop dead-ending at "tag not found";search_tagsaddswd14_hitsfallback hits when no result carries posts, and filters by category (general/artist/copyright/character/meta) so character or artist lookups stop drowning in general tags - Uncensored by default:
search_postsapplies no rating filter — results reflect a tag's whole population (arm_up is ~95% g/s/q); add arating:g/s/q/emetatag when you want only R-18 or only all-ages - Self-updating:
danbooru-tag-mcp upgradechecks GitHub Releases, verifies SHA256 and replaces the binary atomically - Zero-config install: per-user installer (setup wizard or one-line PowerShell) that registers the install directory into the user PATH automatically
- Polite API usage: requests are throttled to one per 1.5 seconds; anonymous access works, credentials raise the limits (free/anonymous post searches are still capped at 2 content tags per query)
Install
Requires Windows 10/11 on x64 or ARM64.
Option 1: setup wizard (recommended)
Download danbooru-tag-mcp-windows-<arch>-setup.exe from the
latest release
and double-click it. This installs per-user to
%LOCALAPPDATA%\Programs\danbooru-tag-mcp (no admin rights needed) and
registers the user PATH.
Option 2: one-line PowerShell
Custom install directory:
Option 3: portable zip
Download danbooru-tag-mcp-windows-<arch>.zip from the
release page,
extract danbooru-tag-mcp.exe anywhere, and run it once — the first run
silently adds its own directory to the user PATH (idempotent).
Option 4: ZCode / Claude Code plugin (auto MCP config)
For ZCode and Claude Code users the MCP configuration can come from a plugin
instead of hand-edited JSON: add this repository as a plugin marketplace and
install danbooru-tag-mcp — the plugin ships the danbooru-tags server
definition, so no client-side config is needed.
- ZCode: Plugin Marketplace → Add →
BaixuanZhu/danbooru-tag-mcp→ install thedanbooru-tag-mcpplugin. - Claude Code:
/plugin install danbooru-tag-mcp --marketplace BaixuanZhu/danbooru-tag-mcp(one step, Claude Code 2.1.275+), or add the marketplace first withclaude plugin marketplace add BaixuanZhu/danbooru-tag-mcpand install from there.
The plugin wires the configuration only — the CLI still has to be on PATH
(install it first via Option 1-3 above), and danbooru-tag-mcp upgrade
keeps it updated independently of the plugin. See
plugins/danbooru-tag-mcp/README.md.
Configure your MCP client
Point your MCP client (Claude Desktop, ZCode, etc.) at the command:
The bare command name works because the install directory is on the user PATH; alternatively use the full exe path. ZCode and Claude Code users can skip the manual JSON entirely via Option 4.
Tools
CLI
Environment variables
DANBOORU_LOGIN— your Danbooru account name (the login you use on the site). Optional.DANBOORU_API_KEY— your Danbooru API key, generated from the API key section of your Danbooru profile. Optional. When bothDANBOORU_LOGINandDANBOORU_API_KEYare set, every request is sent authenticated with your account (higher rate limits and content access); otherwise the client is anonymous and Danbooru applies lower limits.DANBOORU_MCP_NO_BOOTSTRAP— skip the startup PATH registration when non-empty.
Building from source
Requires Go 1.26+ and GNU Make (bundled with Git Bash):
Releases are automated: pushing a v* tag makes GitHub Actions run the test
suite and publish the setup exes, portable zips, and checksums.txt for both
architectures.
Reproducible builds & verifying downloads
Release binaries are not Authenticode-signed; integrity rests on reproducible builds plus SHA-256, all free and verifiable by anyone:
- The exe and portable zips are byte-reproducible: the exact Go toolchain
is pinned in
go.mod, builds useCGO_ENABLED=0 -trimpath -buildvcs=false, and zips are written byscripts/zipfilewith entry timestamps pinned to the commit time (SOURCE_DATE_EPOCH). Same source + toolchain ⇒ identical bytes on any machine, any timezone. - Every release job runs a verify-repro check: it rebuilds the exe from the tagged source on a Linux runner and compares it byte-for-byte against the published Windows-built asset — a green check on the release proves the artifacts were built from the tag without tampering.
- All artifacts carry SHA-256 checksums (
checksums.txt) and free keyless build-provenance attestations signed by the GitHub workflow.
Verify a download:
Reproduce the portable exe yourself and compare:
The NSIS setup exe is the one non-reproducible artifact (makensis embeds
build metadata); it is still covered by checksums.txt and the attestations.
来源:README.md,提交 71ea48f
工具
0版本历史
5- v0.5.0最新Nov 3, 2026
- v0.4.0Oct 31, 2026
- v0.3.0Oct 1, 2026
- v0.2.2Sep 30, 2026
- v0.2.1Sep 30, 2026
评分
已满足适用检查项的 50%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分