Skip to content

norahe0304-art/30x-video / cli/skill

30x-web-to-video

Flagged

Use when a user gives a brand URL and wants a premium launch, demo, or marketing video. Zero-manual workflow — Claude runs the V2 orchestrator itself (scrapes brand evidence, auto-installs missing tools, generates the first-cut Remotion project). User only sees the URL and the Studio preview.

FileKindSize
.gitignoreother103 B
AGENTS.mdmarkdown2.5 KB
FUSION-REPORT.mdmarkdown12.3 KB
README.mdmarkdown3.6 KB
SKILL.mdskill md30.7 KB
benchmarks/AGENTS.mdmarkdown773 B
benchmarks/README.mdmarkdown2.8 KB
benchmarks/manifest.jsonconfig5.9 KB
examples/INDEX.mdmarkdown1.8 KB
examples/caylent/MainVideo.tsxother6.0 KB
examples/caylent/scenes-v2/Act1V2.tsxother1.9 KB
examples/caylent/scenes-v2/Act2V2.tsxother2.5 KB
examples/caylent/scenes-v2/Act3V2.tsxother11.3 KB
examples/caylent/scenes-v2/Act4V2.tsxother8.6 KB
examples/caylent/scenes-v2/Act5V2.tsxother1.0 KB
examples/caylent/scenes/Act1.tsxother6.0 KB
examples/caylent/scenes/Act2.tsxother2.5 KB
examples/caylent/scenes/Act3.tsxother7.4 KB
examples/caylent/scenes/Act4.tsxother7.1 KB
examples/caylent/scenes/Act5.tsxother2.2 KB
examples/caylent/theme.tsscript1.2 KB
examples/cofounder/MainVideo.tsxother5.5 KB
examples/cofounder/scenes/AGENTS.mdmarkdown1.4 KB
examples/cofounder/scenes/Act1.tsxother2.3 KB
examples/cofounder/scenes/Act2.tsxother2.4 KB
examples/cofounder/scenes/Act3a.tsxother6.7 KB
examples/cofounder/scenes/Act3b.tsxother8.5 KB
examples/cofounder/scenes/Act3c.tsxother6.8 KB
examples/cofounder/scenes/Act4.tsxother4.4 KB
examples/cofounder/scenes/Act5.tsxother3.3 KB
examples/cofounder/scenes/World.tsxother4.0 KB
examples/cofounder/theme.tsscript1.5 KB
examples/happy-model/MainVideo.tsxother6.8 KB
examples/happy-model/scenes/AGENTS.mdmarkdown1.7 KB
examples/happy-model/scenes/Act1.tsxother7.9 KB
examples/happy-model/scenes/Act2.tsxother10.2 KB
examples/happy-model/scenes/Act3.tsxother15.6 KB
examples/happy-model/scenes/Act4.tsxother16.9 KB
examples/happy-model/scenes/Act5.tsxother9.0 KB
examples/happy-model/scenes/copy.tsscript588 B
examples/happy-model/theme.tsscript1.2 KB
examples/mana/MainVideo.tsxother4.9 KB
examples/mana/scenes/AGENTS.mdmarkdown926 B
examples/mana/scenes/Act1Open.tsxother2.8 KB
examples/mana/scenes/Act2Hero.tsxother3.3 KB
examples/mana/scenes/Act3Flavors.tsxother9.0 KB
examples/mana/scenes/Act4Label.tsxother7.3 KB
examples/mana/scenes/Act5Close.tsxother4.7 KB
examples/mana/scenes/World.tsxother7.2 KB
examples/mana/theme.tsscript2.6 KB
examples/parker/MainVideo.tsxother6.2 KB
examples/parker/scenes/AGENTS.mdmarkdown1.1 KB
examples/parker/scenes/Act1Hook.tsxother3.2 KB
examples/parker/scenes/Act2Meet.tsxother2.3 KB
examples/parker/scenes/Act2Problem.tsxother3.6 KB
examples/parker/scenes/Act3Steps.tsxother4.7 KB
examples/parker/scenes/Act4Proof.tsxother3.2 KB
examples/parker/scenes/Act5Close.tsxother2.6 KB
examples/parker/scenes/PaperWorld.tsxother6.8 KB
examples/parker/theme.tsscript1.6 KB
examples/perplexity-pc/MainVideo.tsxother4.5 KB
examples/perplexity-pc/scenes/Act1.tsxother2.1 KB
examples/perplexity-pc/scenes/Act2.tsxother2.7 KB
examples/perplexity-pc/scenes/Act3.tsxother3.1 KB
examples/perplexity-pc/scenes/Act4.tsxother1.6 KB
examples/perplexity-pc/scenes/Act5.tsxother2.0 KB
examples/perplexity-pc/theme.tsscript2.5 KB
references/AGENTS.mdmarkdown767 B
references/animations.mdmarkdown15.1 KB
references/audio.mdmarkdown8.6 KB
references/components.mdmarkdown9.5 KB
references/lottie.mdmarkdown5.1 KB
references/visual-effects.mdmarkdown5.0 KB
rules/AGENTS.mdmarkdown3.0 KB
rules/archetypes.mdmarkdown6.0 KB
rules/artifact-catalog.mdmarkdown10.8 KB
rules/beat-sync.mdmarkdown5.7 KB
rules/cards.mdmarkdown2.5 KB
rules/cinematic.mdmarkdown6.7 KB
rules/color.mdmarkdown2.2 KB
rules/composition.mdmarkdown13.2 KB
rules/creative-moves.mdmarkdown3.8 KB
rules/data-viz.mdmarkdown1.9 KB
rules/finish-gate.mdmarkdown5.2 KB
rules/layout.mdmarkdown6.6 KB
rules/media-resolve.mdmarkdown7.1 KB
rules/motion.mdmarkdown9.5 KB
rules/narration-sync.mdmarkdown5.5 KB
rules/narrative-templates.mdmarkdown10.4 KB
rules/narrative.mdmarkdown7.3 KB
rules/qc-gates.mdmarkdown11.3 KB
rules/taste.mdmarkdown12.6 KB
rules/transitions.mdmarkdown2.7 KB
rules/typography.mdmarkdown4.1 KB
rules/ui-mockups.mdmarkdown5.6 KB
rules/workflow.mdmarkdown53.2 KB
scaffold/.prettierrcother66 B
scaffold/AGENTS.mdmarkdown1.1 KB
scaffold/eslint.config.mjsscript79 B
scaffold/package-lock.jsonmanifest186.3 KB
scaffold/package.jsonmanifest1.5 KB
scaffold/remotion.config.tsscript219 B
scaffold/src/AGENTS.mdmarkdown831 B
scaffold/src/MainVideo.tsxother41.7 KB
scaffold/src/Root.tsxother2.3 KB
scaffold/src/components/AGENTS.mdmarkdown1.5 KB
scaffold/src/components/Animations.tsxother6.8 KB
scaffold/src/components/Atmosphere.tsxother8.1 KB
scaffold/src/components/Background.tsxother4.5 KB
scaffold/src/components/Captions.tsxother6.4 KB
scaffold/src/components/LogoEntrance.tsxother15.2 KB
scaffold/src/components/MockupTemplates.tsxother19.0 KB
scaffold/src/components/PhoneFrame.tsxother3.6 KB
scaffold/src/components/ShaderFX.tsxother5.3 KB
scaffold/src/components/Transitions.tsxother8.4 KB
scaffold/src/components/UI.tsxother3.0 KB
scaffold/src/components/VisualEffects.tsxother10.7 KB
scaffold/src/generated/AGENTS.mdmarkdown508 B
scaffold/src/generated/beat-map.tsscript1.1 KB
scaffold/src/generated/project-data.tsscript5.2 KB
scaffold/src/index.cssother576 B
scaffold/src/index.tsscript400 B
scaffold/src/lib/AGENTS.mdmarkdown411 B
scaffold/src/lib/fonts.tsscript867 B
scaffold/src/lib/modes.tsscript2.2 KB
scaffold/src/lib/utils.tsscript352 B
scaffold/src/theme.tsscript2.5 KB
scaffold/tsconfig.jsonconfig333 B
scripts/AGENTS.mdmarkdown2.4 KB
scripts/analyze-audiomap.pyscript13.3 KB
scripts/beat-sync.tsscript12.1 KB
scripts/benchmark-suite.tsscript17.8 KB
scripts/critique-scenes.tsscript10.1 KB
scripts/evidence-model.tsscript9.4 KB
scripts/generate-bgm.pyscript10.5 KB
scripts/iterate.tsscript4.0 KB
scripts/project-blueprint.tsscript12.1 KB
scripts/regenerate-scene.tsscript7.4 KB
scripts/render-qa.tsscript9.0 KB
scripts/scene-constitution.tsscript13.4 KB
scripts/timing-audit.tsscript9.5 KB
scripts/url-to-video.tsscript68.6 KB
scripts/visual-audit.tsscript26.5 KB

