Product Video Replication V1.2.1
Transform user-provided product details and reference videos into playable, traceable, and iterable final videos. First determine what to retain, then select model capabilities. This package is an Agent execution specification and toolkit, not a standalone program that works without models, network, or authorization.
Execution Conventions
- By default, produce 1 complete video; explore 2–3 if there are substantially different strategies and the user allows it. If the user explicitly requests three versions, plan for three. Maximum of 3 final plans can be in progress concurrently. Multiple model tasks within a single plan do not count as multiple final videos, but they are still subject to service concurrency limits; tasks are serial by default, and the concurrency may be increased to a maximum of 3 only after confirming quotas.
- User specifications for product, model, duration, reference scope, and fidelity take priority. If the product is mismatched or identity is unclear, ask. For authorized choices such as shots, segments, and prompts, proceed autonomously without repeated confirmation.
- Do not include product PID, internal IDs, local paths, or unrelated brand names in prompts. Prefer SKUs confirmable from product images and claims with clear sources; do not fabricate features, prices, or test results.
- Save the actual inputs, requests, configurations, outputs, post-processing steps, reasoning, failures, and verification for each plan. Record evidence, choices, and trade-offs, but not private reasoning chains or credentials. Archive locally first, then publish to platforms as requested; do not send additional messages or share publicly.
- The goal is to deliver all planned 1–3 videos, with at least one passing minimum acceptance. If all fail, report truthfully; do not pretend to meet the minimum count, nor pay for unlimited retries.
Stage-Based Loading
| Stage | Read |
|---|---|
| First run, switching Agents | Running & Migration |
| Command examples from input to delivery | Complete Walkthrough |
| Understanding, duration, strategy, prompts | Decision Tree |
| Intro, story, talking head, subtitles, character & SKU fidelity | V1.2.1 Fidelity Gates |
| Planning, versions & metadata | Data Contract |
| Current Codex + Xiao Yun Que | Current Adapters |
| Replacing understanding, generation, image, or audio tools | Open Adapter Interface |
| Execution, recovery, post-processing, acceptance | Execution & QA |
| Local annotation platform | Platform Adaptation |
| Encountered counterexamples | Regression Cases |
End-to-End Steps
- Clarify Goals: Create run.json, parse product, SKU, images, references, and requirements; probe multiple references one by one, select, and record reasons for exclusion. Clarify mismatched names/images first. Check for existing tasks to avoid duplicate submissions.
- Discover Capabilities: Confirm available understanding, generation, and media processing tools and authentication; query current model and pattern limitations, save raw and normalized capability snapshots. Unknown does not mean unlimited; unavailable specified models must not be silently replaced.
- Understand Reference: Probe video stream and container duration, frame rate, dimensions, and audio tracks. Extract frames covering the entire video, then perform deep hooks on close-ups, products, transitions, and cut points; talking heads or stories require audio/transcription. Record the actual understanding model, frame extraction rate, scope, timestamps, and limits. Output content structure, segment-by-segment talking head/subtitle coverage, single subtitle responsibility source, character voice and position portrait, BGM/key actions, and SKU geometry negative constraints. Extracting frames is not equivalent to having visually analyzed them.
- Determine Retention & Length Strategy: Select shots, causality, functional modules, local elements, or emotional mechanisms. Map attention-grabbing intros, linguistic structure, storyline relationships, first/second half talking-head/subtitles, BGM, and key actions based on reference fingerprints. If strict full-length replication exceeds limits, segment at natural cut points; if compressed adaptation is allowed, rewrite a complete short advertisement, defaulting to at least 85% of the reference total duration. Extracting only the intro requires user permission; do not present the intro as a complete advertisement. Check both input total duration and output duration separately.
- Plan 1–3 Plans: Strategies must have substantive differences. Describe how the product participates in transitions, bind timeline, material roles, character identity references, segment-by-segment talking head/subtitle coverage, subtitle responsibility source, BGM, duration, SKU geometry negative constraints, risks, and acceptance criteria. When the same character spans multiple segments, prioritize preparing and reusing one set of three-view/character reference images; if identity assets cannot be bound, reduce segments and mark risks. Save plan.json and prompts; run
scripts/replica.py validate-plan, then manually check semantics and pattern constraints. - Invoke Generation: Prepare reference segments/condition images based on dependencies; visually inspect condition images first; save material paths and hashes. Record intent before submission; immediately save ID/link after submission and inform the user. Query and download using the original ID; do not regenerate on slow downloads or download failures. Adhere to failure classification and limited retries.
- Post-Processing: Retain original model files. Trim and composite based on target frame count/PTS, and check seams; do not use speed changes to mask duration errors. Handle audio tracks according to policy; rewritten stories must not default to carrying over old product talking head. Keep only one trusted source for subtitles.
- Acceptance & Iteration: Verify file and complete decoding, duration/frame count/audio tracks; separately assess product correctness, intro/story mechanism, segment-by-segment talking head and subtitle coverage, subtitle duplication, character consistency and positional composition, voice portrait, BGM/key actions, duration ratio, and continuity. Videos that closely resemble the reference but have not replaced the product, missing talking head segments, dual subtitles, or degraded storytelling are still failures. First fix post-processing; generation revisions within budget default to once maximum, create parent-child versions, retain old version and user evaluation.
- Delivery: Associate each version with method, version, prompts, actual configuration, Input, original and final Output, workflow, and QA. Write results.md; attach them side-by-side to the corresponding reference video as required and verify playback/refresh. Report completion count, differences, quality limitations, and outstanding items.
Continuing a Run
After interruption, first read run.json, plan.json, events.jsonl, and jobs/*/state.json. If task IDs exist, query them; for submitting/submission_unknown without IDs, first verify the server side, absolutely forbid re-submitting. Downloaded only means the file was obtained; validated means minimum acceptance passed. Update agent.md at key stages to allow other Agents to take over.