h4 : Axis Driver (v0.6.0)
Let the Axis Driver write the JSON
- axis_x
- axis_y
- axis_z
- legacy_summary
Setting up an XY grid in a plain plot node means typing comma-separated sampler names, or worse, full model filenames with subfolder paths, into a text box - and praying you got the spelling right. The h4 Axis Driver is the answer to that particular annoyance: a visual configuration node that builds structured axis payloads and hands them to The Engine. Instead of hand-authoring strings, you click "add item", pick a value from a dropdown, and out comes clean JSON.
It belongs to the same small, openly-shelved h4 ToolKit pack as the Engine (search impressions: zero - you're an early adopter). But as a concept it's the right instinct, and it's the sort of quality-of-life thinking that makes big test matrices less miserable.
How it works
The Driver's entire job is serialization. It has one widget, config - a JSON document describing three axis slots (X, Y, Z), the items in each, and a style block for grid labels. The UI layer (js/h4_ui.js) gives that widget a friendly editor: per-axis preset dropdowns, add/remove item rows, and model pickers that discover your checkpoints, LoRAs, VAEs and CLIPs straight from ComfyUI's /object_info API. When you emit, it parses that config and outputs four strings:
axis_x,axis_y,axis_z- structured JSON payloads for the Engine's matching axis inputs.legacy_summary- a newline-separated text version for older workflows that still want plain strings.
Wire axis_x → the Engine's axis_x input and the Driver's preset is authoritative; the Engine's manual x_axis_mode/x_axis_values widgets get ignored in favor of the connected payload. No duplicated configuration, no sync errors.
The presets that matter
Pick a preset per slot and add items: checkpoint, lora, vae, clip, clip_vision, sampler, scheduler, cfg, steps, denoise, seed, prompt, or none. The two you'll reach for most:
lora- each item gets a model dropdown plus a strength slider (0–2.0, default 0.75). This is the killer feature: testing three LoRAs at three strengths is usually a fiddly multi-node mess, and here it's one axis.checkpoint- A/B model testing with actual dropdown discovery instead of typed paths.
The style block also carries a label_layout selector (overlay, border, none) that tells the Engine how to annotate the grid - overlay for quick inspection, border for clean export charts with axis headers. The payload ships the choice downstream automatically.
Install
Same pack-wide story: ComfyUI Manager → search "h4 ToolKit", or:
cd ComfyUI/custom_nodes
git clone https://github.com/m3rr/h4_ToolKit
Restart, and the banner prints the loaded nodes. Dependencies are just colorama and numpy (auto-installed on startup); no models to fetch. Note the README's folder references (h4_Plot/js/) are stale - the shipped tree is flat.
Common issues
- Models not appearing in the dropdowns - check the console for asset-loading logs, and make sure your models are in standard ComfyUI or Stability Matrix model folders. The discovery is real ComfyUI API calls, not magic.
- Engine throwing errors after wiring - make sure the axis preset matches what the Driver is emitting (both set to
lora, say), and don't feed Driver output into the Engine's manualx_axis_valuesfield. Payload inputs and widget inputs are two different lanes. - Custom values with "(custom)" labels - the Driver preserves values it didn't recognize from a dropdown, which is great, but only if the exact path/name matches what ComfyUI expects. Typos surface as load errors in the console.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| config | STRING | { "axes": [ { "slot": "X", "preset": "checkpoint", "items": [] }, { "slot": "Y", "preset": "prompt", "items": [] }, { "slot": "Z", "preset": "none", "items": [] } ], "style": { "font_size": 22, "font_family": "DejaVuSans", "font_colour": "#FFFFFF", "background": "black60", "alignment": "center", "label_position": "top_left", "label_layout": "overlay", "custom_label_x": "X", "custom_label_y": "Y", "custom_label_z": "Z", "show_axis_headers": true } } | JSON configuration for the Axis Driver UI. Connect the outputs to nodes expecting axis payloads. |
Outputs (4)
| Name | Type | Description |
|---|---|---|
| axis_x | STRING | — |
| axis_y | STRING | — |
| axis_z | STRING | — |
| legacy_summary | STRING | — |