scripts/scene-constitution.ts

View on GitHub
/**
 * [INPUT]: BrandReport evidence package from url-to-video V2
 * [OUTPUT]: Design archetype inference, story intent draft, and scene-constitution object
 * [POS]: scripts/ 的本质层生成器; 把证据转成 mode-aware 叙事宪法
 * [PROTOCOL]: 变更时更新此头部,然后检查 AGENTS.md
 */

// ================================================================
//  URL-TO-VIDEO V2 — Scene Constitution Generator
// ================================================================

import {
  EDITORIAL_KEYWORDS,
  PRODUCT_KEYWORDS,
  keywordHits,
  type BrandReport,
  type VideoMode,
} from "./evidence-model.ts";

export type DesignArchetype =
  | "Financial Precision"
  | "System Clarity"
  | "Editorial Minimalism"
  | "Infra Authority"
  | "Productive Warmth";

export interface ArchetypeSelection {
  primary: DesignArchetype;
  secondary?: DesignArchetype;
  rationale: string[];
}

export interface PacingProfile {
  durationSeconds: number;
  style: "measured" | "kinetic" | "editorial";
  notes: string[];
  targetActs: Record<string, number>;
}

export interface SceneDefinition {
  id: string;
  act: number;
  label: string;
  purpose: string;
  visualSource: string[];
  copyPayload: string[];
  motionTemperament: string;
  evidenceDependency: string[];
  failureFallback: string;
}

