Skip to content

AionUi Image Generation Tool Model Configuration Guide

Waili(็“ฆ็ พ) edited this page May 27, 2026 · 4 revisions

๐ŸŽจ AionUi Image Generation Tool โ€” Model Configuration Guide

This guide shows how to enable AionUi's image generation tool and pick a backend model. AionUi can drive image generation through several platforms โ€” both chat-completion-style (Gemini, OpenRouter) and dedicated images APIs (OpenAI, Stability AI, DashScope, Together AI).

English | ็ฎ€ไฝ“ไธญๆ–‡


๐ŸŽฏ How it works

AionUi's image tool supports two API shapes and routes each provider to the right adapter automatically:

Shape Used by Endpoint
Chat Completion (multimodal) Gemini, Gemini (Vertex AI), OpenRouter, AntigravityTools OpenAI-compatible /v1/chat/completions returning image parts
Dedicated Images API OpenAI, Stability AI, Alibaba DashScope, Together AI /v1/images/* returning b64_json

Only models that AionUi's allowlist recognizes will appear in the picker โ€” this prevents accidentally selecting a text-only model. The allowlist matches both the platform (or base URL) and the model name pattern (image, dall-e, flux, stable, sd<n>, wanx, imagen, banana, imagine, etc.).

๐Ÿ’ก If your platform has no allowlisted image model yet, AionUi auto-injects a sensible default (see below) so the feature still works out of the box.


๐Ÿš€ Recommended path: Gemini

The fastest, cheapest, and easiest setup.

1. Get a Gemini API Key

  1. Visit https://aistudio.google.com/
  2. Sign in with your Google account
  3. Create a new API Key

2. Add Gemini to AionUi

  1. Settings โ†’ Models โ†’ Add Model
  2. Select Gemini
  3. Paste your API Key, save

Configure LLM example

3. Enable the image tool

  1. Settings โ†’ Tools โ†’ Image Generation
  2. Toggle on
  3. From the model dropdown pick gemini-2.5-flash-image-preview (auto-injected if Gemini has no other image model in your config)
  4. Save

Set tool LLM example


๐ŸŒ OpenRouter

OpenRouter aggregates many image-gen models. Most are paid; AionUi auto-adds a free Gemini option as a fallback.

1. Get an OpenRouter key

  1. Sign in at https://openrouter.ai/
  2. Create a key at https://openrouter.ai/keys โ€” copy it (shown only once)

Create OpenRouter API Key

2. Add OpenRouter to AionUi

  1. Settings โ†’ Models โ†’ Add Model
  2. Select OpenRouter, paste the key, save

3. Pick an image model

  1. Settings โ†’ Tools โ†’ Image Generation
  2. Pick any allowlisted OpenRouter model in the dropdown
  3. Default fallback: google/gemini-2.5-flash-image-preview (free)

๐Ÿ’ธ Most non-Gemini OpenRouter image models are paid โ€” check pricing on OpenRouter before committing.


๐Ÿ”Œ Other supported platforms

These work the same way: add the platform under Settings โ†’ Models, then pick an allowlisted model in Settings โ†’ Tools โ†’ Image Generation.

Platform API shape Recognized model patterns Notes
Gemini Chat *-image-*, gemini-*image* Default: gemini-2.5-flash-image-preview
Gemini (Vertex AI) Chat same as Gemini Enterprise variant
OpenRouter Chat image, dall-e, flux, stable, etc. Default: google/gemini-2.5-flash-image-preview
AntigravityTools Chat image-capable models Default: gemini-3-pro-image-1x1
OpenAI Images API gpt-image-*, dall-e-* Requires images-API access
Stability AI Images API stable-*, sd<n>, ultra, core Requires Stability key
Alibaba DashScope Images API wanx-*, image-* Requires DashScope key
Together AI Images API flux-* Requires Together key

โœ… Verify the setup

  1. Open a conversation with any tool-capable model

  2. Ask "what tools do you have?" โ€” image-generation should appear in the list

    Tool list example

  3. Try a generation prompt, e.g.:

    Generate a 1024ร—1024 blue neon cyberpunk city nightscape

    Image generation test


โ“ FAQ

Q: Which model gives the best free experience?

A: gemini-2.5-flash-image-preview โ€” fast, free with a Gemini API key, decent quality.

Q: I added a model but it doesn't show up in the picker.

A: AionUi only lists allowlisted image models. Either the model name doesn't match the pattern (e.g., image, flux, dall-e, stable, sd<n>, wanx) or the platform/base URL isn't recognized. Rename the model entry to include a recognized keyword, or use one of the supported platforms above.

Q: Tool list doesn't show image-generation.

A: Make sure (1) image generation is toggled on in Settings โ†’ Tools, (2) a model is selected and saved, (3) you start a fresh conversation after saving.

Q: API key invalid?

A: Check the key is copied without whitespace and that the corresponding platform account is active and has billing/quota set up where required.

Q: Generation failed mid-request?

A: Usually a network timeout, expired token, or quota exhaustion on the upstream platform. Check the platform's dashboard.

Q: How do I switch models for image gen?

A: Settings โ†’ Tools โ†’ Image Generation โ†’ Model โ€” dropdown lists every allowlisted model from your configured platforms.


๐Ÿ”— References


Need Help?

๐Ÿš€ AionUi Wiki

Welcome to the comprehensive AionUi documentation! Find everything you need to configure, use, and master AionUi.


๐Ÿ  Home


๐Ÿ“š Configuration & Usage Guides

Overview

Getting Started

Core Configuration

Support


๐ŸŽฏ Application Use Cases

Overview

Featured Use Cases


๐ŸŒ Language Switch


๐Ÿ”— Quick Links


๐Ÿค Community

Clone this wiki locally