Створіть завдання Runway для перетворення тексту на відео
Створюйте відео на основі текстового Prompt за допомогою Runway Gen-4.5 через CometAPI.
gen4.5, щоб створити відео на основі текстового Prompt. Надсилайте свій ключ CometAPI API
за допомогою автентифікації Bearer і тіла JSON-запиту.
Підготуйте запит
- Установіть
modelу значенняgen4.5. - Опишіть сцену й рух у
promptText, використовуючи від 1 до 1 000 кодових одиниць UTF-16. - Установіть
ratioу значення1280:720для альбомної орієнтації або720:1280для портретної. - Установіть
durationяк ціле число від2до10секунд.
promptImage або перемикач audio до цього запиту для перетворення тексту на відео.
Налаштуйте додаткові параметри керування
Щоб явно вказати seed вибірки, використовуйте1–4294967295. Якщо його не вказано або задано 0
вибирається випадковий seed. Якщо ви додаєте contentModeration, установіть його
publicFigureThreshold у значення auto або low; інакше не додавайте об’єкт.
Використовуйте outputFormat, щоб вибрати MP4, ProRes, послідовності PNG або один із форматів HDR
перелічених у схемі запиту. Не вказуйте його для H.264 MP4. Ви можете встановити
proresProfile лише коли outputFormat має значення prores або hdr_prores.
Формат HDR ProRes підтримує 422, 422 HQ або 4444.
Отримайте результат
Збережіть поверненийid і скористайтеся Отримайте завдання Runway.
Коли status має значення SUCCEEDED, прочитайте URL-адреси відео в output.Авторизації
Use your CometAPI API key.
Тіло
Request parameters for gen4.5.
Model ID for this request variant.
gen4.5 "gen4.5"Describe the requested scene or motion in 1 to 1,000 UTF-16 code units.
1 - 1000Requested output dimensions, expressed as width:height. Choose a value listed for this model and endpoint.
1280:720, 720:1280 Requested video duration in whole seconds, from 2 through 10.
2 <= x <= 10Optional sampling seed. Use a positive integer for an explicit seed. Omission or 0 selects a random seed.
0 <= x <= 4294967295Optional content moderation settings. Omit the object to use standard moderation.
Output encoding. Omit for mp4 (H.264). prores returns MOV; png_sequence returns a PNG ZIP; sdr_rec709_10bit returns 10-bit Rec.709 HEVC. hdr10 and hlg return 10-bit HDR MP4; hdr_pq_12bit_master returns 12-bit HEVC MOV; hdr_prores returns HDR ProRes MOV. The HDR PNG/EXR sequence formats return ZIP archives; the ACEScg variants target the named ACES version.
mp4, prores, png_sequence, hdr10, hlg, sdr_rec709_10bit, hdr_pq_12bit_master, hdr_prores, hdr_png_sequence, hdr_exr_sequence, hdr_exr_acescg_sequence_1_3, hdr_exr_acescg_sequence_2_0 Profile for outputFormat prores or hdr_prores. Omit for 4444 with prores, or 422 HQ with hdr_prores. hdr_prores accepts only 422, 422 HQ, or 4444. Omit this field for other formats.
422, 4444, 422 Proxy, 422 LT, 422 HQ, 4444 XQ Відповідь
Task submitted. Save its id to retrieve task status.
Task ID for GET /runwayml/v1/tasks/{id}.
Task state, when returned.
Task submission timestamp, when returned.
Result URLs, when returned.
Failure explanation, when returned.
Machine-readable failure code, when returned.
Task estimate metadata, when returned.
Task cost metadata, when returned.