All Products
Search
Document Center

Alibaba Cloud Model Studio:Pengeditan Video 2.7

Last Updated:Oct 11, 2026

Model pengeditan video Wanxiang mendukung berbagai operasi pengeditan pada video input, seperti menambahkan, menghapus, atau memodifikasi konten; mengganti latar belakang; mengonversi gaya; serta mereplikasi aksi, efek, atau pergerakan kamera. Model ini menyediakan dua metode berikut:

  • Instruction-based editing: Memodifikasi konten video menggunakan instruksi teks, seperti mengganti pakaian karakter, mengubah elemen adegan, atau menyesuaikan gaya visual.
  • Instruction and reference image editing: Selain instruksi teks, Anda dapat memberikan gambar referensi untuk menerapkan elemen dari gambar tersebut—seperti karakter, pakaian, atau prop—ke dalam video.

CatatanUntuk pengeditan video, terutama saat mereplikasi aksi, pergerakan kamera, atau efek dari video tertentu, gunakan Video Editing 2.7. Untuk kemampuan kelanjutan video (video continuation), gunakan Wanxiang Image-to-Video 2.7.

Mulai

Prompt input dan gambar referensiVideo masukan (video efek)Video Output

Terapkan efek khusus dari video referensi ke wanita berambut panjang dalam gambar. Adegannya adalah pesta.

image.png

Sebelum melakukan pemanggilan, dapatkan Kunci API, lalu konfigurasikan Kunci API sebagai Variabel lingkungan. Untuk melakukan pemanggilan menggunakan kit pengembangan perangkat lunak (SDK), instal SDK DashScope.

Ganti {WorkspaceId} dengan Workspace ID Anda yang sebenarnya.

Python SDK

PentingPastikan versi SDK DashScope untuk Python tidak lebih lama dari1.25.16 sebelum menjalankan kode berikut.

Versi yang usang dapat memicu error seperti "url error, please check url!". Untuk informasi lebih lanjut, lihat Instal SDK untuk memperbarui.

# -*- coding: utf-8 -*-
from http import HTTPStatus
from dashscope import VideoSynthesis
import dashscope
import os

# URL berikut untuk wilayah Singapura. Ganti {WorkspaceId} dengan Workspace ID Anda yang sebenarnya. URL berbeda tiap wilayah.
dashscope.base_http_api_url = 'https://{WorkspaceId}.ap-southeast-1.maas.aliyuncs.com/api/v1'

# Jika variabel lingkungan tidak diatur, ganti baris berikut dengan Kunci API Studio Model Anda: api_key="sk-xxx"
# Kunci API berbeda tiap wilayah. Untuk informasi lebih lanjut, lihat https://www.alibabacloud.com/help/en/model-studio/get-api-key
api_key = os.getenv("DASHSCOPE_API_KEY")

media = [
    {
        "type": "video",
        "url": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260409/eclvbm/21_refined.mp4"
    },
    {
        "type": "reference_image",
        "url": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260409/jgekix/wan2.7-videoedit-demo.webp"
    }
]

def sample_sync_call():
    print('----sync call, please wait a moment----')
    rsp = VideoSynthesis.call(
        api_key=api_key,
        model="wan2.7-videoedit",
        media=media,
        resolution="720P",
        prompt_extend=True,
        watermark=True,
        prompt="Apply the special effects from the reference video to the long-haired woman in the image. The scene is a party.",
    )
    print(rsp)
    if rsp.status_code == HTTPStatus.OK:
        print(rsp.output.video_url)
    else:
        print('Failed, status_code: %s, code: %s, message: %s' %
              (rsp.status_code, rsp.code, rsp.message))

if __name__ == '__main__':
    sample_sync_call()

Java SDK

PentingPastikan versi SDK Java DashScope tidak lebih lama dari2.22.14 sebelum menjalankan kode berikut.

