inference.moss-image.sft.flow.txt2img.v1
The inference.moss-image.sft.flow.txt2img.v1 job generates an image from
a text prompt with a fast version of MOSS-Image, OpenMOSS’s open-weight
text-to-image model. It returns an image in well under a second at
1024x1024 and keeps MOSS-Image’s strengths: long English and Chinese text
rendering and JSON layouts. Output is 1024x1024 by default.
{ "type": "inference.moss-image.sft.flow.txt2img.v1", "config": { "prompt": "A wide view of a refrigerator beside a kitchen counter with a fruit bowl. A small sticky note on the refrigerator door is handwritten: \"Buy milk and eggs!\"" }}Prompting
Section titled “Prompting”The prompt is used exactly as written. It can be natural language (English
works best, Chinese and other languages are supported), a tag sequence, or a
JSON layout in the same format as inference.moss-image.sft.txt2img.v1. Put
the exact text to render in quotes.
The model reads at most 4096 tokens (about 16,000 characters of English, fewer for Chinese); anything beyond that is cut off.
There is no negative_prompt or guidance_scale: describe what you want in
the prompt.
steps (1-50, default 4) trades speed for detail. One or two steps already
give a sharp, complete image; more steps add fine detail and take
proportionally longer. Images change little past about 16 steps.
width and height can each be any integer from 512 to 2048 (default
1024). The model works best at about 1 megapixel, e.g. 1024x1024, 1248x832
or 832x1248.
The same seed reproduces the same image. With the same seed, different
steps values give closely related images, so you can preview with 1 step
and refine with more.
Latency
Section titled “Latency”Typical latency on a warm worker is about 0.5 s at 1024x1024 with the default 4 steps.
Schema
Section titled “Schema”{ "type": "object", "required": [ "type", "config" ], "additionalProperties": false, "properties": { "type": { "type": "string", "enum": [ "inference.moss-image.sft.flow.txt2img.v1" ] }, "config": { "type": "object", "required": [ "prompt" ], "additionalProperties": false, "properties": { "prompt": { "type": "string", "minLength": 1, "maxLength": 16384, "examples": [ "A wide view of a refrigerator beside a kitchen counter with a fruit bowl. A small sticky note on the refrigerator door is handwritten: \"Buy milk and eggs!\"" ], "description": "The prompt to generate an image from, used verbatim: natural language, a tag sequence or a JSON layout. Text beyond the model's 4096-token limit (about 16,000 characters of English, fewer for Chinese) is cut off." }, "width": { "type": "integer", "minimum": 512, "maximum": 2048, "default": 1024, "description": "Output image width in pixels, 512 to 2048." }, "height": { "type": "integer", "minimum": 512, "maximum": 2048, "default": 1024, "description": "Output image height in pixels, 512 to 2048." }, "steps": { "type": "integer", "minimum": 1, "maximum": 50, "default": 4, "description": "Number of sampling steps, 1 to 50. 1-2 steps are already sharp; more steps add fine detail (little changes past about 16) and take proportionally longer." }, "seed": { "type": "integer", "minimum": 0, "maximum": 2147483647, "description": "Random seed for reproducible results." } } } }}