Failed to load versions. Head to the versions page to see all versions for this model.
You're looking at a specific version of this model. Jump to the model overview.
cfbach /greeting-card-generator-flux:211401c8
Input
Run this model in Node.js with one line of code:
npm install replicate
REPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
import Replicate from "replicate";
import fs from "node:fs";
const replicate = new Replicate({
auth: process.env.REPLICATE_API_TOKEN,
});
Run cfbach/greeting-card-generator-flux using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"cfbach/greeting-card-generator-flux:211401c8c2662ecd38f3346a9bc686ed2f206532e9274ef04a50336907d09e90",
{
input: {
model: "dev",
width: 832,
height: 1216,
prompt: "The image is a photograph of a celebratory greeting card displayed on a shelf in a store. The card features a the text \"Congrats on the layoffs\" and dollar bills.",
go_fast: true,
lora_scale: 1,
megapixels: "1",
num_outputs: 1,
aspect_ratio: "custom",
output_format: "jpg",
guidance_scale: 3,
output_quality: 80,
prompt_strength: 0.8,
extra_lora_scale: 1,
num_inference_steps: 35
}
}
);
// To access the file URL:
console.log(output[0].url()); //=> "http://example.com"
// To write the file to disk:
fs.writeFile("my-image.png", output[0]);
To learn more, take a look at the guide on getting started with Node.js.
pip install replicate
REPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
import replicate
Run cfbach/greeting-card-generator-flux using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"cfbach/greeting-card-generator-flux:211401c8c2662ecd38f3346a9bc686ed2f206532e9274ef04a50336907d09e90",
input={
"model": "dev",
"width": 832,
"height": 1216,
"prompt": "The image is a photograph of a celebratory greeting card displayed on a shelf in a store. The card features a the text \"Congrats on the layoffs\" and dollar bills.",
"go_fast": True,
"lora_scale": 1,
"megapixels": "1",
"num_outputs": 1,
"aspect_ratio": "custom",
"output_format": "jpg",
"guidance_scale": 3,
"output_quality": 80,
"prompt_strength": 0.8,
"extra_lora_scale": 1,
"num_inference_steps": 35
}
)
print(output)
To learn more, take a look at the guide on getting started with Python.
REPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Run cfbach/greeting-card-generator-flux using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
curl -s -X POST \
-H "Authorization: Bearer $REPLICATE_API_TOKEN" \
-H "Content-Type: application/json" \
-H "Prefer: wait" \
-d $'{
"version": "cfbach/greeting-card-generator-flux:211401c8c2662ecd38f3346a9bc686ed2f206532e9274ef04a50336907d09e90",
"input": {
"model": "dev",
"width": 832,
"height": 1216,
"prompt": "The image is a photograph of a celebratory greeting card displayed on a shelf in a store. The card features a the text \\"Congrats on the layoffs\\" and dollar bills.",
"go_fast": true,
"lora_scale": 1,
"megapixels": "1",
"num_outputs": 1,
"aspect_ratio": "custom",
"output_format": "jpg",
"guidance_scale": 3,
"output_quality": 80,
"prompt_strength": 0.8,
"extra_lora_scale": 1,
"num_inference_steps": 35
}
}' \
https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
Add a payment method to run this model.
By signing in, you agree to our
terms of service and privacy policy
Output
{
"completed_at": "2025-02-18T13:46:59.406520Z",
"created_at": "2025-02-18T13:46:49.932000Z",
"data_removed": false,
"error": null,
"id": "y280fwxrshrmc0cn357rxvty04",
"input": {
"model": "dev",
"width": 832,
"height": 1216,
"prompt": "The image is a photograph of a celebratory greeting card displayed on a shelf in a store. The card features a the text \"Congrats on the layoffs\" and dollar bills.",
"go_fast": true,
"lora_scale": 1,
"megapixels": "1",
"num_outputs": 1,
"aspect_ratio": "custom",
"output_format": "jpg",
"guidance_scale": 3,
"output_quality": 80,
"prompt_strength": 0.8,
"extra_lora_scale": 1,
"num_inference_steps": 35
},
"logs": "Custom aspect ratios not supported with fast fp8 inference; will run in bf16\nLoaded LoRAs in 0.50s\nUsing seed: 54321\nPrompt: The image is a photograph of a celebratory greeting card displayed on a shelf in a store. The card features a the text \"Congrats on the layoffs\" and dollar bills.\n[!] txt2img mode\n 0%| | 0/35 [00:00<?, ?it/s]\n 3%|▎ | 1/35 [00:00<00:08, 4.04it/s]\n 6%|▌ | 2/35 [00:00<00:07, 4.57it/s]\n 9%|▊ | 3/35 [00:00<00:07, 4.31it/s]\n 11%|█▏ | 4/35 [00:00<00:07, 4.20it/s]\n 14%|█▍ | 5/35 [00:01<00:07, 4.14it/s]\n 17%|█▋ | 6/35 [00:01<00:07, 4.10it/s]\n 20%|██ | 7/35 [00:01<00:06, 4.09it/s]\n 23%|██▎ | 8/35 [00:01<00:06, 4.07it/s]\n 26%|██▌ | 9/35 [00:02<00:06, 4.06it/s]\n 29%|██▊ | 10/35 [00:02<00:06, 4.06it/s]\n 31%|███▏ | 11/35 [00:02<00:05, 4.05it/s]\n 34%|███▍ | 12/35 [00:02<00:05, 4.04it/s]\n 37%|███▋ | 13/35 [00:03<00:05, 4.04it/s]\n 40%|████ | 14/35 [00:03<00:05, 4.04it/s]\n 43%|████▎ | 15/35 [00:03<00:04, 4.04it/s]\n 46%|████▌ | 16/35 [00:03<00:04, 4.04it/s]\n 49%|████▊ | 17/35 [00:04<00:04, 4.04it/s]\n 51%|█████▏ | 18/35 [00:04<00:04, 4.04it/s]\n 54%|█████▍ | 19/35 [00:04<00:03, 4.04it/s]\n 57%|█████▋ | 20/35 [00:04<00:03, 4.04it/s]\n 60%|██████ | 21/35 [00:05<00:03, 4.04it/s]\n 63%|██████▎ | 22/35 [00:05<00:03, 4.04it/s]\n 66%|██████▌ | 23/35 [00:05<00:02, 4.04it/s]\n 69%|██████▊ | 24/35 [00:05<00:02, 4.04it/s]\n 71%|███████▏ | 25/35 [00:06<00:02, 4.04it/s]\n 74%|███████▍ | 26/35 [00:06<00:02, 4.04it/s]\n 77%|███████▋ | 27/35 [00:06<00:01, 4.04it/s]\n 80%|████████ | 28/35 [00:06<00:01, 4.04it/s]\n 83%|████████▎ | 29/35 [00:07<00:01, 4.04it/s]\n 86%|████████▌ | 30/35 [00:07<00:01, 4.04it/s]\n 89%|████████▊ | 31/35 [00:07<00:00, 4.04it/s]\n 91%|█████████▏| 32/35 [00:07<00:00, 4.04it/s]\n 94%|█████████▍| 33/35 [00:08<00:00, 4.04it/s]\n 97%|█████████▋| 34/35 [00:08<00:00, 4.04it/s]\n100%|██████████| 35/35 [00:08<00:00, 4.04it/s]\n100%|██████████| 35/35 [00:08<00:00, 4.06it/s]\nTotal safe images: 1 out of 1",
"metrics": {
"predict_time": 9.320651231,
"total_time": 9.47452
},
"output": [
"https://replicate.delivery/xezq/4LJxm8qfKtTxOy9cDtTtsoE2yPi4EJzH7DuOqFGEXQ4pCSIKA/out-0.jpg"
],
"started_at": "2025-02-18T13:46:50.085868Z",
"status": "succeeded",
"urls": {
"stream": "https://stream.replicate.com/v1/files/bcwr-w3ifb3honk6f3gien4wfmwbet4lys7lqrlmnzw3hxqrdfegkvpqa",
"get": "https://api.replicate.com/v1/predictions/y280fwxrshrmc0cn357rxvty04",
"cancel": "https://api.replicate.com/v1/predictions/y280fwxrshrmc0cn357rxvty04/cancel"
},
"version": "211401c8c2662ecd38f3346a9bc686ed2f206532e9274ef04a50336907d09e90"
}
Custom aspect ratios not supported with fast fp8 inference; will run in bf16
Loaded LoRAs in 0.50s
Using seed: 54321
Prompt: The image is a photograph of a celebratory greeting card displayed on a shelf in a store. The card features a the text "Congrats on the layoffs" and dollar bills.
[!] txt2img mode
0%| | 0/35 [00:00<?, ?it/s]
3%|▎ | 1/35 [00:00<00:08, 4.04it/s]
6%|▌ | 2/35 [00:00<00:07, 4.57it/s]
9%|▊ | 3/35 [00:00<00:07, 4.31it/s]
11%|█▏ | 4/35 [00:00<00:07, 4.20it/s]
14%|█▍ | 5/35 [00:01<00:07, 4.14it/s]
17%|█▋ | 6/35 [00:01<00:07, 4.10it/s]
20%|██ | 7/35 [00:01<00:06, 4.09it/s]
23%|██▎ | 8/35 [00:01<00:06, 4.07it/s]
26%|██▌ | 9/35 [00:02<00:06, 4.06it/s]
29%|██▊ | 10/35 [00:02<00:06, 4.06it/s]
31%|███▏ | 11/35 [00:02<00:05, 4.05it/s]
34%|███▍ | 12/35 [00:02<00:05, 4.04it/s]
37%|███▋ | 13/35 [00:03<00:05, 4.04it/s]
40%|████ | 14/35 [00:03<00:05, 4.04it/s]
43%|████▎ | 15/35 [00:03<00:04, 4.04it/s]
46%|████▌ | 16/35 [00:03<00:04, 4.04it/s]
49%|████▊ | 17/35 [00:04<00:04, 4.04it/s]
51%|█████▏ | 18/35 [00:04<00:04, 4.04it/s]
54%|█████▍ | 19/35 [00:04<00:03, 4.04it/s]
57%|█████▋ | 20/35 [00:04<00:03, 4.04it/s]
60%|██████ | 21/35 [00:05<00:03, 4.04it/s]
63%|██████▎ | 22/35 [00:05<00:03, 4.04it/s]
66%|██████▌ | 23/35 [00:05<00:02, 4.04it/s]
69%|██████▊ | 24/35 [00:05<00:02, 4.04it/s]
71%|███████▏ | 25/35 [00:06<00:02, 4.04it/s]
74%|███████▍ | 26/35 [00:06<00:02, 4.04it/s]
77%|███████▋ | 27/35 [00:06<00:01, 4.04it/s]
80%|████████ | 28/35 [00:06<00:01, 4.04it/s]
83%|████████▎ | 29/35 [00:07<00:01, 4.04it/s]
86%|████████▌ | 30/35 [00:07<00:01, 4.04it/s]
89%|████████▊ | 31/35 [00:07<00:00, 4.04it/s]
91%|█████████▏| 32/35 [00:07<00:00, 4.04it/s]
94%|█████████▍| 33/35 [00:08<00:00, 4.04it/s]
97%|█████████▋| 34/35 [00:08<00:00, 4.04it/s]
100%|██████████| 35/35 [00:08<00:00, 4.04it/s]
100%|██████████| 35/35 [00:08<00:00, 4.06it/s]
Total safe images: 1 out of 1