Versi yang usang dapat memicu error seperti "url error, please check url!". Untuk informasi lebih lanjut, lihat Instal SDK untuk memperbarui.

// Copyright (c) Alibaba, Inc. and its affiliates.

import com.alibaba.dashscope.aigc.videosynthesis.VideoSynthesis;
import com.alibaba.dashscope.aigc.videosynthesis.VideoSynthesisParam;
import com.alibaba.dashscope.aigc.videosynthesis.VideoSynthesisResult;
import com.alibaba.dashscope.exception.ApiException;
import com.alibaba.dashscope.exception.InputRequiredException;
import com.alibaba.dashscope.exception.NoApiKeyException;
import com.alibaba.dashscope.utils.Constants;
import com.alibaba.dashscope.utils.JsonUtils;

import java.util.ArrayList;
import java.util.List;

public class VideoEdit {

    static {
        // URL berikut untuk wilayah Singapura. Ganti {WorkspaceId} dengan Workspace ID Anda yang sebenarnya. URL berbeda tiap wilayah.
        Constants.baseHttpApiUrl = "https://{WorkspaceId}.ap-southeast-1.maas.aliyuncs.com/api/v1";
    }

    // Jika variabel lingkungan tidak diatur, ganti baris berikut dengan Kunci API Studio Model Anda: apiKey="sk-xxx"
    // Kunci API berbeda tiap wilayah. Untuk informasi lebih lanjut, lihat https://www.alibabacloud.com/help/en/model-studio/get-api-key
    static String apiKey = System.getenv("DASHSCOPE_API_KEY");

    public static void syncCall() {
        VideoSynthesis videoSynthesis = new VideoSynthesis();
        final String prompt = "Apply the special effects from the reference video to the long-haired woman in the image. The scene is a party.";
        List<VideoSynthesisParam.Media> media = new ArrayList<VideoSynthesisParam.Media>(){{
            add(VideoSynthesisParam.Media.builder()
                    .url("https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260409/eclvbm/21_refined.mp4")
                    .type("video")
                    .build());
            add(VideoSynthesisParam.Media.builder()
                    .url("https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260409/jgekix/wan2.7-videoedit-demo.webp")
                    .type("reference_image")
                    .build());
        }};
        VideoSynthesisParam param =
                VideoSynthesisParam.builder()
                        .apiKey(apiKey)
                        .model("wan2.7-videoedit")
                        .prompt(prompt)
                        .media(media)
                        .resolution("720P")
                        .promptExtend(true)
                        .watermark(true)
                        .build();
        VideoSynthesisResult result = null;
        try {
            System.out.println("---sync call, please wait a moment----");
            result = videoSynthesis.call(param);
        } catch (ApiException | NoApiKeyException e){
            throw new RuntimeException(e.getMessage());
        } catch (InputRequiredException e) {
            throw new RuntimeException(e);
        }
        System.out.println(JsonUtils.toJson(result));
    }

    public static void main(String[] args) {
        syncCall();
    }
}

curl

Langkah 1: Buat tugas untuk mendapatkan ID tugas
curl --location 'https://{WorkspaceId}.ap-southeast-1.maas.aliyuncs.com/api/v1/services/aigc/video-generation/video-synthesis' \
    -H 'X-DashScope-Async: enable' \
    -H "Authorization: Bearer $DASHSCOPE_API_KEY" \
    -H 'Content-Type: application/json' \
    -d '{
    "model": "wan2.7-videoedit",
    "input": {
        "prompt": "Apply the special effects from the reference video to the long-haired woman in the image. The scene is a party.",
        "media": [
            {
                "type": "video",
                "url": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260409/eclvbm/21_refined.mp4"
            },
            {
                "type": "reference_image",
                "url": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260409/jgekix/wan2.7-videoedit-demo.webp"
            }
        ]
    },
    "parameters": {
        "resolution": "720P",
        "prompt_extend": true,
        "watermark": true
    }
}'
Langkah 2: Ambil hasil berdasarkan ID tugas

