How to Use PuLID Flux in Gemini CLI
PuLID Flux creates new portraits from a reference face and a text description, including photographic and illustrated treatments. It adds identity preservation to FLUX.1 dev without training a model for each person.
Prompts to try with PuLID Flux in Gemini CLI
Copy an example into Gemini CLI, or ask in your own words.
Use PuLID Flux with the reference portrait in this project's assets to create a headshot for the speaker page. Match the page's visual direction, use soft window light, and show me the result before replacing the current image.
Use PuLID Flux with the project's reference face to create a 1280 by 720 banner concept. Place the person on the right, leave the left side uncluttered for HTML text, and use a plain studio background.
Use PuLID Flux with the reference portrait in the project to create a comic profile image. Frame the head and shoulders centrally and follow the colors described in our design notes.
Use PuLID Flux to make a portrait lighting study from the project's reference photo: soft daylight, candlelight, and direct studio light. Save each result separately for review.
Use PuLID Flux with the project's reference portrait to compare ordinary guidance against true CFG for an illustrated avatar. For the true CFG test, set true_cfg to 2 and guidance_scale to 1; record the settings with each image.
How to set up PuLID Flux in Gemini CLI
Pick the way that suits you. Each takes about two minutes.
Use Spiral's MCP server
- Add the server
Or add it to ~/.gemini/settings.json yourself:
gemini mcp add --scope user --transport http spiral https://api.spiral.ai/mcp
- Sign in
Start gemini and run:
/mcp auth spiral
- Check it
In Gemini CLI, run /mcp. From your shell:
gemini mcp list
Use the Spiral skill
- Send Gemini CLI this message
Your agent reads Spiral's skill and sets itself up.
set up https://spiral.ai/SKILL.md
- Sign in or paste a key
Approve Spiral in the browser, or give the agent a key from the console.
Use the Spiral CLI
- Install and sign in
Installs the Spiral CLI, signs you in and adds its skill to your coding agents.
npx -y spiral-cli@latest init
Call the Spiral API
- Create an API key
In the console, under API keys.
- Run PuLID Flux
One request; the result comes back by polling or a webhook.
curl https://api.spiral.ai/v1/runs \ -H "Authorization: Bearer $SPIRAL_API_KEY" \ -H "Content-Type: application/json" \ -H "Idempotency-Key: $(uuidgen)" \ -d '{ "provider": "fal", "model": "fal-ai/flux-pulid", "input": { "prompt": "a woman holding sign with glowing green text '\''PuLID for FLUX'\''", "reference_image_url": "https://storage.googleapis.com/falserverless/gallery/example_inputs_liuyifei.png" } }'
Then paste one of the prompts above: Gemini CLI finds PuLID Flux on Spiral, shows the price and runs it.
PuLID Flux providers and prices
Spiral runs PuLID Flux through fal. Open a card for today's price, with every fee included.
$0.04329 per megapixel. image_size presets count as 1 MP; custom sizes round up to whole megapixels.
Settings you can ask for
PuLID Flux works from your prompt. Ask Gemini CLI for any of these in your prompt.
| Setting | Allowed values | Default | Description |
|---|---|---|---|
| Number of inference steps | 1 to 50 | 20 | The number of inference steps to perform. |
| Seed | a whole number | The same seed and the same prompt given to the same version of the model will output the same image every time. | |
| Guidance scale (CFG) | 0 to 20 | 4 | The CFG (Classifier Free Guidance) scale is a measure of how close you want the model to stick to your prompt when looking for a related image to show you. |
| Negative prompt | what to leave out, in words | The prompt to generate an image from. | |
| Start step | 0 to 50 | 0 | The number of steps to start the CFG from. |
| True CFG | 1 to 10 | 1 | The weight of the CFG loss. |
| ID weight | 0 to 1 | 1 | The weight of the ID loss. |
| Max sequence length | 128, 256, or 512 | 128 | The maximum sequence length for the model. |
Every API field of PuLID Flux is on its tool page: open its card above.
What can you do with PuLID Flux in Gemini CLI?
Create portrait assets for a project's profile screens, speaker pages, and image previews from reference faces. Use the project's design requirements to guide composition, then review likeness before adding a result.
Professional headshot concepts
Use a reference portrait to explore studio lighting, wardrobe, and backgrounds. Review facial resemblance before selecting a result.
Illustrated profile pictures
Turn a reference face into a comic or painted portrait. Specify the medium and framing in the description.
Speaker banner portraits
Create a wide portrait concept from a speaker's reference photo, with the person to one side and room for event copy.
Portrait lighting studies
Explore window light, candlelight, and studio lighting using the same reference face. Compare resemblance alongside the lighting treatment.
Character concept portraits
Use a reference face to explore a character's costume, setting, and visual style for a pitch or storyboard.
Creator thumbnail concepts
Generate portrait concepts from a creator's reference photo, changing the background and composition to match a video's subject.
More on PuLID Flux and Gemini CLI
Overview
PuLID Flux in other agents
Questions about PuLID Flux in Gemini CLI
Can Gemini CLI use PuLID Flux?
Yes. Add Spiral to Gemini CLI as an MCP server, and Gemini CLI can find and run PuLID Flux like any built-in tool.
How much does PuLID Flux cost in Gemini CLI?
$0.04329 per megapixel. `image_size` presets count as 1 MP; custom sizes round up to whole megapixels. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your Gemini CLI plan is separate.
Do I need a fal account to use PuLID Flux in Gemini CLI?
No. Spiral runs PuLID Flux on its own fal account. You sign in to Spiral once and never paste a key.
How long does it take to set up PuLID Flux in Gemini CLI?
About two minutes: add the server, then sign in, then check it.
Does Gemini CLI wait while PuLID Flux runs?
PuLID Flux runs in the background. Gemini CLI starts the run, checks on it and gives you the image when it's ready.
What is PuLID Flux good for?
Use it to create new portraits that retain a reference person's facial identity. Headshots, illustrated avatars, and portraits with different lighting or settings are practical starting points.
Does PuLID Flux require training for each person?
No. It conditions image generation on a reference identity without a separate training run for that person.
Can PuLID Flux create illustrated portraits?
Yes. The maker documents stylized generation alongside realistic portraits. Specify the treatment, composition, and lighting you want, then check whether the face remains recognizable.
Will PuLID Flux preserve the face exactly?
Treat likeness as something to review, not a guarantee. The maker describes a tradeoff between identity fidelity and editability, so assess both resemblance and the requested changes.
Why might a negative prompt have no effect?
The official implementation processes negative prompts only when true CFG is active. The maker recommends ordinary guidance for most work; when testing true CFG above 1, set ordinary guidance to 1.
Start using PuLID Flux in Gemini CLI
One Spiral account for every tool your agent needs. No subscription; you pay per run.
Paste this into Gemini CLI:
set up https://spiral.ai/SKILL.md



