Repository navigation
Image Generation
Formamorph can draw images with an image server that you connect. It makes portraits for entities, pictures for locations and world thumbnails, and an image of each turn. The image server is separate from your text AI. It can run on your own PC, or be a paid cloud service.
Image generation is off until you turn it on. To connect a text AI, see Connect Your Own AI.
- Open Settings, then the Endpoints tab, then the Image tab.
- Select the Enable Image Generation checkbox.
- In Provider, select your image server.
- Select How to Set Up and follow the steps for that provider. The steps for each provider are below too.
- Fill in Endpoint URL, API Token and Model as the provider needs.
The Generate with AI buttons now show beside the World Editor's image fields. To get an image of each turn, see How to Turn On Scene Images.
- Install ComfyUI.
- Add
--enable-cors-headerto the start command in yourrun_*.batfile. - Run that file to start ComfyUI.
- In Provider, select ComfyUI (local).
- Leave Endpoint URL empty to use
http://localhost:8188, or type your server's address. - In Model, select a checkpoint. The Model and Sampler lists load from your server.
To use your own ComfyUI graph, see How to Use Your Own ComfyUI Workflow.
- Install InvokeAI.
- Open
invokeai.yamlin the InvokeAI root folder. - Add the app's address to
allow_origins. How to Set Up shows the exact line for the app you use, for exampleallow_origins: ["https://formamorph.ai"]. - Restart InvokeAI.
- In Provider, select InvokeAI (local).
- Leave Endpoint URL empty to use
http://localhost:9090, or type your server's address. - In Model, select an installed SDXL, SD1.5, Z-Image or Anima model. The list loads from your server.
A Z-Image or Anima model also needs a Qwen3 text encoder and a VAE. Formamorph picks installed ones. To choose them yourself, see InvokeAI Fields.
-
Install Automatic1111 or Forge.
-
Add this line to
webui-user.bat:set COMMANDLINE_ARGS=--api --cors-allow-origins=* -
Run
webui-user.batto start the server. -
In Provider, select Automatic1111 / Forge (local).
-
Leave Endpoint URL empty to use
http://localhost:7860, or type your server's address. -
In Model, type the checkpoint name, or leave it empty to use the server's checkpoint.
To use Face Fix, install the ADetailer extension on your server.
You need a NovelAI subscription.
- In NovelAI, select the cog icon, then the Account tab.
- Select Get Persistent API Token. Copy the token before you close the popup. NovelAI shows it only once.
- In Formamorph, in Provider, select NovelAI (cloud).
- Paste the token in API Token. Endpoint URL is already set to
https://image.novelai.net. - In Model, select a NovelAI model.
NovelAI starts at 1024ร1024 and 28 steps. Opus subscribers get one free image per request at those values or lower. Larger images or more steps spend Anlas. Stop can't cancel an image that NovelAI has started, so that image can still cost Anlas.
This provider works only in the desktop app. The desktop app sends the requests for you, so the service needs no CORS setup.
- In Provider, select OpenAI-compatible (cloud).
- In Endpoint URL, type the service's base URL, for example
https://api.openai.com. - Paste your API key in API Token. It stays on your PC.
- In Model, type the image model name. Empty uses
gpt-image-1.
This provider ignores Negative Prompt, Steps / CFG and Sampler. Each image is 1024ร1024, 1536ร1024 or 1024ร1536, whichever shape is nearest to the size you set.
The Workflow (API Format) field shows in Advanced mode. It holds the ComfyUI graph that Formamorph sends. How to Get This shows these steps too.
- In ComfyUI, open Settings and turn on Enable dev mode options (API save, etc.).
- Load or build your workflow.
- Select Workflow โ Export (API). Older builds have a Save (API Format) button. You get a
.jsonfile. - Open the file and paste all of it in Workflow (API Format).
- Replace each value that Formamorph must set with its token. See ComfyUI Workflow Rules.
Reset to Defaults puts back the default graph.
- Turn on image generation. See How to Turn On Image Generation.
- Open Settings, then the Display tab.
- In the Scene section, select Scene Images.
Each turn now ends with an image. See Scene Images.
- In the game, open the turn's More menu.
- Select Generate Scene Image. The item shows when the turn has no image.
If a turn is still running, the image starts when it ends. Write Scene Tags writes the tags only, so you can edit them before the image is made.
- On the Image tab, open Preset.
- Select Add New Presetโฆ.
- Type a name and select Save. The new preset copies the current values.
- Change the values you want. They save to that preset.
Select a preset in Preset to switch to it. See Image Presets.
| Provider | Runs on | Default address | Setup |
|---|---|---|---|
| ComfyUI (local) | Your PC | http://localhost:8188 |
How to Connect ComfyUI |
| InvokeAI (local) | Your PC | http://localhost:9090 |
How to Connect InvokeAI |
| Automatic1111 / Forge (local) | Your PC | http://localhost:7860 |
How to Connect Automatic1111 or Forge |
| NovelAI (cloud) | NovelAI's servers | https://image.novelai.net |
How to Connect NovelAI |
| OpenAI-compatible (cloud) | The service you pick | None. Type one. | How to Connect an OpenAI-Compatible Service |
ComfyUI (local) is the default provider. In the browser, OpenAI-compatible (cloud) shows desktop app only and can't be picked.
Each field of the Image tab is explained in Settings โ Image.
These fields show in Advanced mode when the provider is InvokeAI (local).
| Field | What it does |
|---|---|
| Board | The InvokeAI board that gets the images. Uncategorized is InvokeAI's own default. |
| Qwen3 Encoder | The text encoder for a Z-Image or Anima model. Z-Image needs Qwen3 4B; Anima needs Qwen3 0.6B. Empty picks one. |
| Z-Image VAE, Anima VAE | The VAE for that model. Z-Image needs a FLUX-type VAE. Anima needs a QwenImage/Wan 2.1 VAE; a FLUX VAE also works. Empty picks one. |
Face Fix on InvokeAI needs no extension. The first image with it on waits while InvokeAI downloads its detector models, a few hundred MB, one time. After that, it about doubles the time of each image.
The workflow must be ComfyUI's API format, not the normal saved workflow. Formamorph puts its values in with these tokens:
| Value | Token |
|---|---|
| Positive prompt text | "%prompt%" |
| Negative prompt text | "%negative%" |
Checkpoint (ckpt_name) |
"%ckpt%" |
Sampler (sampler_name) |
"%sampler%" |
| Latent width and height |
%width%, %height%
|
| KSampler seed, steps and cfg |
%seed%, %steps%, %cfg%
|
- A text token goes inside the quotes:
"text": "%prompt%". - A number token replaces the number:
"width": %width%. - A value with no token stays the same on each image. Use this to fix a LoRA, a refiner or a size.
- Formamorph takes the first image that any output node makes.
- An empty field uses the default graph.
When ComfyUI refuses the graph, the error names each node that failed and why. Text that is not JSON shows Invalid ComfyUI workflow JSON.
With Scene Images on, each turn ends with an image of the scene. The image comes last, after all of the turn's text. Your next action waits for it.
The image is made in these steps:
- Your text AI writes tags for the action in the turn. The Scene Tags prompt does this. See Prompts.
- The game adds the Image Tags of the location and of up to two entities in the scene.
- An entity or location with no Image Tags gets tags from its description, through the Tag Prompt.
- The image server draws the tags at the Landscape size of the current preset.
The image shows on the turn, above your action. Select it to zoom. A turn can keep several images: use Previous image and Next image to move between them, and Delete this image to remove one.
The panel under the image shows the progress, with Stop. Select Tags to see the tag line:
| Control | What it does |
|---|---|
| Re-roll tags | Writes a new tag line from this turn |
| Draw again | Draws the same tags again. After you edit the tags, it is Draw these tags. |
| Revert | Puts back the tags you edited |
Scene images are not in a save unless you select their checkbox in Save Game. Without them, the save keeps the tags only. See The Save Game Dialog. A rewind removes the images of the turns it removes.
A preset keeps a full set of Image tab values: the provider, its address and token, the model, the prompts, the sizes and the sampling values. Keep one preset for each server or style, and switch between them.
The icon buttons next to Preset manage your presets. Point at an icon to see its name. On a narrow screen they are in the Preset Actions menu.
| Control | What it does |
|---|---|
| Preset | Switches to a preset. Add New Presetโฆ makes one. |
| Duplicate | Copies the preset as "preset name (copy)" and selects the copy |
| Rename | Changes the preset's name |
| Reset | Sets the preset back to its default values |
| Delete | Deletes the preset. Shows when you have more than one. |
The first preset is Default, and you can edit it. The Generate image dialog in the World Editor has its own Preset picker. Enable Image Generation and the Tag Prompt are the same for all presets.
Under Preset, on the Image tab and in the Generate image dialog, a badge shows whether the preset's server answers. Select Recheck to test again after you start the server.
| Badge | What it means |
|---|---|
| Reachable | The server answered |
| Reachable, but no "model" | The server answered, but its model list doesn't have your Model. Check the model name. |
| Reachable, but no model | The InvokeAI server answered, but Model is empty. Pick an installed model. |
| Didn't answer | The server is off, the address is wrong, or CORS blocks the app |
The check reads ComfyUI's node list, or the model list of InvokeAI, Automatic1111 / Forge and OpenAI-compatible servers. It never generates an image, so it costs no credits. NovelAI has no free check, so it shows no badge. OpenAI-compatible servers show a badge in the desktop app only.
Most PCs have one graphics card. When a text model and an image model run on one card at the same time, both move into system memory and get very slow. So Formamorph never runs them at the same time:
- A scene image starts after the turn's text is complete.
- Your next action waits until the image is done.
- An image you ask for during a turn starts when the turn ends.
- A rewind or a re-generate stops the image in progress.
Each turn with Scene Images on takes as long as your image server needs.
Playing
- ๐ Connect Your Own AI
- ๐ฑ Install on Android
- ๐ Library
- ๐ง Avatars
- ๐ช Starting a Game
- ๐ฎ How to Play
- โ Formaquestion
- ๐พ Saves and Backup
- ๐ง Story Memory
- ๐ญ Entities in Game
- ๐ชช Personas
- ๐ Community Creations
- โ๏ธ Settings
Reference
- ๐ค Glossary
- โ๏ธ Text Formatting
- ๐ ๏ธ World Editor
- ๐งช Test Bench
- ๐ชช Personas for Authors
- ๐ World Format
- ๐งฎ Stat Code Guide
- ๐ Linked Content
Project