Ganti {task_id} dengan nilai task_id yang dikembalikan oleh pemanggilan API sebelumnya. task_id berlaku untuk kueri selama 24 jam.

curl -X GET https://{WorkspaceId}.ap-southeast-1.maas.aliyuncs.com/api/v1/tasks/{task_id} \
--header "Authorization: Bearer $DASHSCOPE_API_KEY"
Contoh output

video_url berlaku selama 24 jam. Segera unduh video tersebut.

{
    "request_id": "c1209113-8437-424f-a386-xxxxxx",
    "output": {
        "task_id": "966cebcd-dedc-4962-af88-xxxxxx",
        "task_status": "SUCCEEDED",
        "video_url": "https://dashscope-result-sh.oss-accelerate.aliyuncs.com/xxx.mp4?Expires=xxx",
         ...
    },
    ...
}

Cakupan

  • Model yang didukung berbeda tiap wilayah. Sumber daya terisolasi antar wilayah. Untuk daftar model yang didukung di setiap wilayah, lihat Konsol Studio Model.
  • Saat melakukan pemanggilan, pastikan model, URL titik akhir, dan Kunci API Anda semuanya berasal dari wilayah yang sama. Pemanggilan lintas wilayah akan gagal.

CatatanKode contoh dalam topik ini berlaku untuk wilayah Singapura.

Kemampuan inti

Pengeditan hanya berbasis instruksi

Model yang didukung: wan2.7-videoedit.

Perkenalan fitur: Fitur ini memodifikasi konten video berdasarkan video input dan prompt teks. Cocok untuk skenario seperti konversi gaya, modifikasi aksi, dan penyesuaian pergerakan kamera.

Pengaturan parameter:

  • media: Menentukan video yang akan diedit (type=video). Anda tidak perlu memberikan gambar referensi.
  • prompt: Jelaskan maksud pengeditan, misalnya "Ubah video menjadi gaya piksel 8-bit".
Input promptInput videoVideo output

Ubah video menjadi gaya piksel 8-bit

Ganti {WorkspaceId} dengan Workspace ID Anda yang sebenarnya.

Python SDK

PentingPastikan versi SDK DashScope untuk Python tidak lebih lama dari1.25.16 sebelum menjalankan kode berikut.

Versi yang usang dapat memicu error seperti "url error, please check url!". Untuk informasi lebih lanjut, lihat Instal SDK untuk memperbarui.

# -*- coding: utf-8 -*-
from http import HTTPStatus
from dashscope import VideoSynthesis
import dashscope
import os

# URL berikut untuk wilayah Singapura. Ganti {WorkspaceId} dengan Workspace ID Anda yang sebenarnya. URL berbeda tiap wilayah.
dashscope.base_http_api_url = 'https://{WorkspaceId}.ap-southeast-1.maas.aliyuncs.com/api/v1'

# Jika variabel lingkungan tidak diatur, ganti baris berikut dengan Kunci API Studio Model Anda: api_key="sk-xxx"
# Kunci API berbeda tiap wilayah. Untuk informasi lebih lanjut, lihat https://www.alibabacloud.com/help/en/model-studio/get-api-key
api_key = os.getenv("DASHSCOPE_API_KEY")

media = [
    {
        "type": "video",
        "url": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260402/ldnfdf/wan2.7-videoedit-style-change.mp4"
    }
]

def sample_sync_call():
    print('----sync call, please wait a moment----')
    rsp = VideoSynthesis.call(
        api_key=api_key,
        model="wan2.7-videoedit",
        media=media,
        resolution="720P",
        prompt_extend=True,
        watermark=True,
        prompt="Convert the entire frame to a claymation style",
    )
    if rsp.status_code == HTTPStatus.OK:
        print(rsp.output.video_url)
    else:
        print('Failed, status_code: %s, code: %s, message: %s' %
              (rsp.status_code, rsp.code, rsp.message))