export interface SceneConstitution {
  sourceUrl: string;
  generatedAt: string;
  mode: VideoMode;
  archetype: ArchetypeSelection;
  storyIntentDraft: string;
  pacingProfile: PacingProfile;
  sceneList: SceneDefinition[];
}

// 关键词列表和 keywordHits 统一从 evidence-model.ts 导入

export function inferDesignArchetype(report: BrandReport): ArchetypeSelection {
  const haystack = [
    report.brandName,
    report.textTruth.title,
    report.textTruth.headline,
    report.textTruth.subheadline,
    ...report.textTruth.featureNames,
    ...report.structureTruth.notes,
  ]
    .join(" ")
    .toLowerCase();

  const productHits = keywordHits(haystack, PRODUCT_KEYWORDS);
  const editorialHits = keywordHits(haystack, EDITORIAL_KEYWORDS);
  const financeHits = keywordHits(haystack, ["payments", "finance", "banking", "billing", "treasury"]);
  const designHits = keywordHits(haystack, ["design", "collaboration", "workspace", "productivity", "editor"]);
  const infraHits = keywordHits(haystack, ["infra", "security", "cloud", "data", "observability", "developer"]);

  const rationale: string[] = [];

  if (report.structureTruth.productType === "fintech" || financeHits >= 2) {
    rationale.push("Brand language signals trust-sensitive financial product behavior.");
    return {
      primary: "Financial Precision",
      secondary: infraHits > 0 ? "Infra Authority" : undefined,
      rationale,
    };
  }

  if (
    infraHits >= 2
    || report.structureTruth.productType === "developer-platform"
    || (productHits >= 3 && report.structureTruth.productType === "developer-platform")
  ) {
    rationale.push("Evidence points to developer, data, infra, or security credibility.");
    return {
      primary: "Infra Authority",
      secondary: designHits > 0 ? "System Clarity" : undefined,
      rationale,
    };
  }

  if (designHits >= 2) {
    rationale.push("UI/system density and workspace language suggest product/system clarity.");
    return {
      primary: "System Clarity",
      secondary: productHits > 0 ? "Productive Warmth" : undefined,
      rationale,
    };
  }

  if (report.suggestedMode === "editorial" && editorialHits >= 1) {
    rationale.push("Brand signal is visual/editorial before it is product-operational.");
    return {
      primary: "Editorial Minimalism",
      secondary: report.score.brandDistinctiveness >= 65 ? "Productive Warmth" : undefined,
      rationale,
    };
  }

  if (report.score.brandDistinctiveness >= 60 && report.score.screenshotCompleteness >= 45) {
    rationale.push("Distinct brand surface with usable visual proof supports warm branded storytelling.");
    return {
      primary: "Productive Warmth",
      secondary: report.suggestedMode === "editorial" ? "Editorial Minimalism" : "System Clarity",
      rationale,
    };
  }

  rationale.push("Defaulting to system clarity because the brand evidence is product-adjacent but not highly specific.");
  return {
    primary: "System Clarity",
    secondary: report.suggestedMode === "editorial" ? "Editorial Minimalism" : undefined,
    rationale,
  };
}

