# Hermes ComfyUI Image Profiles

Hermes does not require users to open the ComfyUI web UI for normal model selection.

The connector reads `config/comfyui.config.json`, checks which profiles are ready, then auto-routes:

- `comfyui_generate_image`: pure visuals and backgrounds.
- `comfyui_generate_poster`: posters, covers, e-commerce banners, and any task that needs readable Chinese text.
- High-end profiles such as Qwen-Image, Kolors, and FLUX only become selectable after their model and API workflow are installed and the profile is enabled.

## Current Low-End Route

`sd15_lcm_fast` is enabled by default:

- DreamShaper 6.2 checkpoint
- SD1.5 LCM LoRA
- Fast low-end background generation
- Not reliable for Chinese text or typography

For Chinese posters, Hermes should call `comfyui_generate_poster`. This creates a no-text background through ComfyUI and then overlays real Chinese text with Windows fonts and ffmpeg.

## Optional High-End Routes

The config already contains disabled templates:

- `qwen_image_cn_poster`
- `kolors_cn_visual`
- `flux_schnell_visual`

To enable one:

1. Install the matching ComfyUI model and custom nodes.
2. Export a ComfyUI API-format workflow JSON.
3. Put the workflow under:

```text
D:\Hermes-MCP-Connectors\runtimes\comfyui-image\workflows
```

4. Edit `config/comfyui.config.json`:

```json
{
  "id": "qwen_image_cn_poster",
  "enabled": true,
  "api_workflow_path": "D:/Hermes-MCP-Connectors/runtimes/comfyui-image/workflows/qwen-image-api.json"
}
```

5. Restart the ComfyUI MCP server or Hermes.
6. Call `comfyui_health_check`.

If the profile shows `ready=true`, Hermes can auto-select it. If it is not ready, Hermes keeps using the lower route instead of failing the whole product.

## API Workflow Binding

For custom API workflows, use ordinary ComfyUI API JSON. Hermes can bind common node classes automatically:

- `CheckpointLoaderSimple`
- `CLIPTextEncode`
- `EmptyLatentImage`
- `KSampler`
- `SaveImage`

For complex workflows, add `_meta.hermes_role` to important nodes:

```json
"_meta": { "hermes_role": "positive_prompt" }
```

Supported roles:

- `checkpoint`
- `positive_prompt`
- `negative_prompt`
- `latent`
- `sampler`
- `save_image`

## Product Rule

Do not use diffusion text rendering as the only way to create Chinese commercial posters. Even high-end models can fail on exact brand text, dates, or dense copy.

Use this priority:

1. High-end model if available for better background/semantics.
2. Native text overlay for exact Chinese title, date, brand, price, or selling points.
3. SD1.5 LCM fallback when GPU/model is weak.