if __name__ == '__main__':
    sample_sync_call()

Java SDK

PentingPastikan versi SDK Java DashScope Anda tidak lebih lama dari2.22.14 sebelum menjalankan kode berikut.

Versi yang usang dapat memicu error seperti "url error, please check url!". Untuk informasi lebih lanjut, lihat Instal SDK untuk memperbarui.

// Copyright (c) Alibaba, Inc. and its affiliates.

import com.alibaba.dashscope.aigc.videosynthesis.VideoSynthesis;
import com.alibaba.dashscope.aigc.videosynthesis.VideoSynthesisParam;
import com.alibaba.dashscope.aigc.videosynthesis.VideoSynthesisResult;
import com.alibaba.dashscope.exception.ApiException;
import com.alibaba.dashscope.exception.InputRequiredException;
import com.alibaba.dashscope.exception.NoApiKeyException;
import com.alibaba.dashscope.utils.Constants;
import com.alibaba.dashscope.utils.JsonUtils;

import java.util.ArrayList;
import java.util.List;

public class VideoEdit {

    static {
        // URL berikut untuk wilayah Singapura. Ganti {WorkspaceId} dengan Workspace ID Anda yang sebenarnya. URL berbeda tiap wilayah.
        Constants.baseHttpApiUrl = "https://{WorkspaceId}.ap-southeast-1.maas.aliyuncs.com/api/v1";
    }

    // Jika variabel lingkungan tidak diatur, ganti baris berikut dengan Kunci API Studio Model Anda: apiKey="sk-xxx"
    // Kunci API berbeda tiap wilayah. Untuk informasi lebih lanjut, lihat https://www.alibabacloud.com/help/en/model-studio/get-api-key
    static String apiKey = System.getenv("DASHSCOPE_API_KEY");

    public static void syncCall() {
        VideoSynthesis videoSynthesis = new VideoSynthesis();
        final String prompt = "Convert the entire frame to a claymation style";
        List<VideoSynthesisParam.Media> media = new ArrayList<VideoSynthesisParam.Media>(){{
            add(VideoSynthesisParam.Media.builder()
                    .url("https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260402/ldnfdf/wan2.7-videoedit-style-change.mp4")
                    .type("video")
                    .build());
        }};
        VideoSynthesisParam param =
                VideoSynthesisParam.builder()
                        .apiKey(apiKey)
                        .model("wan2.7-videoedit")
                        .prompt(prompt)
                        .media(media)
                        .resolution("720P")
                        .promptExtend(true)
                        .watermark(true)
                        .build();
        VideoSynthesisResult result = null;
        try {
            System.out.println("---sync call, please wait a moment----");
            result = videoSynthesis.call(param);
        } catch (ApiException | NoApiKeyException e){
            throw new RuntimeException(e.getMessage());
        } catch (InputRequiredException e) {
            throw new RuntimeException(e);
        }
        System.out.println(JsonUtils.toJson(result));
    }

    public static void main(String[] args) {
        syncCall();
    }
}

curl

Langkah 1: Buat tugas untuk mendapatkan ID tugas
curl --location 'https://{WorkspaceId}.ap-southeast-1.maas.aliyuncs.com/api/v1/services/aigc/video-generation/video-synthesis' \
    -H 'X-DashScope-Async: enable' \
    -H "Authorization: Bearer $DASHSCOPE_API_KEY" \
    -H 'Content-Type: application/json' \
    -d '{
    "model": "wan2.7-videoedit",
    "input": {
        "prompt": "Change the video to an 8-bit pixel style",
        "media": [
            {
                "type": "video",
                "url": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/en-US/20260409/rkjvku/1.mp4"
            }
        ]
    },
    "parameters": {
        "resolution": "720P",
        "prompt_extend": true,
        "watermark": true
    }
}'
Langkah 2: Ambil hasil berdasarkan ID tugas