function buildPacingProfile(mode: VideoMode, report: BrandReport): PacingProfile {
  if (mode === "product-evidence") {
    return {
      durationSeconds: 40,
      style: report.score.videoUsefulness >= 55 ? "kinetic" : "measured",
      notes: [
        "Let product reality lead the rhythm.",
        "Reserve fastest motion for reveal/showcase handoffs.",
        "Proof act should feel calmer than feature montage.",
      ],
      targetActs: {
        authority: 5,
        reveal: 6,
        showcase: 14,
        proof: 8,
        close: 7,
      },
    };
  }

  if (mode === "editorial") {
    return {
      durationSeconds: 35,
      style: "editorial",
      notes: [
        "Use slower reveals and fewer simultaneous elements.",
        "Typography and crop discipline should do most of the work.",
        "Do not fake product interaction if evidence is weak.",
      ],
      targetActs: {
        "mood-establish": 6,
        "brand-claim": 7,
        "motif-expansion": 10,
        "trust-proof": 6,
        close: 6,
      },
    };
  }

  return {
    durationSeconds: 25,
    style: "measured",
    notes: [
      "Evidence is too weak for a credible auto-build.",
      "Generate only a gap report and a minimal editorial holding pattern.",
    ],
    targetActs: {
      gaps: 25,
    },
  };
}

