Repository navigation
🖼️ docs: Retire DALL-E 3 and Document the GPT Image Flare Default #834
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
767a8d2
5285b67
7da4901
ced3a94
21e9dc1
4183379
8a5e923
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -31,8 +31,8 @@ Get image generation working in a few minutes with OpenAI Image Tools. | |
|
|
||
| ```bash filename=".env" | ||
| IMAGE_GEN_OAI_API_KEY=sk-your-openai-api-key | ||
| # Optional; defaults to gpt-image-1 | ||
| IMAGE_GEN_OAI_MODEL=gpt-image-1 | ||
| # Optional; defaults to gpt-image-2.5-flare | ||
| IMAGE_GEN_OAI_MODEL=gpt-image-2.5-flare | ||
| ``` | ||
|
|
||
| </Step> | ||
|
|
@@ -61,7 +61,7 @@ IMAGE_GEN_OAI_MODEL=gpt-image-1 | |
| - **Image Generation** creates brand-new images from text prompts (no upload required). | ||
| - **Image Editing** edits or remixes images you uploaded: change colors, add objects, extend the canvas, and more. | ||
|
|
||
| Both default to **GPT-Image-1** for instruction following, text rendering, detailed editing, and real-world knowledge. Use `IMAGE_GEN_OAI_MODEL` to choose a different OpenAI image model when your deployment supports it. See OpenAI's [Image Generation documentation](https://platform.openai.com/docs/guides/image-generation?image-generation-model=gpt-image-1) for more details. | ||
| Both default to `gpt-image-2.5-flare`. Use `IMAGE_GEN_OAI_MODEL` to choose a different OpenAI image model when your deployment supports it. OpenAI retires `gpt-image-1` on October 23, 2026, so remove it from `IMAGE_GEN_OAI_MODEL` if you set it explicitly. See OpenAI's [Image Generation documentation](https://platform.openai.com/docs/guides/image-generation) for more details. | ||
|
berry-13 marked this conversation as resolved.
berry-13 marked this conversation as resolved.
|
||
|
|
||
| ### Generation vs. Editing | ||
|
|
||
|
|
@@ -86,35 +86,39 @@ Both tools are always available, and the agent chooses the appropriate one based | |
| **Image Generation** | ||
|
|
||
| - **prompt**: text description (required) | ||
| - **size**: `auto` (default), `1024x1024` (square), `1536x1024` (landscape), or `1024x1536` (portrait) | ||
| - **size**: `auto` (default), `1024x1024` (square), `1536x1024` (landscape), or `1024x1536` (portrait); models that support custom dimensions, such as `gpt-image-2.5-flare`, accept any `WIDTHxHEIGHT` within their limits, for example `2048x1152` or `3840x2160` | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
When a user requests the newly advertised Useful? React with 👍 / 👎.
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fixed in 8a5e923. Confirmed on LibreChat dev: tool images are saved through saveBase64Image with fileConfig.imageGeneration defaulting to 'high', which caps the short edge at 768px (resize.js), so 3840x2160 is stored at 1365x768. A callout under Parameters now says so and links fileConfig.imageGeneration with percentage: 100 or a px cap; the image-gen-default-model-matches-code scenario asserts the text and follows the link to #imagegeneration. |
||
| - **quality**: `auto` (default), `high`, `medium`, or `low` | ||
| - **background**: `auto` (default), `transparent`, or `opaque` (transparent requires PNG or WebP format) | ||
|
|
||
| **Image Editing** | ||
|
|
||
| - **image_ids**: array of image IDs to use as reference for editing (required) | ||
| - **prompt**: text description of the changes (required) | ||
| - **size**: `auto` (default), `1024x1024`, `1536x1024`, `1024x1536`, `256x256`, or `512x512` | ||
| - **size**: `auto` (default), `1024x1024`, `1536x1024`, or `1024x1536`; models that support custom dimensions accept any `WIDTHxHEIGHT` within their limits, for example `3840x2160` | ||
| - **quality**: `auto` (default), `high`, `medium`, or `low` | ||
|
|
||
| <Callout type="info" title="Keeping large sizes"> | ||
| By default, LibreChat resizes saved images so their shorter side is at most 768 pixels, so a `3840x2160` result is stored at 1365x768. To keep the requested size, set [`fileConfig.imageGeneration`](/docs/configuration/librechat_yaml/object_structure/file_config#imagegeneration) to `percentage: 100`, or to a `px` cap large enough for your sizes. | ||
| </Callout> | ||
|
|
||
| ### Setup | ||
|
|
||
| Create or reuse an OpenAI key and add it to `.env`, then add "OpenAI Image Tools" to your agent's **Tools** list: | ||
|
|
||
| ```bash filename=".env" | ||
| IMAGE_GEN_OAI_API_KEY=sk-... | ||
| # optional extras | ||
| IMAGE_GEN_OAI_MODEL=gpt-image-1 | ||
| IMAGE_GEN_OAI_MODEL=gpt-image-2.5-flare | ||
| IMAGE_GEN_OAI_BASEURL=https://... | ||
| ``` | ||
|
|
||
| For Azure OpenAI deployments, first request access at https://aka.ms/oai/gptimage1access, then add your credentials to `.env`: | ||
| For Azure OpenAI, deploy an image model in your Azure OpenAI resource, then add your credentials to `.env`. Set `IMAGE_GEN_OAI_MODEL` to the deployment name: | ||
|
|
||
| ```bash filename=".env" | ||
| IMAGE_GEN_OAI_API_KEY=your-api-key | ||
| # optional extras | ||
| IMAGE_GEN_OAI_MODEL=gpt-image-1 | ||
| IMAGE_GEN_OAI_BASEURL=https://deploymentname.openai.azure.com/openai/deployments/gpt-image-1/ | ||
| IMAGE_GEN_OAI_MODEL=your-deployment-name | ||
| IMAGE_GEN_OAI_BASEURL=https://your-resource-name.openai.azure.com/openai/deployments/your-deployment-name/ | ||
| IMAGE_GEN_OAI_AZURE_API_VERSION=2025-04-01-preview | ||
| ``` | ||
|
|
||
|
|
@@ -124,7 +128,7 @@ Customize the tool descriptions and prompt guidance with these environment varia | |
|
|
||
| ```bash filename=".env" | ||
| # Image Model | ||
| IMAGE_GEN_OAI_MODEL=gpt-image-1 | ||
| IMAGE_GEN_OAI_MODEL=gpt-image-2.5-flare | ||
|
|
||
| # Image Generation Tool Descriptions | ||
| IMAGE_GEN_OAI_DESCRIPTION=... | ||
|
|
@@ -137,7 +141,7 @@ IMAGE_EDIT_OAI_PROMPT_DESCRIPTION=... | |
|
|
||
| ### Pricing | ||
|
|
||
| See the [GPT-Image-1 pricing page](https://platform.openai.com/docs/models/gpt-image-1) and [Image Generation documentation](https://platform.openai.com/docs/guides/image-generation?image-generation-model=gpt-image-1#cost-and-latency) for image generation costs. | ||
| See OpenAI's [API pricing page](https://openai.com/api/pricing/) and [Image Generation documentation](https://platform.openai.com/docs/guides/image-generation) for image generation costs. | ||
|
|
||
| ## Gemini Image Tools | ||
|
|
||
|
|
@@ -191,46 +195,6 @@ GEMINI_IMAGE_IDS_DESCRIPTION=... | |
|
|
||
| More details are in the dedicated [Gemini Image Gen guide](/docs/configuration/tools/gemini_image_gen). | ||
|
|
||
| ## DALL·E (legacy) | ||
|
|
||
| DALL·E provides legacy image generation using OpenAI's `dall-e-3` image model. | ||
|
|
||
| ### Parameters | ||
|
|
||
| - **prompt**: text description of the desired image (required, up to 4000 characters) | ||
| - **style**: `vivid` (hyper-real, dramatic, default) or `natural` (less hyper-real) | ||
| - **quality**: `standard` (default) or `hd` | ||
| - **size**: `1024x1024` (default, square), `1792x1024` (wide), or `1024x1792` (tall) | ||
|
|
||
| ### Setup | ||
|
|
||
| ```bash filename=".env" | ||
| # Required | ||
| DALLE_API_KEY=sk-... # or DALLE3_API_KEY=sk-... | ||
|
|
||
| # Optional | ||
| DALLE_REVERSE_PROXY=https://... # Alternative endpoint | ||
| DALLE3_BASEURL=https://... # For Azure or custom endpoints | ||
| DALLE3_AZURE_API_VERSION=2023-12-01-preview # For Azure deployments | ||
| DALLE3_SYSTEM_PROMPT=... # Custom system prompt for DALL·E | ||
| ``` | ||
|
|
||
| Enable the **DALL·E** tool for the agent and start prompting. | ||
|
|
||
| ### Advanced Configuration | ||
|
|
||
| For Azure OpenAI deployments, configure the base URL and API version: | ||
|
|
||
| ```bash filename=".env" | ||
| DALLE3_BASEURL=https://your-resource-name.openai.azure.com/openai/deployments/your-deployment-name | ||
| DALLE3_AZURE_API_VERSION=2023-12-01-preview | ||
| DALLE3_API_KEY=your-azure-api-key | ||
| ``` | ||
|
|
||
| ### Pricing | ||
|
|
||
| See the [DALL-E pricing page](https://platform.openai.com/docs/models/dall-e-3) and [Image Generation documentation](https://platform.openai.com/docs/guides/image-generation?image-generation-model=dall-e-3) for image generation costs. | ||
|
|
||
| ## Stable Diffusion (local) | ||
|
|
||
| Run images entirely on your own machine or server. Point LibreChat at any Automatic1111 (or compatible) endpoint and you're set. | ||
|
|
@@ -371,7 +335,7 @@ If a tool encounters an error, it returns a message explaining what went wrong. | |
|
|
||
| ## Prompting | ||
|
|
||
| You can customize the prompts for [OpenAI Image Tools](#advanced-configuration) and [DALL·E](#advanced-configuration-2), but the following tips inform the default prompts the tools supply, which is useful to know for your own writing: | ||
| You can customize the prompts for [OpenAI Image Tools](#advanced-configuration), but the following tips inform the default prompts the tool supplies, which is useful to know for your own writing: | ||
|
|
||
| 1. Start with the **subject** and **style** (photo, oil painting, etc.). | ||
| 2. Add **composition** and **camera/medium** ("wide-angle shot of…", "watercolour…"). | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,57 @@ | ||
| import { test, expect } from '@playwright/test' | ||
|
|
||
| test.describe('Image generation docs', () => { | ||
| test('@scenario:image-gen-page-has-no-dalle-setup no page documents the retired DALL-E tool', async ({ | ||
| page, | ||
| }) => { | ||
| await page.goto('/docs/features/image_gen') | ||
| const main = page.locator('main') | ||
| await expect(page.getByRole('heading', { level: 1 }).first()).toBeVisible() | ||
| await expect(main.getByRole('heading', { name: /dall/i })).toHaveCount(0) | ||
| await expect(main).not.toContainText(/DALLE_API_KEY|DALLE3_/) | ||
|
|
||
| await page.goto('/docs/configuration/librechat_yaml/ai_endpoints/azure') | ||
| const azure = page.locator('main') | ||
| await expect(azure.getByRole('heading', { name: /generate images with azure/i })).toBeVisible() | ||
| await expect(azure).not.toContainText(/DALL-?E/i) | ||
| await expect(azure).toContainText('IMAGE_GEN_OAI_BASEURL') | ||
| }) | ||
|
|
||
| test('@scenario:image-gen-default-model-matches-code the documented default is gpt-image-2.5-flare', async ({ | ||
| page, | ||
| }) => { | ||
| await page.goto('/docs/features/image_gen') | ||
| const main = page.locator('main') | ||
| await expect(main).toContainText('defaults to gpt-image-2.5-flare') | ||
| await expect(main).not.toContainText('IMAGE_GEN_OAI_MODEL=gpt-image-1') | ||
| await expect(main).not.toContainText(/defaults? to \**gpt-image-1/i) | ||
| await expect(main).toContainText('accept any WIDTHxHEIGHT') | ||
| await expect(main).toContainText('stored at 1365x768') | ||
| const resizeLink = main.getByRole('link', { name: 'fileConfig.imageGeneration' }) | ||
| await expect(resizeLink).toHaveAttribute('href', /file_config#imagegeneration$/) | ||
| await resizeLink.click() | ||
| await expect(page.locator('[id="imagegeneration"]')).toHaveCount(1) | ||
| }) | ||
|
|
||
| test('@scenario:tools-table-and-agent-lists-omit-dalle feature cards and tool lists omit DALL-E and image links resolve', async ({ | ||
| page, | ||
| }) => { | ||
| const anchors = new Set<string>() | ||
| for (const path of ['/docs/features', '/docs/configuration/tools', '/docs/features/agents']) { | ||
| await page.goto(path) | ||
| const main = page.locator('main') | ||
| await expect(page.getByRole('heading', { level: 1 }).first()).toBeVisible() | ||
| await expect(main).not.toContainText(/DALL-?E/i) | ||
| const hrefs = await main | ||
| .locator('a[href*="/docs/features/image_gen#"]') | ||
| .evaluateAll((links) => links.map((link) => link.getAttribute('href') ?? '')) | ||
| for (const href of hrefs) anchors.add(href.split('#')[1]) | ||
| } | ||
|
|
||
| expect(anchors.size).toBeGreaterThan(0) | ||
| await page.goto('/docs/features/image_gen') | ||
| for (const anchor of anchors) { | ||
| await expect(page.locator(`[id="${anchor}"]`)).toHaveCount(1) | ||
| } | ||
| }) | ||
| }) |
Uh oh!
There was an error while loading. Please reload this page.