Core concepts
Image generation
Create images from natural-language prompts using IGen models. Control size, quality and the number of variations returned.
Generating an image
Send a prompt to the images endpoint. The response includes a URL (or base64 payload) for each generated image.
from tnsa import TNSA
client = TNSA()
result = client.images.generate(
model="IGen-1.5",
prompt="A watercolor fox sitting in a misty forest at dawn",
size="1024x1024",
n=1,
)
print(result.data[0].url)Parameters
prompt— a text description of the desired image.model— an IGen model id, e.g.IGen-1.5.size— output resolution such as512x512or1024x1024.n— number of images to generate (1–4).response_format—urlorb64_json.
Prompting tips
- Describe subject, style, lighting and composition explicitly.
- Use IGen-1 Nano or IGen-1 Fast for rapid drafts, then re-run with IGen-1.5 for the final.
- Iterate: small wording changes can meaningfully shift the result.
Browse all available image models on the Models page.