Flux.1 Schnell
Approved Data Classifications
Description
Flux.1 Schnell is a highly efficient open-source AI image generation model developed by Black Forest Labs, specifically designed for rapid image creation from text prompts. Launched as part of the Flux AI suite, this model excels in generating high-quality images in just 1 to 4 steps, significantly enhancing productivity for users across various creative fields. With its optimized architecture for speed, Flux.1 Schnell can produce stunning visuals quickly while maintaining impressive output quality, making it ideal for rapid prototyping and personal projects. The model supports a versatile range of artistic styles and formats, catering to diverse user preferences and skill levels through its user-friendly interface. Available under an Apache 2.0 license, Flux.1 Schnell is perfect for developers and enthusiasts looking to leverage fast image generation capabilities without compromising on quality.
Capabilities
Model | Training Data | Input | Output | Context Length | Cost (per image) |
---|---|---|---|---|---|
flux.1-schnell | May 2024 | Text | Image | n/a | $0.003/image |
- estimated image size is
1024
x1024
- All prices listed are based on 1 image
Availability
Cloud Provider
Usage
- curl
- python
- javascript
curl -X POST https://api.ai.it.ufl.edu/v1/images/generations \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <API_TOKEN>" \
-d '{
"model": "flux.1-schnell",
"prompt": "An Alligator walking around the University of Florida saying hi to students.",
"n": 1,
"size": "1024x1024",
"quality": "standard",
"response_format": "b64_json"
}'
from openai import OpenAI
client = OpenAI(
api_key="your_api_key",
base_url="https://api.ai.it.ufl.edu/v1"
)
response = client.images.generate(
model="flux.1-schnell",
prompt="An Alligator walking around the University of Florida saying hi to students.",
size="1024x1024",
quality="standard",
n=1,
response_format="url"
)
image_url = response.data[0].url
import OpenAI from 'openai';
const openai = new OpenAI({
apiKey: 'your_api_key',
baseURL: 'https://api.ai.it.ufl.edu/v1'
});
const completion = await openai.images.generate({
model: "flux.1-schnell",
prompt: "An Alligator walking around the University of Florida saying hi to students.",
n: 1,
size: "1024x1024",
quality: "standard",
response_format: "url",
});
image_url = response.data[0].url;