AI Layout Generation
How Lega turns a text prompt into a real, layered composition — and how to write prompts that get you a strong first draft.
Every Lega design starts the same way: you describe what you want, and the AI builds it as real layers on the canvas. This page covers what's happening when you generate a layout, and how to prompt it well.
What "layout generation" actually produces
When you type a prompt and hit generate, Lega isn't producing an image. It's producing a structured composition — text layers with actual copy, shapes and decorative elements positioned with intent, images placed and sized, everything grouped the way a human designer would group it. The AI is reasoning about layout principles (hierarchy, balance, spacing, contrast) and emitting a layer tree, not painting pixels.
That's why the result opens straight into the editor as editable content. You can click any text layer and retype it, drag a shape two pixels to the left, or delete an element entirely — the same way you'd edit anything you built by hand. See What is Lega? for the layers-not-pixels framing this is built on.
What goes into a generation
A layout generation call considers:
- Your prompt — the subject, tone, and any explicit content you specify (headline text, a call to action, a specific color).
- Frame dimensions — the same prompt produces a different structure for a square Instagram post than for a tall story or a wide banner, because the AI is designing to the actual canvas.
- Brand context, if you've set one up — saved colors and fonts bias the generation toward your kit instead of picking arbitrary ones. See Building Reusable Brand Kits.
The output includes both a layout (positions, structure, layer types) and, unless you request otherwise, a style pass — colors, type choices, and treatment. Style can also be regenerated independently; see AI Style Generation if you want to keep a layout but try a different look.
Writing prompts that work
Layout generation responds best to prompts that separate what from how:
- Be concrete about content. "A sale announcement for a 20%-off weekend at a coffee shop" gives the AI something to design around. "A nice poster" doesn't.
- Name the format if it matters. "Instagram story," "printable flyer," "presentation slide" all imply different aspect ratios and information density — set your frame size accordingly, or say so in the prompt.
- Give a tone, not a spec. "Bold and minimal" or "warm and playful" steers style meaningfully. Pixel-level instructions ("put the logo at 40px from the top") don't — that's what the editor is for after generation.
- One clear subject per generation. Prompts that try to cram three separate ideas into one frame tend to produce cluttered results. Generate the primary idea, then use Perfect-It or manual edits to add supporting details.
For a deeper framework with more examples, see AI design prompts that work.
Regenerating instead of starting over
You rarely need to throw away a whole layout because one part is off. Lega's chat-driven refine flow lets you target a specific layer or region and regenerate just that piece — swap out a single graphic, restructure one section, or ask for a different treatment on the headline — while the rest of the frame stays untouched. This is usually faster than re-prompting the whole frame and rerolling the parts that were already working.
Layout generation vs. templates
Layout generation and templates solve different problems. A template is a fixed, pre-built starting structure you customize; a generated layout is built fresh from your description each time, so two different prompts produce two different structures rather than the same skeleton with different copy. If you want a known-good structure to build from quickly, Using Templates is the faster path — you can still run AI style or refine passes on top of a template afterward.
Credits and limits
Each layout generation counts against your plan's monthly AI usage. See Understanding AI Credits & Limits for how usage is tracked and what happens if you hit your limit mid-project.