Ganti {task_id} dengan nilai task_id yang dikembalikan oleh pemanggilan API sebelumnya. task_id berlaku untuk kueri selama 24 jam.

curl -X GET https://{WorkspaceId}.ap-southeast-1.maas.aliyuncs.com/api/v1/tasks/{task_id} \
--header "Authorization: Bearer $DASHSCOPE_API_KEY"

Pengeditan berbasis instruksi dan gambar referensi

Model yang didukung: wan2.7-videoedit.

Perkenalan fitur: Fitur ini menerapkan elemen dari gambar referensi—seperti pakaian atau prop—ke dalam video berdasarkan prompt teks.

Pengaturan parameter:

  • media: Menentukan video yang akan diedit (type=video) dan gambar referensi (type=reference_image). Anda dapat memberikan hingga empat gambar referensi.
  • prompt: Jelaskan maksud pengeditan, misalnya "Buat karakter berkepala kuda dalam video mengenakan sweater bergaris dari gambar".
Prompt input dan gambar referensiVideo inputVideo keluaran

Buat karakter berkepala kuda dalam video mengenakan sweater bergaris dari gambar

2560154123_RF-jpeg

Ganti {WorkspaceId} dengan Workspace ID Anda yang sebenarnya.

Python SDK

PentingPastikan versi SDK DashScope untuk Python tidak lebih lama dari1.25.16 sebelum menjalankan kode berikut.

Versi yang usang dapat memicu error seperti "url error, please check url!". Untuk informasi lebih lanjut, lihat Instal SDK untuk memperbarui.

# -*- coding: utf-8 -*-
from http import HTTPStatus
from dashscope import VideoSynthesis
import dashscope
import os

# URL berikut untuk wilayah Singapura. Ganti {WorkspaceId} dengan Workspace ID Anda yang sebenarnya. URL berbeda tiap wilayah.
dashscope.base_http_api_url = 'https://{WorkspaceId}.ap-southeast-1.maas.aliyuncs.com/api/v1'

# Jika variabel lingkungan tidak diatur, ganti baris berikut dengan Kunci API Studio Model Anda: api_key="sk-xxx"
# Kunci API berbeda tiap wilayah. Untuk informasi lebih lanjut, lihat https://www.alibabacloud.com/help/en/model-studio/get-api-key
api_key = os.getenv("DASHSCOPE_API_KEY")

media = [
    {
        "type": "video",
        "url": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260403/nlspwm/T2VA_22.mp4"
    },
    {
        "type": "reference_image",
        "url": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260402/fwjpqf/wan2.7-videoedit-change-clothes.png"
    }
]

def sample_sync_call():
    print('----sync call, please wait a moment----')
    rsp = VideoSynthesis.call(
        api_key=api_key,
        model="wan2.7-videoedit",
        media=media,
        resolution="720P",
        prompt_extend=True,
        watermark=True,
        prompt="Replace the girl's clothes in the video with the clothes from the image",
    )
    if rsp.status_code == HTTPStatus.OK:
        print(rsp.output.video_url)
    else:
        print('Failed, status_code: %s, code: %s, message: %s' %
              (rsp.status_code, rsp.code, rsp.message))

if __name__ == '__main__':
    sample_sync_call()

Java SDK

PentingPastikan versi SDK Java DashScope tidak lebih lama dari2.22.14 sebelum menjalankan kode berikut.

Versi yang usang dapat memicu error seperti "url error, please check url!". Untuk informasi lebih lanjut, lihat Instal SDK untuk memperbarui.

// Copyright (c) Alibaba, Inc. and its affiliates.

import com.alibaba.dashscope.aigc.videosynthesis.VideoSynthesis;
import com.alibaba.dashscope.aigc.videosynthesis.VideoSynthesisParam;
import com.alibaba.dashscope.aigc.videosynthesis.VideoSynthesisResult;
import com.alibaba.dashscope.exception.ApiException;
import com.alibaba.dashscope.exception.InputRequiredException;
import com.alibaba.dashscope.exception.NoApiKeyException;
import com.alibaba.dashscope.utils.Constants;
import com.alibaba.dashscope.utils.JsonUtils;