function buildProductScenes(report: BrandReport): SceneDefinition[] {
  const fallback = "Fallback to screenshot-first framing and freeze UI motion into controlled parallax.";
  return [
    {
      id: "authority",
      act: 1,
      label: "Authority",
      purpose: "Establish the brand's category authority and serious tone in under five seconds.",
      visualSource: ["homepage-screenshot", "logo"],
      copyPayload: [report.textTruth.headline || report.textTruth.title, report.textTruth.subheadline].filter(Boolean),
      motionTemperament: "Measured camera move, restrained typography reveal, no gimmick particles.",
      evidenceDependency: ["homepage screenshot", "logo"],
      failureFallback: fallback,
    },
    {
      id: "reveal",
      act: 2,
      label: "Reveal",
      purpose: "Turn abstract promise into visible product reality.",
      visualSource: ["product-screenshot", "video", "hero-image"],
      copyPayload: report.textTruth.featureNames.slice(0, 2),
      motionTemperament: "Clip-led reveal if video exists; otherwise hard-framed product crop with editorial wipes.",
      evidenceDependency: ["product screenshot or demo clip"],
      failureFallback: "Use hero image and primary CTA while suppressing UI-claim language.",
    },
    {
      id: "showcase",
      act: 3,
      label: "Showcase",
      purpose: "Explain the operating model through 2-3 evidence-backed product moments.",
      visualSource: ["video", "product-screenshot", "proof-image"],
      copyPayload: report.textTruth.featureNames.slice(0, 4),
      motionTemperament: "Sequence rhythm follows product logic, not random montage energy.",
      evidenceDependency: ["at least two evidence-backed features"],
      failureFallback: "Reduce to two vignettes and reuse strongest product screenshot with alternate crops.",
    },
    {
      id: "proof",
      act: 4,
      label: "Proof",
      purpose: "Make trust visible through metrics, customer proof, compliance, or density of real product evidence.",
      visualSource: ["proof-image", "homepage-screenshot", "product-screenshot"],
      copyPayload: report.structureTruth.notes.slice(0, 3),
      motionTemperament: "Calmer pace, crisp counters, no hype motion.",
      evidenceDependency: ["proof-rich section or product detail"],
      failureFallback: "Use customer logos, metrics, or CTA sections from the homepage if product proof is weak.",
    },
    {
      id: "close",
      act: 5,
      label: "Close",
      purpose: "Resolve the narrative with one clear action and one memorable brand lockup.",
      visualSource: ["logo", "homepage-screenshot"],
      copyPayload: [...report.textTruth.cta.slice(0, 1), report.textTruth.title].filter(Boolean),
      motionTemperament: "Minimal motion, premium hold, strong contrast finish.",
      evidenceDependency: ["logo", "primary CTA"],
      failureFallback: "Use wordmark or favicon lockup with a simplified CTA plate.",
    },
  ];
}

function buildEditorialScenes(report: BrandReport): SceneDefinition[] {
  return [
    {
      id: "mood-establish",
      act: 1,
      label: "Mood Establish",
      purpose: "Introduce the brand world before making product claims.",
      visualSource: ["homepage-screenshot", "hero-image", "logo"],
      copyPayload: [report.textTruth.title, report.textTruth.headline].filter(Boolean),
      motionTemperament: "Slow editorial crop, subtle type entrance, atmosphere over density.",
      evidenceDependency: ["hero or homepage image"],
      failureFallback: "Fall back to logo and title only, with a neutral motion bed.",
    },
    {
      id: "brand-claim",
      act: 2,
      label: "Brand Claim",
      purpose: "State the brand promise with disciplined copy and hierarchy.",
      visualSource: ["homepage-screenshot", "proof-image"],
      copyPayload: [report.textTruth.subheadline, ...report.textTruth.cta.slice(0, 1)].filter(Boolean),
      motionTemperament: "Typography-first. No fake UI interaction.",
      evidenceDependency: ["headline or subheadline evidence"],
      failureFallback: "Use a distilled claim from title + category instead of fabricated copy.",
    },
    {
      id: "motif-expansion",
      act: 3,
      label: "Visual Motif Expansion",
      purpose: "Deepen the brand surface through recurring visual motifs, crops, and supportive artifacts.",
      visualSource: ["hero-image", "proof-image", "homepage-screenshot"],
      copyPayload: report.textTruth.featureNames.slice(0, 3),
      motionTemperament: "Layered editorial cuts, scale shifts, restrained texture motion.",
      evidenceDependency: ["multiple visual references"],
      failureFallback: "Reuse strongest hero image with alternate crops and type rhythm changes.",
    },
    {
      id: "trust-proof",
      act: 4,
      label: "Trust / Proof",
      purpose: "Anchor the piece in proof instead of pure mood.",
      visualSource: ["proof-image", "homepage-screenshot"],
      copyPayload: report.structureTruth.notes.slice(0, 2),
      motionTemperament: "Quiet proof cards or stat plates with generous breathing room.",
      evidenceDependency: ["metrics, customer logos, trust content, or clear CTA context"],
      failureFallback: "Use screenshot crops of trust sections or replace with category trust language from the site.",
    },
    {
      id: "close",
      act: 5,
      label: "Close",
      purpose: "Deliver one brand-true lockup that leaves room for manual polish.",
      visualSource: ["logo", "homepage-screenshot"],
      copyPayload: [...report.textTruth.cta.slice(0, 1), report.textTruth.title].filter(Boolean),
      motionTemperament: "Strong hold, simple brand plate, no extra effects.",
      evidenceDependency: ["logo or wordmark"],
      failureFallback: "Close on favicon-derived mark plus URL if no wordmark exists.",
    },
  ];
}

