Model API'si

FLUX.1 [dev] with Controlnets and Loras

FLUX.1 diferansiyel difüzyon ile görseli bir değişim haritasına göre düzenle.

Model kimliği

Her istekte bunu kullan
flux-general/differential-diffusion

Çalıştır

Girdiye ücret teklifi al, bu teklifle üretimi başlat, ardından işin durumunu sorgula. Önce RAYWAKE_API_KEY değişkenini ayarla; ayrıntılar için Kimlik doğrulama sayfasına bak.

# 1. Price the exact input (quotes are valid for up to 10 minutes)
curl -s https://api.raywake.com/v1/quotes \
  -H "Authorization: Bearer $RAYWAKE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "model": "flux-general/differential-diffusion",
  "input": {
    "prompt": "A red ceramic cup on a wooden table, soft morning light",
    "image_url": "https://example.com/input.png",
    "change_map_image_url": "https://example.com/input.png"
  }
}'

# 2. Start the generation with the quote_id from step 1
curl -s https://api.raywake.com/v1/generate \
  -H "Authorization: Bearer $RAYWAKE_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"model": "flux-general/differential-diffusion", "quote_id": "QUOTE_ID", "input": {"prompt":"A red ceramic cup on a wooden table, soft morning light","image_url":"https://example.com/input.png","change_map_image_url":"https://example.com/input.png"}}'

# 3. Poll until the status is terminal
curl -s https://api.raywake.com/v1/jobs/JOB_ID \
  -H "Authorization: Bearer $RAYWAKE_API_KEY"

Girdi

flux-general/differential-diffusion girdi alanları
AlanTürAçıklama
promptzorunlustring
The prompt to generate an image from.
image_sizestring (enum)
The size of the generated image.

Seçenekler: square_hd, square, portrait_4_3, portrait_16_9, landscape_4_3, landscape_16_9

num_inference_stepsinteger
The number of inference steps to perform.

Varsayılan: 28

seedinteger
The same seed and the same prompt given to the same version of the model will output the same image every time.
lorasarray of objects
The LoRAs to use for the image generation. You can use any number of LoRAs and they will be merged together to generate the final image.
control_lorasarray of objects
The LoRAs to use for the image generation which use a control image. You can use any number of LoRAs and they will be merged together to generate the final image.
controlnetsarray of objects
The controlnets to use for the image generation. Only one controlnet is supported at the moment.
controlnet_unionsarray of objects
The controlnet unions to use for the image generation. Only one controlnet is supported at the moment.
ip_adaptersarray of objects
IP-Adapter to use for image generation.
easycontrolsarray of objects
EasyControl Inputs to use for image generation.
fill_imageobject
Use an image input to influence the generation. Can be used to fill images in masked areas.
guidance_scalenumber
The CFG (Classifier Free Guidance) scale is a measure of how close you want the model to stick to your prompt when looking for a related image to show you.

Varsayılan: 3.5

real_cfg_scalenumber
The CFG (Classifier Free Guidance) scale is a measure of how close you want the model to stick to your prompt when looking for a related image to show you.

Varsayılan: 3.5

use_real_cfgboolean
Uses classical CFG as in SD1.5, SDXL, etc. Increases generation times and price when set to be true. If using XLabs IP-Adapter v1, this will be turned on!.

Varsayılan: false

use_cfg_zeroboolean
Uses CFG-zero init sampling as in https://arxiv.org/abs/2503.18886.

Varsayılan: false

sync_modeboolean
If `True`, the media will be returned as a data URI and the output data won't be available in the request history.

Varsayılan: false

num_imagesinteger
The number of images to generate. This is always set to 1 for streaming output.

Varsayılan: 1

reference_image_urlstring (image URL)
URL of Image for Reference-Only
reference_strengthnumber
Strength of reference_only generation. Only used if a reference image is provided.

Varsayılan: 0.65

reference_startnumber
The percentage of the total timesteps when the reference guidance is to bestarted.

Varsayılan: 0

reference_endnumber
The percentage of the total timesteps when the reference guidance is to be ended.

Varsayılan: 1

base_shiftnumber
Base shift for the scheduled timesteps

Varsayılan: 0.5

max_shiftnumber
Max shift for the scheduled timesteps

Varsayılan: 1.15

output_formatstring (enum)
The format of the generated image.

Varsayılan: png

Seçenekler: jpeg, png

use_beta_scheduleboolean
Specifies whether beta sigmas ought to be used.

Varsayılan: false

sigma_schedulestring
Sigmas schedule for the denoising process.
schedulerstring (enum)
Scheduler for the denoising process.

Varsayılan: euler

Seçenekler: euler, dpmpp_2m

negative_promptstring
Negative prompt to steer the image generation away from unwanted features. By default, we will be using NAG for processing the negative prompt.
nag_scalenumber
The scale for NAG. Higher values will result in a image that is more distant to the negative prompt.

Varsayılan: 3

nag_taunumber
The tau for NAG. Controls the normalization of the hidden state. Higher values will result in a less aggressive normalization, but may also lead to unexpected changes with respect to the original image. Not recommended to change this value.

Varsayılan: 2.5

nag_alphanumber
The alpha value for NAG. This value is used as a final weighting factor for steering the normalized guidance (positive and negative prompts) in the direction of the positive prompt. Higher values will result in less steering on the normalized guidance where lower values will result in considering the positive prompt guidance more.

Varsayılan: 0.25

nag_endnumber
The proportion of steps to apply NAG. After the specified proportion of steps has been iterated, the remaining steps will use original attention processors in FLUX.

Varsayılan: 0.25

image_urlzorunlustring (image URL)
URL of image to use as initial image.
change_map_image_urlzorunlustring (image URL)
URL of change map.
strengthnumber
The strength to use for differential diffusion. 1.0 is completely remakes the image while 0.0 preserves the original.

Varsayılan: 0.85

Çıktı

Başarılı bir iş, sonuçlarını outputs altında listeler; dosyalar bizim tarafımızda saklanır. Tüm alanlar için İşler sayfasına bak.

İş yanıtından bir bölüm
"outputs": [
  { "type": "image", "url": "https://…", "mime_type": "image/png", "thumbnail_url": "https://…" }
]

Fiyatlandırma

  • en fazla$0,60/ üretim

Girdinin kesin ücreti ücret teklifinden gelir. Bakiye nasıl kesinleşir?