Nodes/ComfyUI_RS_NAI_API_Request/NAI Precise Reference
ComfyUI Node

NAI Precise Reference

V4.5's character cheat, and the 5 Anlas it charges

By raspie10032·Created 2 years ago·Updated about 15 hours ago· 10
NAI Precise Reference
  • image
  • references
  • references
◄reference_typecharacter►
◄strength1.00►
◄fidelity1.00►
◄enabledtrue►

Vibe Transfer is for style. Precise Reference is the one that tries to hold an identity - a character's face and build, or a painter's look, or both - and it's the only reference mechanism NovelAI V4.5 lets you use inside an inpaint or a detailer pass. It's also the most expensive button in the pack.

If you're coming from the local side, think of it as the closed-weight cousin of IP-Adapter FaceID (identity-preservation.md): a reference image goes in, the model is conditioned on it, and there's no LoRA training anywhere in the loop. The difference is you don't control the encoder, the strength semantics are the vendor's, and each reference is metered.

What it does, mechanically

One image in - and it must be one, batches are rejected - plus three choices:

  • reference_type: character, style, or character&style. This is a different question from Vibe's information_extracted: you're declaring what should transfer before the model looks at it.
  • strength (default 1.0) - how much the reference influences the result.
  • fidelity (default 1.0) - how faithfully the reference is followed. Both sliders default to maximum, which is where most people start and where many stay.

Optional: references to chain more images (up to 16), and enabled to drop a node from the chain without deleting it. strength = 0 also drops the image, same as Vibe.

Before anything is sent, the image is fitted to the canvas the official client uses: the closest of 1024×1536, 1472×1472, or 1536×1024 by aspect ratio, padded with black rather than stretched or cropped. So a wide reference gets letterboxed into a wide canvas, a tall one into a tall canvas, and there's black in the corners. That's not a quirk of this pack; it's matching NovelAI's own client so your results look like the web app's.

Output is a single references socket, typed RS_NAI_REFERENCES, which goes into the references input on the generator, img2img, the inpaint node, or either Detailer.

The mental model that saves you a day

References are global guidance, not per-character assignment. Multiple character references blend their identities into the result. They do not map onto character slots. If you want two distinct OCs in one frame, that's the multi-character prompt system - separate prompt slots with X/Y coordinates so the attributes stop bleeding into each other (regional-prompting.json) - not two reference images. People arrive at this node expecting "image A → character 1, image B → character 2" and it has never worked that way.

Same rule inside a detailer: a connected reference applies to every region being re-rendered. One character's reference plus a multi-region detail_mode=all pass means that character's face gets pushed onto every crop. Use a single region.

Costs, because there are always costs

Per the author's reading of NovelAI's docs, Precise Reference adds 5 Anlas per reference per generation - and it applies even when your base generation qualifies as Opus free. That's the part that catches people: you set up a tidy free-text-to-image loop, add one reference, and now every queue press spends.

The pack's protection is limit_opus_free on the downstream generation node, default True. It blocks reference requests before the token is read, before any encoding happens, before anything is uploaded. You have to consciously set it to False to run. Check NovelAI's current pricing before you batch anything.

Compatibility, and the error you'll see

  • V4.5 Full and V4.5 Curated only. Connect a reference with V5 selected and you get a clear model error before any request.
  • V5 Curated inpainting falling back to V4.5 doesn't help you - for reference work you have to select V4.5 explicitly.
  • Cannot be combined with Vibe Transfer. NovelAI won't take both; the pack raises an error rather than sending a payload that would fail.

Detailer preview_only is the free way to check your masks: it doesn't encode or upload references at all.

Install and run

cd ComfyUI/custom_nodes
git clone https://github.com/raspie10032/ComfyUI_RS_NAI_API_Request.git
cd ComfyUI_RS_NAI_API_Request
python -m pip install -r requirements.txt

ComfyUI Manager: search ComfyUI_RS_NAI_API_Request, Install, restart. Then .env in the pack folder with NAI_ACCESS_TOKEN=... - required, since the reference has to reach NovelAI's servers.

Load Image → NAI Precise Reference → (references) → NAI Image Generator   [limit_opus_free = False]

The pack serialises all its NovelAI calls - one lock, at least two seconds between network attempts, one 429 retry honouring Retry-After. Predictable, not fast; a batch of reference generations will feel deliberate.

One last honest note from the author's own release notes: unlike Vibe Transfer on V3, Precise Reference was not validated end-to-end against the live API - the earlier V4/V4.5 encoding attempt came back HTTP 402 for insufficient Anlas and the paid path wasn't retried. Payloads, guards and caching are covered by offline tests. Treat your first run as a paid experiment, not a proven pipeline.

CategoryRS_NovelAI_API/References

Inputs (6)

NameTypeDefaultDescription
imageIMAGE—
reference_typeCOMBOcharacter3 options: character, style, character&style
strengthFLOAT1.000–1—
fidelityFLOAT1.000–1—
referencesoptRS_NAI_REFERENCES—
enabledoptBOOLEANtrue—

Outputs (1)

NameTypeDescription
referencesRS_NAI_REFERENCES—