Nodes/ComfyUI-TJ_NODE/Krea2 LoRA Analyzer (TJ)
ComfyUI Node

Krea2 LoRA Analyzer (TJ)

See inside a Krea2 LoRA block by block — and fix it, not just apply it

By designloves2·Created 4 months ago·Updated 3 days ago· 13
Krea2 LoRA Analyzer (TJ)
  • model
  • clip
  • model
  • clip
  • analysis_text
  • analysis_json
lora_name
global_strength1.00
use_originalfalse
block_config{}

Krea2 LoRA Analyzer (TJ) is the Krea2-specific member of a four-node LoRA analyzer family that lets you see where a LoRA is actually working instead of just applying it and hoping. A normal LoRA loader dumps the whole adapter on at one strength. This node parses the LoRA into its per-block contributions - Krea2's structure is main 28 blocks + TxtFusion layerwise 2 + refiner 2, for 32 blocks total - shows you which blocks carry the effect, and lets you scale or zero them individually. It's the difference between a dimmer switch and a channel fader on a mixing desk.

How it works

Under the hood is a shared analyzer core that reads the LoRA's keys and maps them onto the architecture's block layout. It's deliberately format-agnostic on the way in: dot, kohya, diffusers, LoKr, and the shortened key forms are all auto-recognized, which is genuinely useful because LoRA files in the wild rarely use one consistent key convention. Once mapped, each block gets a strength, and the node patches the model with your per-block config instead of a flat strength. It can also detect when the LoRA you loaded doesn't match Krea2's architecture and warn you before you waste a run - the same core powers the Klein and Z-Image variants with their own block maps.

The interface is where the pack put its effort: a live effect bar that updates as you drag strength, an overlay comparing against the original, and one-click presets for "keep only the strong blocks," "balanced," and "clean up the weak ones" - plus save/load of your own presets. There's a use_original toggle to A/B against the unmodified model while keeping your settings.

Inputs and outputs that matter

  • model - the base model the LoRA will patch.
  • lora_name - the LoRA file from your models/loras folder.
  • global_strength - master strength, -5 to 5.
  • use_original - compare against the original model.
  • block_config - a JSON string (default {}) where the per-block overrides live; the UI builds this for you.
  • clip - optional; pass a CLIP if your LoRA also patches the text encoder.

Outputs: model (the patched model - this is what you wire into your sampler), clip, plus analysis_text and analysis_json (STRING) describing what was found and applied, useful for debugging or logging.

Install

ComfyUI Manager → Install Custom Nodes → search TJ_NODE, or:

cd ComfyUI/custom_nodes
git clone https://github.com/designloves2/ComfyUI-TJ_NODE

Restart ComfyUI. The LoRA analyzer family needs no extra dependencies. Category: ✨ TJ_Node/Lora Analyzer.

Why this exists, and whether you need it

The idea (the README credits comfyUI-Realtime-Lora for the block-analysis inspiration, though this is a from-scratch implementation per architecture) is that a LoRA's quality problems are usually localized: a character LoRA that overpowers anatomy, a style LoRA whose composition is great but whose colors bleed - that's often one or two block regions doing the damage, and a flat strength reduction weakens everything else along with them. If you're training or heavily using Krea2 LoRAs and find yourself fighting strengths, this is the node that turns guesswork into something you can inspect. If you just stack a couple of LoRAs from Civitai and rarely touch strength, a plain loader does the job with less ceremony.

Category ✨ TJ_Node/Lora Analyzer

Inputs (6)

NameTypeDefaultDescription
modelMODEL
lora_nameCOMBO0 options:
global_strengthFLOAT1.00-5–5
use_originalBOOLEANfalse
block_configSTRING{}
clipoptCLIP

Outputs (4)

NameTypeDescription
modelMODEL
clipCLIP
analysis_textSTRING
analysis_jsonSTRING