export function buildStoryIntentDraft(report: BrandReport, archetype: ArchetypeSelection): string {
  const headline = report.textTruth.headline || report.textTruth.title || report.brandName;

  if (report.suggestedMode === "product-evidence") {
    return `Show ${report.brandName} as a credible ${report.structureTruth.productType} system: lead with ${headline}, prove it with real interface evidence, and close with one decisive action in a ${archetype.primary} tone.`;
  }

  if (report.suggestedMode === "editorial") {
    return `Treat ${report.brandName} as a brand world first and a product second: let the visual surface, copy hierarchy, and trust cues carry the film in a ${archetype.primary} register.`;
  }

  return `Evidence is weak. Build a minimal editorial holding pattern for ${report.brandName}, surface the missing proof, and avoid any fabricated product story.`;
}

export function buildSceneConstitution(report: BrandReport): SceneConstitution {
  const archetype = inferDesignArchetype(report);
  const storyIntentDraft = buildStoryIntentDraft(report, archetype);
  const pacingProfile = buildPacingProfile(report.suggestedMode, report);
  const sceneList =
    report.suggestedMode === "product-evidence"
      ? buildProductScenes(report)
      : report.suggestedMode === "editorial"
        ? buildEditorialScenes(report)
        : [
            {
              id: "gaps",
              act: 1,
              label: "Gap Report",
              purpose: "Stop before fiction and explain what evidence is missing.",
              visualSource: ["homepage-screenshot"],
              copyPayload: report.risks,
              motionTemperament: "Static editorial board with concise warnings.",
              evidenceDependency: ["at least one traceable screenshot"],
              failureFallback: "Emit report only; do not generate a fake first cut.",
            },
          ];

  return {
    sourceUrl: report.sourceUrl,
    generatedAt: report.generatedAt,
    mode: report.suggestedMode,
    archetype,
    storyIntentDraft,
    pacingProfile,
    sceneList,
  };
}
planning-and-task-breakdownaddyosmani/agent-skillsBreaks work into ordered tasks. Use when you have a spec or clear requirements and need to break work into implementable tasks. Use when a task feels too large to start, when you need to estimate scope, or when parallel work is possible.Stars: 119kUpdated Claude CodeCodexVerifiedInstall
screenpipethedotmack/claude-memSearch screen and audio history recorded by Screenpipe and optionally save selected context into claude-mem. Use when the user asks to recall desktop activity, a meeting, or something seen in another app through Screenpipe.Stars: 118kUpdated Claude CodeCodexVerifiedInstall
contact-widgetnexu-io/open-designSelf-contained floating chat widget with welcome screen, social links, meeting button, and message input. Single HTML file, zero dependencies.Stars: 108kUpdated Claude CodeCodexVerifiedInstall
meeting-notesnexu-io/open-designMeeting notes page — title bar with attendees, agenda checklist, decisions block, action items table with owners + dates, and a "next meeting" footer. Use when the brief mentions "meeting notes", "minutes", "1:1 notes", "all-hands recap", or "会议纪要".Stars: 108kUpdated Claude CodeCodexVerifiedInstall