Civitai Media Rating
Civitai's own moderation brain, exposed as a node
- image
- api_config
- nsfw_level
- blocked_reason
- is_blocked
- labels
- age_classification
- face_recognition
- ai_recognition
- anime_recognition
- workflow_id
- raw_json
This is the node that lets a machine tell you whether an image is NSFW - and a bunch of other things - using the exact same rating pipeline Civitai runs on its own uploads. If you're building an automated pipeline (batch-generating, auto-uploading, content filtering before a model card goes up), that's genuinely useful: it's the platform's own verdict, from the platform's own servers, so "Civitai would block this" and "this node says blocked" line up by construction.
How it works
It's one of the Analysis family in the Civitai pack: send an image up to the Orchestration API, get structured moderation data back. The key control is engine:
default- HiveVLM, a third-party moderation model.civitai- Civitai's own rating engine, and the one you want if your goal is "will Civitai accept this?" The four boolean inputs (include_age_classification,include_face_recognition,include_airecognition,include_anime_recognition) are all flagged civitai engine only - on the default engine they're no-ops. Two of them (AI-vs-real and anime-vs-real detection) are also marked GPU-only on Civitai's side.
The output fan-out is the fun part. Eleven outputs:
nsfw_level,is_blocked,blocked_reason- the headline trio. If you're gating an upload,is_blocked+blocked_reasonis your gate.labels- what the model thinks is in the frame.age_classification,face_recognition,ai_recognition,anime_recognition- the four optional analyses, when you asked for them on the civitai engine.
Inputs you actually set
image- anIMAGEinput. The tooltip is unusually technical: the image is "pre-processed in the API layer - imported into blob storage so the worker can pre-fetch it as a declared resource," and after processing the output slot contains the blob AIR URL. Translation: you wire an image in, and Civitai handles the rest.engine- default vs. civitai, as above. This is the decision that matters.- The four
include_*booleans - all default false; flip the ones you want, on the civitai engine.
Install
cd ComfyUI/custom_nodes
git clone https://github.com/civitai/civitai-comfy-nodes.git
pip install -r civitai-comfy-nodes/requirements.txt
Or ComfyUI Manager → "Civitai Comfy Nodes" → Install → restart. Authenticate (CIVITAI_API_TOKEN or sidebar), and remember every rating call costs a little Buzz.
Gotchas
This is the one node where "early preview" plus "someone else's policy" both bite at once. The moderation rules behind is_blocked are Civitai's, and they've shifted repeatedly through the platform's history - what's blocked today may not be blocked next quarter, and the pack regenerates node shapes from the API spec, so the option list can change too. Also, a rating is a model's opinion: HiveVLM and Civitai's engine disagree on edge cases, which is exactly why the engine switch exists. And remember the data flow - the image you send up is processed on Civitai's infrastructure, so this isn't the node for sensitive content you'd rather keep local. For gating your own pipeline against the platform's own standards, though, it's the closest thing to asking Civitai directly.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| include_age_classification | BOOLEAN | false | Include age classification analysis in the results (civitai engine only). |
| include_face_recognition | BOOLEAN | false | Include face recognition and similarity analysis in the results (civitai engine only). |
| include_airecognition | BOOLEAN | false | Include AI vs real image detection in the results (civitai engine only, GPU-only). |
| include_anime_recognition | BOOLEAN | false | Include anime vs real image detection in the results (civitai engine only, GPU-only). |
| imageopt | IMAGE | The image to rate. Pre-processed in the API layer — imported into blob storage so the worker can pre-fetch it as a declared resource. After processing, contains the blob AIR URL. | |
| engineopt | STRING | default | The engine to use for media rating. Valid values: "default" (HiveVLM) or "civitai". |
| api_configopt | CIVITAI_CONFIG | Optional Civitai Auth connection; defaults to CIVITAI_API_TOKEN or stored OAuth login. |
Outputs (10)
| Name | Type | Description |
|---|---|---|
| nsfw_level | STRING | — |
| blocked_reason | STRING | — |
| is_blocked | STRING | — |
| labels | STRING | — |
| age_classification | STRING | — |
| face_recognition | STRING | — |
| ai_recognition | STRING | — |
| anime_recognition | STRING | — |
| workflow_id | STRING | — |
| raw_json | STRING | — |