import java.util.ArrayList;
import java.util.List;

public class VideoEdit {

    static {
        // URL berikut untuk wilayah Singapura. Ganti {WorkspaceId} dengan Workspace ID Anda yang sebenarnya. URL berbeda tiap wilayah.
        Constants.baseHttpApiUrl = "https://{WorkspaceId}.ap-southeast-1.maas.aliyuncs.com/api/v1";
    }

    // Jika variabel lingkungan tidak diatur, ganti baris berikut dengan Kunci API Studio Model Anda: apiKey="sk-xxx"
    // Kunci API berbeda tiap wilayah. Untuk informasi lebih lanjut, lihat https://www.alibabacloud.com/help/en/model-studio/get-api-key
    static String apiKey = System.getenv("DASHSCOPE_API_KEY");

    public static void syncCall() {
        VideoSynthesis videoSynthesis = new VideoSynthesis();
        final String prompt = "Replace the girl's clothes in the video with the clothes from the image";
        List<VideoSynthesisParam.Media> media = new ArrayList<VideoSynthesisParam.Media>(){{
            add(VideoSynthesisParam.Media.builder()
                    .url("https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260403/nlspwm/T2VA_22.mp4")
                    .type("video")
                    .build());
            add(VideoSynthesisParam.Media.builder()
                    .url("https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260402/fwjpqf/wan2.7-videoedit-change-clothes.png")
                    .type("reference_image")
                    .build());
        }};
        VideoSynthesisParam param =
                VideoSynthesisParam.builder()
                        .apiKey(apiKey)
                        .model("wan2.7-videoedit")
                        .prompt(prompt)
                        .media(media)
                        .resolution("720P")
                        .promptExtend(true)
                        .watermark(true)
                        .build();
        VideoSynthesisResult result = null;
        try {
            System.out.println("---sync call, please wait a moment----");
            result = videoSynthesis.call(param);
        } catch (ApiException | NoApiKeyException e){
            throw new RuntimeException(e.getMessage());
        } catch (InputRequiredException e) {
            throw new RuntimeException(e);
        }
        System.out.println(JsonUtils.toJson(result));
    }

    public static void main(String[] args) {
        syncCall();
    }
}

curl

Langkah 1: Buat tugas untuk mendapatkan ID tugas
curl --location 'https://{WorkspaceId}.ap-southeast-1.maas.aliyuncs.com/api/v1/services/aigc/video-generation/video-synthesis' \
    -H 'X-DashScope-Async: enable' \
    -H "Authorization: Bearer $DASHSCOPE_API_KEY" \
    -H 'Content-Type: application/json' \
    -d '{
    "model": "wan2.7-videoedit",
    "input": {
        "prompt": "Make the horse-headed character in the video wear the striped sweater from the image",
        "media": [
            {
                "type": "video",
                "url": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260409/dozxak/Wan_Video_Edit_33_1.mp4"
            },
            {
                "type": "reference_image",
                "url": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260415/hynnff/wan-video-edit-clothes.webp"
            }
        ]
    },
    "parameters": {
        "resolution": "720P",
        "prompt_extend": true,
        "watermark": true
    }
}'
Langkah 2: Ambil hasil berdasarkan ID tugas

Ganti {task_id} dengan nilai task_id yang dikembalikan oleh pemanggilan API sebelumnya. task_id berlaku untuk kueri selama 24 jam.

curl -X GET https://{WorkspaceId}.ap-southeast-1.maas.aliyuncs.com/api/v1/tasks/{task_id} \
--header "Authorization: Bearer $DASHSCOPE_API_KEY"

Skenario dan contoh

Menambahkan, menghapus, atau memodifikasi elemen

Menambahkan, menghapus, atau mengganti elemen tertentu dalam video.

