コンテンツにスキップ
オープンキャスタリーコンソール

動画

happyhorse-1.1-r2v API

Modelflare 非同期ビデオ ルーティングを通じて正確な happyhorse-1.1-r2v モデル ID を使用します。

正確なモデル ID happyhorse-1.1-r2v を使用します。モデル フィールドはこのページと正確に一致する必要があります。

サンプル出力happyhorse-1.1-r2vPOST /v1/videos5.2s

パラメータ: duration=5resolution=1080pratio=16:9入力画像

プロンプト: One continuous take, no cuts. Keep the woman in the crimson satin coat and the peeling carpet ribbons from the reference and move the event outdoors: she walks out of a revolving door onto a wet plaza and the patterned ribbons keep tearing up behind her, now lifting off the paving stones and streaming out across the square in a long coloured wake. The camera tracks backward ahead of her at waist height and cranes up as the wake spreads. One hard green sign light above the door, warm street lamps across the plaza. Real weight and inertia, satin and wet stone, no text.

入力メディア URL が置き換えられた、このサンプルを生成したリクエスト
{
"model": "happyhorse-1.1-r2v",
"prompt": "One continuous take, no cuts. Keep the woman in the crimson satin coat and the peeling carpet ribbons from the reference and move the event outdoors: she walks out of a revolving door onto a wet plaza and the patterned ribbons keep tearing up behind her, now lifting off the paving stones and streaming out across the square in a long coloured wake. The camera tracks backward ahead of her at waist height and cranes up as the wake spreads. One hard green sign light above the door, warm street lamps across the plaza. Real weight and inertia, satin and wet stone, no text.",
"seconds": "5",
"duration": 5,
"resolution": "1080p",
"ratio": "16:9",
"aspect_ratio": "16:9",
"image": "https://example.com/input-image.png"
}

https://modelflare.dev/v1 で Modelflare API キーを使用します。ゲートウェイのエントリ ポイントは POST /v1/videos です。

HTTP
Authorization: Bearer YOUR_MODELFLARE_API_KEY
ターミナルウィンドウbash
curl https://modelflare.dev/v1/videos \
-H "Authorization: Bearer YOUR_MODELFLARE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "happyhorse-1.1-r2v",
"input": {"prompt": "The person in [Image 1] picks up [Image 2].", "media": [{"type": "reference_image", "url": "https://example.com/person.jpg"}, {"type": "reference_image", "url": "https://example.com/object.jpg"}]},
"parameters": {"resolution": "1080P", "ratio": "16:9", "duration": 5, "watermark": false}
}'

タスクIDを保存します。 GET /v1/videos/{task_id} をポーリングし、GET /v1/videos/{task_id}/content でダウンロードします。結果 URL は有効期限が切れている可能性があるため、速やかにファイルを転送してください。

ターミナルウィンドウbash
curl https://modelflare.dev/v1/videos/TASK_ID \
-H "Authorization: Bearer YOUR_MODELFLARE_API_KEY"

HappyHorse は input.prompt を使用します。 t2v、i2v、または r2v モデル ID に一致する input.media シェイプを選択します。

HappyHorse R2V は、input.media に 1 ~ 9 個の reference_image 項目を配置し、プロンプトから順に参照します。

フィールド 必須 注意事項
model はい happyhorse-1.1-r2v
input.prompt はい テキスト説明または参照指示、最大 5,000 文字(非中国語文字または 2,500 文字)
input.media[] はい 1 ~ 9 reference_image の項目。パブリック URL または Base64、20 MB 未満、最小 400 ピクセルの短辺
parameters.resolution いいえ 720P / 1080P、デフォルトは1080P
parameters.ratio いいえ 16:9 / 9:16 / 1:1 / 4:3 / 3:4 / 4:5 / 5:4 / 9:21 / 21:9、デフォルトは16:9
parameters.duration いいえ 3 ~ 15 秒、デフォルトは 5
parameters.watermark いいえ HappyHorseウォーターマークを追加するかどうか
parameters.seed いいえ 0 ~ 2,147,483,647 のオプションのシード

R2V は 1 ~ 9 の reference_image アイテムを使用し、それらをイメージ 1、イメージ 2 などとプロンプト順に参照します。プロンプトは、中国語以外の文字は 5,000 文字、または中国語は 2,500 文字に制限されます。画像は最小 400 ピクセルの短辺で 20 MB 未満です。

無効なモデル パラメーターは、リクエスト ID を含む 4xx を返します。非同期タスクは、作成が成功した後に失敗することもあります。ポーリング応答からの error_code と error_message を最終タスク理由として使用します。異なる JSON 形式で同じリクエストを再試行しないでください。

このページでは、Modelflare モデルの生成と編集呼び出しについて説明します。検索またはマップのエンリッチメント、音声管理、および要素ライブラリ管理は、このパブリック モデル呼び出しサーフェスの外部にあるリソース API であり、必須のリクエスト フィールドではありません。

動画秒単位課金モデルです。現在の顧客価格、参考定価、完全な仕様については、モデル価格ページを参照してください。

メディア契約 · v1

契約ID: media.happyhorse-1-1-r2v.v1アダプター: video.happyhorse.v1@v1指紋: 080ba09723851efe1ae578055ceca7299f987e1fe2602d9e554e47a8431ec35a

公式ソース: Alibaba Cloud Model Studio

契約パラメータ

インテントフィールドコントロールオプション
ratioselect16:9 / 9:16 / 1:1 / 4:3 / 3:4 / 4:5 / 5:4 / 21:9 / 9:21
resolutionselect720p / 1080p
durationselect3 / 4 / 5 / 6 / 7 / 8 / 9 / 10 / 11 / 12 / 13 / 14 / 15

サポートされる機能

  • allowed_values · ratio · 16:9, 9:16, 1:1, 4:3, 3:4, 4:5, 5:4, 21:9, 9:21
  • allowed_values · resolution · 720p, 1080p
  • allowed_values · duration · 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15
  • required_assets · reference_asset_ids
  • max_assets · reference_asset_ids · 9

構造化リクエストの例

reference

インテント

{
  "duration": 3,
  "prompt": "A red paper kite over a quiet harbour at dusk.",
  "ratio": "16:9",
  "reference_asset_ids": [
    "asset_example"
  ],
  "resolution": "720p"
}

プロバイダーリクエスト

{
  "duration": 3,
  "image": "https://example.com/reference.png",
  "model": "happyhorse-1.1-r2v",
  "prompt": "A red paper kite over a quiet harbour at dusk.",
  "ratio": "16:9",
  "resolution": "720p",
  "seconds": "3"
}