PillarTranslation
Chinese↔English translation that piggybacks on your JoyCaption install
- text
The Pillar pack's caption nodes are bilingual by design - they ask JoyCaption to answer in both English and Chinese. That creates an obvious need: translate the Chinese half back to English (or vice versa) before you feed it into a prompt encoder, since Stable Diffusion prompts don't read Chinese well. PillarTranslation is that glue. You paste in text, it detects whether it's Chinese or English, and translates it into the other language. That's it - no language picker, because it decides for you.
How it works
The translation runs through the same JoyCaption model as the caption nodes, so it's a real LLM doing the work, not a dictionary lookup. It detects the source language with langdetect, then builds a "translate this passage into English/Chinese" prompt and runs a generation pass. Two execution modes, same as the rest of the pack:
- Local (
本地): loads the model in-process, hardcoded to the 4-bit memory mode (≈4.2 GB) to keep the footprint down, and caches the loaded model so a second translation is fast. - Remote (
远程): POSTs tobase_url's/translateendpoint on a Pillar_Service instance.
The catch you need to know going in: local mode still downloads the whole multi-GB JoyCaption model on first use. This is not a lightweight translator you bolt onto any workflow - it's the companion to the caption flow. If you're already running PillarJoyCaption locally, the model's already there and this is nearly free. If you just want a one-off translation, a free web service will do the same job with less setup.
Inputs and outputs
exec_opt-远程(remote) or本地(local).base_url- only used in remote mode; fill in192.168.1.100:8000-styleip:port.text(multiline STRING) - the passage to translate. Wire it straight from a caption node'scn_captionoutput.
Output: text - the translated string. Feed it into a preview node (PillarTextMultLine pairs nicely) or a CLIP text encode.
Installing and gotchas
Same pack, same install: ComfyUI Manager → search Pillar_For_ComfyUI, or clone https://github.com/aicoder-max/Pillar_For_ComfyUI into custom_nodes and pip install -r requirements.txt. Restart after.
Where people trip up: the dropdowns are in Chinese (远程/本地), and if you leave base_url at its default server_ip:port in remote mode, the node quietly returns your original text untranslated rather than erroring - it swallows the failure and passes the input through. So if "nothing happened," check that exec_opt is what you think it is and base_url is valid. Also, because local mode forces the 4-bit load, expect a chunky first-run memory spike while it spins up the model.
It's a narrow tool - one direction, one language pair - but within the Pillar workflow it's exactly the right bridge, and it means you never have to hand-copy a Chinese caption into a translator again.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| exec_opt | COMBO | 2 options: 远程, 本地 | |
| base_url | STRING | server_ip:port | — |
| text | STRING | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| text | STRING | — |