JenisPrompt input dan gambar referensiVideo masukanVideo output

Add

Tambahkan sepotong cokelat persegi hitam ke dalam cangkir

Delete

Hapus kereta dari video. Pertahankan semua elemen lainnya.

Modify

Ganti film pada video dengan plate dari gambar.

image.png

Modify

Buat manusia kuda dalam video mengenakan sweater bergaris dari gambar2560154123_RF-jpeg

Modify

Ubah kucing menjadi anjing

Memodifikasi lingkungan atau latar belakang

Gunakan instruksi untuk mengubah kondisi pencahayaan, warna musim, atau ruang geografis dalam video. Anda juga dapat mengganti latar belakang video untuk memindahkan objek ke ruang apa pun.

JenisPrompt inputVideo inputVideo output

Modify season

Ubah musim latar belakang menjadi musim dingin bersalju, dengan salju menutupi pepohonan. Pertahankan sungai tetap sama.

Modify weather

Pertahankan aksi karakter tetap sama, tetapi ubah seluruh adegan dari hari berawan saat ini menjadi hari cerah. Pertahankan semua elemen lainnya.

Modify lighting and shadow

Pertahankan semua elemen lainnya. Ubah warna cahaya dan filter keseluruhan bingkai dari putih menjadi nada hangat. Pertahankan detail warna kulit karakter agar menciptakan tampilan harmonis antara karakter dan latar belakang.

Modify background

Pertahankan aksi wanita utama tetap sama, tetapi ubah latar belakang video menjadi gym.

Memodifikasi gaya video

Konversi cepat video yang ada ke berbagai gaya artistik, seperti animasi, 3D, claymation, atau benang rajut.

JenisMasukkan promptVideo masukanVideo output

Modify style

Video-to-Image: Gaya Kartun C4D2402534429_RF

Modify style

Konversi seluruh bingkai menjadi gaya film live-action

Modify style

Konversi seluruh bingkai menjadi gaya lukisan cat air

Memodifikasi perilaku karakter, dialog, atau teknik kamera

Untuk konten video yang sudah ada atau dihasilkan, Anda dapat menggunakan instruksi untuk memodifikasi alur cerita—seperti perilaku atau dialog karakter—dan menyesuaikan teknik kamera untuk pengeditan kreatif lebih lanjut.

JenisMasukkan promptVideo inputVideo output

Modify character behavior

Buat pria dalam video mengambil sesendok sup dan meminumnya. Pertahankan semua elemen lainnya.

Modify character emotion

Ekspresi gadis dalam bingkai menjadi sedih dan mulai menangis. Pertahankan semua elemen lainnya.

Modify character lines

Pertahankan suara dan nada karakter. Ubah kalimat anak perempuan di sebelah kiri menjadi: "Ibu, ini warna apa?", dan kalimat anak perempuan di sebelah kanan menjadi: "Ini warna hijau, sayang."

Modify camera work

Ubah pergerakan kamera menjadi orbit searah jarum jam mengelilingi karakter, dengan karakter mengikuti pergerakan kamera.

Modify camera work

Ubah pergerakan kamera video menjadi tilt-up sambil secara bersamaan melihat ke bawah.

Mereplikasi aksi, pergerakan kamera, atau efek

Mereplikasi urutan aksi, lintasan kamera, dan efek visual dari video referensi untuk menghasilkan video dengan fitur dinamis yang konsisten.

JenisPrompt input atau gambar referensiVideo inputVideo output

Replicate single-person action

Buat orang dalam gambar meniru aksi orang dalam video.

image.png

Replicate multi-person action

Referensikan aksi lima orang dalam video, dan ubah adegan menjadi lima orang bernyanyi dan memainkan instrumen di warung pinggir jalan di kota.

Replicate camera movement

Referensikan pergerakan kamera video asli dengan gerakan kamera cepat. Ubah adegan menjadi upacara penghargaan, dengan wanita dari gambar referensi berjalan di karpet merah.

