Gemma API Encode [MPS]
The LTX-2 text encoder that lives in the cloud, not your GPU
- conditioning
The one LTX-2 bottleneck you can just delete
LTX-2's single worst pain point was never the DiT. It's the Gemma 3 12B text encoder that sits in front of it: 22.7 GB in fp16, the cause of most OOMs on consumer cards, and slow enough to load that people burned whole minutes per run. The community's fixes were workarounds - bypass it entirely, or hunt down 4-bit quant repacks.
Gemma API Encode [MPS] (class GemmaMPSAugmentation) takes the third option: it just doesn't load Gemma at all. It sends your prompt to Lightricks' API and gets the conditioning back, while the 19B video model keeps running on your machine. For anyone on Apple Silicon - which is exactly who this pack targets - or on a card that chokes on the 22 GB encoder, that's the difference between "barely runs" and "runs fine."
One thing up front so the name doesn't mislead you: this is an API node, not an MPS node. The [MPS] tag is about how it handles the response, not where the encoding happens. Your prompt leaves the machine, gets embedded on Lightricks' servers, and the returned tensor is patched so a Mac can load it without a CUDA device. It needs an API key from console.ltx.video. No key, no generation.
How it works
The encode is a two-step dance. First it reads a model_id out of your local LTX-2 checkpoint's safetensors metadata (the encrypted_wandb_properties key), because different LTX-2 builds expect different conditioning. Then it POSTs {prompt, model_id, enhance_prompt} to https://api.ltx.video/v1/prompt-embedding with your key as a Bearer token.
The interesting part is the response handling. The API returns pickled tensors that reference CUDA storage - useless on a Mac. The node ships a custom unpickler that rewrites torch.storage CUDA references to FloatStorage and patches torch.serialization._validate_device to accept a CPU device, so the conditioning lands on your machine clean and MPS-ready. It's a surgical hack, and it's very much in the pack's "augment, don't replace" spirit.
The inputs that matter
- api_key - paste a key from
console.ltx.video. This is the whole cost model; it's metered per call. - prompt - multiline. LTX wants long, detailed prompts, so feed it one. This is where the real quality lives.
- enhance_prompt - defaults to true, which runs Lightricks' server-side prompt enhancement. The community's hard-won lesson with LTX-2 is that the built-in Gemma enhancer is often worth bypassing - write your own structured prompt and flip this off.
- ckpt_name - your local LTX-2 checkpoint. Quirky bit: it's not encoding on your machine, it just needs the checkpoint's metadata to know which model version to target.
Output is a single conditioning, which wires straight into the positive conditioning input of your LTX-2 sampler - the exact slot the local Gemma encoder would have filled.
Install
It's a one-file lean pack, and the source confirms the "no dependencies" claim - no requirements.txt, just requests, torch, and safetensors, all of which ComfyUI already ships. Either way:
- ComfyUI Manager: search "Silicon-Implants", install, restart.
- Manual:
cd ComfyUI/custom_nodes && git clone https://github.com/blackest/Silicon-Implantsthen restart.
Where people get burned
- 401 / "Invalid API key" - the error message is accurate: generate a fresh one at
console.ltx.video. - "Model ID cannot be identified" - your checkpoint's metadata is missing the key, which happens with repacked or renamed LTX-2 checkpoints. Use an official release.
- It's a cloud call - data leaves the machine, per-call cost adds up, and API nodes are exactly the shape of thing that's been weaponized before in ComfyUI. This one is open source and short - read it before you trust it.
- Licensing: this node's code derives from LTX-2 code and carries the LTX-2 Community License - free under $10M annual revenue, share-alike if you modify it. The author's own note: if you clear the commercial threshold, "can I be your friend?"
If your GPU already handles the 22 GB encoder, skip this. But if Gemma is the reason LTX-2 won't run on your machine at all, this is the cheapest fix in the pack.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| api_key | STRING | — | |
| prompt | STRING | — | |
| enhance_prompt | BOOLEAN | true | — |
| ckpt_name | COMBO | 0 options: |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| conditioning | CONDITIONING | — |