Danbooru Popular Posts Tags Retriever
Mine Danbooru's most popular posts for ready-made prompts
- full_tags
- general_tags
- character_tags
- copyright_tags
- artist_tags
- meta_tags
DanbooruPopularPostsTagsRetriever grabs the tags from Danbooru's popular-posts leaderboard - daily, weekly, or monthly - and returns them as ready-to-prompt tag lists. It's the "what's good this week" node for the Danbooru-trained model crowd: a steady source of prompts that the community actually upvoted, which correlates with output that reads as "good" to the same audience.
Where Danbooru Post Tags Retriever is precise (you know the post), this one is exploratory (you want something popular). It's a genuinely fun node to plug into a workflow that generates a batch of images from trending tags - a poor-man's trend feed for Illustrious and NoobAI prompting.
How it works
The node hits Danbooru's explore/posts/popular.json endpoint. The scale input picks day/week/month, and date (YYYY-MM-DD) lets you rewind to a specific day - empty means "latest". The popular endpoint returns posts in rank order, 20 per page, and there are two consumption modes:
random=True(default): fetches a pool of popular posts and randomly samplesnof them using yourseed, so repeated runs with the same seed give the same "random" selection. Great for variety without surprises.random=False: walks the ranking deterministically. Withoffsetyou can step down the leaderboard - setoffset's control to increment andn=1, and each queue returns the next most-popular post's tags. This is the documented way to iterate through the ranking one post at a time, and it's cleverly efficient: it only fetches the page(s) that actually contain your rank range, not the whole leaderboard. If the rank you asked for doesn't exist, it raises rather than silently returning nothing.
Each output is a list - one entry per post - so n=5 gives you five tag strings per category. full_tags is the character + copyright + artist + general combination with meta tags excluded, same convention as the rest of the pack.
Inputs that matter
scale- day/week/month. Day is the freshest and noisiest; month is the safest "these are broadly popular" signal.n- how many posts to pull (default 1).random/seed/offset- the three knobs that decide which posts you get.
Outputs: full_tags, general_tags, character_tags, copyright_tags, artist_tags, meta_tags - all lists.
Install
Part of ComfyUI-Alchemine-Pack:
cd ComfyUI/custom_nodes
git clone https://github.com/alchemine/comfyui-alchemine-pack
pip install -r requirements.txt
Or via ComfyUI Manager (search "ComfyUI-Alchemine-Pack"). Uses plain requests; no model downloads.
Common issues
This endpoint is cached with a 1-hour TTL, so the same day's leaderboard won't refetch for an hour - that's a feature (rate-limit courtesy), but it means you won't see freshly-uploaded posts appear mid-session. The offset walk raises if you overshoot the leaderboard depth, which is correct behavior, but it can look like a crash - if you've hit it, you've simply walked past the end of the ranking. And popular isn't the same as promptable: many top posts lean on artist style tags, so you may want to drop artist_tags from your full prompt.
Inputs (6)
| Name | Type | Default | Description |
|---|---|---|---|
| date | STRING | — | |
| scale | COMBO | day | 3 options: day, week, month |
| n | INT | 1 | — |
| random | BOOLEAN | true | — |
| seed | INT | 0 | — |
| offset | INT | 0 | — |
Outputs (6)
| Name | Type | Description |
|---|---|---|
| full_tags | STRING | — |
| general_tags | STRING | — |
| character_tags | STRING | — |
| copyright_tags | STRING | — |
| artist_tags | STRING | — |
| meta_tags | STRING | — |