image.png

Replicate effects

Referensikan efek khusus video dan terapkan ke wanita dalam gambar, dengan adegan diatur di jalan.

image.png

Cara memasukkan video dan gambar

Video input

  • Jumlah video: Wajib. Tepat satu.

  • Metode input:

Gambar referensi input

  • Jumlah gambar: Opsional. Maksimal empat.

  • Metode input:

    • URL publik: Mendukung protokol HTTP atau HTTPS. Contoh: https://xxxx/xxx.png.

    • String terenkripsi Base64: Contoh: data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAABDg...... (Contoh dipotong untuk keperluan demonstrasi).

      • Format: data:{MIME_type};base64,{base64_data}, dengan:

        • {base64_data}: String terenkripsi Base64 dari file gambar.
        • {MIME_type}: Jenis media gambar, yang harus sesuai dengan format file.

        Format gambar

        MIME Type

        JPEG

        image/jpeg

        JPG

        image/jpeg

        PNG

        image/png

        BMP

        image/bmp

        WEBP

        image/webp

        Kode contoh

        import base64
        import mimetypes
        
        # Format adalah data:{MIME_type};base64,{base64_data}
        def encode_file(file_path):
            mime_type, _ = mimetypes.guess_type(file_path)
            if not mime_type or not mime_type.startswith("image/"):
                raise ValueError("Unsupported or unrecognized image format")
            with open(file_path, "rb") as image_file:
                encoded_string = base64.b64encode(image_file.read()).decode('utf-8')
            return f"data:{mime_type};base64,{encoded_string}"
        
        # Ganti your_image.jpg dengan path gambar sebenarnya
        base64_str = encode_file("your_image.jpg")
        print(base64_str)
        

Video output

  • Jumlah video: 1.
  • Spesifikasi video: Formatnya MP4. Untuk informasi lebih lanjut, lihat Cakupan spesifikasi video.
  • Masa berlaku URL video: 24 jam.
  • Dimensi video: Parameter resolution menentukan resolusi video, dan parameter ratio menentukan rasio aspek video.

Penagihan dan pembatasan laju

  • Untuk kuota gratis model dan harga penagihan, lihat Harga model.

  • Untuk batas laju model, lihat Seri Wanxiang.

  • Deskripsi penagihan:

    • Gambar input tidak dikenai biaya. Video input dan video output ditagih per detik. Rumusnya: Total durasi tagihan (detik) = Durasi video input (detik) + Durasi video output (detik).
    • Pemanggilan model yang gagal atau error pemrosesan tidak dikenai biaya apa pun dan tidak mengurangi kuota gratis untuk pengguna baru.

Dokumentasi API

Wanxiang Video Editing 2.7

FAQ

T: Apa perbedaan antara Video Editing 2.7 (wan2.7-videoedit) dan Video Editing 2.1 (wan2.1-vace-plus)?

J: Video Editing 2.7 mengedit video langsung berdasarkan instruksi, sehingga lebih mudah digunakan dan menawarkan peningkatan komprehensif. Video Editing 2.1 mengharuskan Anda menentukan parameter function dan berfokus pada fitur seperti pengeditan lokal dengan mask dan ekspansi bingkai. Kami menyarankan Anda menggunakan Video Editing 2.7.

T: Bagaimana cara memasukkan beberapa gambar referensi?

J: Anda dapat menambahkan beberapa objek dengan type=reference_image ke dalam array media. Anda dapat menambahkan hingga empat gambar referensi. Contoh:

{
    "media": [
        {"type": "video", "url": "<Input video URL>"},
        {"type": "reference_image", "url": "<Reference image 1 URL>"},
        {"type": "reference_image", "url": "<Reference image 2 URL>"},
        {"type": "reference_image", "url": "<Reference image 3 URL>"},
        {"type": "reference_image", "url": "<Reference image 4 URL>"}
    ]
}