0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

How to Make AI Video Prompts With a Timeline Validator

0
Posted at

AI video prompts become reproducible when they are compiled from a validated timeline instead of written as one cinematic paragraph. Define ordered time windows, one camera responsibility, visible causes for sound, and invariants that must survive every beat.

仕様: prompt manifest

type Beat = {
  start: number;
  end: number;
  action: string;
  sound?: string;
};

type VideoBrief = {
  duration: 20;
  aspectRatio: "16:9";
  subject: string;
  environment: string;
  camera: string;
  invariants: string[];
  beats: Beat[];
  forbid: string[];
};

このチュートリアルでは、FLUX 3 Video の発表済みワークフローを参考に 20 秒の brief を作ります。ただし現在の Voor ページは FLUX 3 Video を一般提供モデルとして表示していません。生成フォームでは明示された利用可能モデルで brief をテストします。

Validator

export function validateBrief(x: VideoBrief): string[] {
  const errors: string[] = [];
  if (x.duration !== 20) errors.push("duration must be 20");
  if (x.beats.length < 3 || x.beats.length > 5) {
    errors.push("use 3-5 beats");
  }
  if (x.beats[0]?.start !== 0) errors.push("first beat starts at 0");

  for (let i = 0; i < x.beats.length; i++) {
    const b = x.beats[i];
    if (b.end <= b.start) errors.push(`beat ${i} has invalid range`);
    if (i > 0 && b.start !== x.beats[i - 1].end) {
      errors.push(`gap or overlap before beat ${i}`);
    }
  }

  if (x.beats.at(-1)?.end !== x.duration) {
    errors.push("timeline must fill the full duration");
  }
  if (x.camera.split(/,| and /i).length > 2) {
    errors.push("camera plan is probably overloaded");
  }
  for (const b of x.beats) {
    if (b.sound && !b.action) errors.push("sound needs a visible cause");
  }
  return errors;
}

再現可能な入力例

const brief: VideoBrief = {
  duration: 20,
  aspectRatio: "16:9",
  subject: "matte ceramic pour-over brewer, no logo",
  environment: "warm stone counter at dawn",
  camera: "one slow 20-degree orbit",
  invariants: ["shape", "glaze color", "handle", "light direction"],
  beats: [
    { start: 0, end: 3, action: "locked establishing frame", sound: "quiet room tone" },
    { start: 3, end: 8, action: "hand begins pouring water", sound: "water stream" },
    { start: 8, end: 14, action: "orbit reveals ceramic surface", sound: "water and soft ceramic contact" },
    { start: 14, end: 18, action: "hand exits and steam settles" },
    { start: 18, end: 20, action: "stable final hero frame" }
  ],
  forbid: ["music", "text", "logo", "scene cut", "shape change"]
};

Compile to prompt

export function compile(x: VideoBrief): string {
  const timeline = x.beats
    .map(b => `${b.start}-${b.end}s: ${b.action}${b.sound ? `; sound: ${b.sound}` : ""}`)
    .join(". ");
  return [
    `Create a ${x.aspectRatio}, ${x.duration}-second sequence.`,
    `Subject: ${x.subject}. Environment: ${x.environment}.`,
    `Camera: ${x.camera}.`,
    timeline + ".",
    `Preserve: ${x.invariants.join(", ")}.`,
    `Do not include: ${x.forbid.join(", ")}.`
  ].join(" ");
}

Voor でのテスト手順

  1. 利用可能モデル付きの timed-brief generator を開く。
  2. 20-second sequence の preset を選ぶ。
  3. validator が空配列を返した manifest だけを compile する。
  4. prompt を貼り、選択中モデル、duration、aspect ratio、Public/Private、credit estimate を確認する。
  5. Generate 後は prompt の各 beat と実際の映像をフレーム単位で照合する。

判定基準

  • beat の順番が変わっていない
  • camera direction が一貫している
  • subject geometry と light direction が維持される
  • sound は画面内の cause と対応する
  • 18–20 秒が stable hold になっている

Technical limitations

Validator は構文と時間整合性だけを保証し、生成結果の品質は保証しません。FLUX 3 Video はこのページで coming soon と明記されています。利用可能モデルや価格は変更され得るため、固定 credit 値を書かず UI の見積りを確認します。Public が現在の既定値です。この検証では paid generation を実行していません。

manifest と review harness が揃ったら、同じ generator で live estimate を確認してから brief をテストしてください。
qiita-cover.png
qiita-workspace.png

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?