imagesarrayzorunlu
List of input image URLs for editing. Up to 4 images.
alibaba/wan/2.7/image-to-imageAlibaba Wan 2.7 image-to-image model that edits images from a natural-language instruction, with multi-reference support and selectable aspect ratio.
Modeli deneyin
PNG, JPEG, WebP, or GIF · 20 MiB maximum each
Bir örnek seçerek girdilerini ve sonucunu playground'a yükleyin.
{
"aspect_ratio": "9:16",
"images": [
"https://static.sandbase.ai/examples/0eeefa8f-0c4d-4a75-ad7e-6ead1df9e998/input/2a3945fe-b5cb-4a5c-bc95-e9b14b69d6ed.png"
],
"prompt": "Turn the scene into a snowy winter night"
}İnsan tercihi
Kör yan yana oylamalardan elde edilen Elo puanları, diğer görsel ve video modelleriyle karşılaştırılır.
Sıralamalar Artificial Analysis Arena kaynaklıdır
Görsel düzenleme arena: kullanıcılar, model adlarını görmeden aynı görsel ve yönergeden yapılan iki düzenlemeden daha iyisini seçer.
Edit or restyle pictures with an instruction. Send one or more images and describe the change; Wan 2.7 keeps what you do not mention.
| Field | Type | Default | Notes |
|---|---|---|---|
prompt | string, required | — | Up to 10,000 characters. |
images | image URL[], required | — | Images to edit or combine, referred to as Image 1, Image 2, … |
aspect_ratio | 21:9 / 16:9 / 4:3 / 1:1 / 3:4 / 9:16 / 9:21 | — | Omit to follow the first input image. |
$0.03 per output image, Alibaba's list price. Input images are not metered.
| Request | Price |
|---|---|
| One image | $0.03 |
Failed runs are not charged.
Other Wan 2.7 image endpoints: alibaba/wan/2.7/text-to-image, alibaba/wan/2.7/pro/text-to-image, alibaba/wan/2.7/pro/image-to-image.
Geliştirmeye başlayın
Bu modeli SandBase Unified Run API üzerinden gönderin.
# The quoted heredoc keeps Unicode and shell metacharacters unchanged.
result=$(curl --fail-with-body --silent \
-X POST "https://api.sandbase.ai/v1/run" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
--data-binary @- <<'SANDBASE_JSON'
{
"model": "alibaba/wan/2.7/image-to-image",
"images": [
"https://static.sandbase.ai/samples/image-editing/edit-style-watercolor-source.png"
],
"prompt": "Convert this photograph into a delicate watercolor painting style with visible brush strokes and soft color bleeding"
}
SANDBASE_JSON
)
run_id=$(printf '%s' "$result" | jq -r .id)
for attempt in $(seq 1 120); do
status=$(printf '%s' "$result" | jq -r .status)
case "$status" in completed|failed|timeout) break ;; esac
sleep 2
result=$(curl --fail-with-body --silent \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
"https://api.sandbase.ai/v1/run/$run_id")
done
status=$(printf '%s' "$result" | jq -r .status)
[ "$status" = completed ] || { echo "Generation ended: $status" >&2; exit 1; }
printf '%s\n' "$result"Bir SandBase API anahtarı oluşturun ve sunucu ortamınıza ayarlayın. Tüm istekler Bearer kimlik doğrulaması kullanır.
export SANDBASE_API_KEY="YOUR_API_KEY"Anahtarı sunucuda tutun. Tarayıcı kodunda açığa çıkarmayın veya bir depoya commit etmeyin.
Bu model kimliği ve girdileriyle /v1/run adresine POST gönderin. Yukarıdaki istek örneği gönderme ve yoklamayı içerir.
Durum completed, failed veya timeout olana kadar verilen run ID ile yoklama yapın. Çıktıyı yalnızca completed olduktan sonra okuyun.
curl "https://api.sandbase.ai/v1/run/$RUN_ID" \
-H "Authorization: Bearer $SANDBASE_API_KEY"Modelin image, video veya audio alanına herkese açık erişilebilir bir dosya URL'si verin. Desteklenen formatlar ve sınırlar her Playground girişinin yanında gösterilir.
Playground'daki desteklenen image alanlarında yükleme veya değiştirme kontrolünü kullanın. Video URL alanları barındırılan bir sürüş videosu kabul eder; video yükleme desteği anlamına gelmez.
imagesarrayzorunluList of input image URLs for editing. Up to 4 images.
promptstringzorunluThe editing instruction describing what changes to make.
Varsayılan: "Convert this photograph into a delicate watercolor painting style with visible brush strokes and soft color bleeding"
aspect_ratiostringThe aspect ratio of the generated image.
Olası değerler: "21:9", "16:9", "4:3", "1:1", "3:4", "9:16", "9:21"
{
"model": "alibaba/wan/2.7/image-to-image",
"images": [
"https://static.sandbase.ai/samples/image-editing/edit-style-watercolor-source.png"
],
"prompt": "Convert this photograph into a delicate watercolor painting style with visible brush strokes and soft color bleeding"
}Tamamlanan bir run, sonucunu output içinde gösterir. Aşağıdaki, modelin kaydedilmiş örneğidir; yeni bir üretim değildir.
[
{
"source": "Self organization completed prediction",
"source_url": "https://www.sandbase.ai",
"url": "https://static.sandbase.ai/examples/0eeefa8f-0c4d-4a75-ad7e-6ead1df9e998/output/fa02f813-dc4c-4b72-be4d-deaccae048ae.png"
}
]