Dalian Works
aifilm

First-Frame and Last-Frame Dual-Image Driven Jimeng Video Generation Logic

Published 2026-11-03 · Translated from the Chinese original

When you open any dbvideo_process storyboard record in the Yuncao Academy system, you'll find that it does not directly correspond to a video file, but rather to two images in an arcpictask task: one first-frame image with the suffix -a, and one last-frame image with the suffix -b. These two images are the only physical inputs for all subsequent video generation actions. The Jimeng video model is essentially not a diffusion model that generates frames from scratch, but a motion generator that performs interpolation prediction based on input conditions. It receives two static images, along with a plain-text instruction describing the actions that should occur in the scene, and then the model automatically computes a coherent motion path between the two fixed visual endpoints, producing a video segment of approximately five seconds in length. This mechanism determines that the visual difference between the first frame and the last frame directly defines the only dynamic possibility in the video. The text instruction merely adds guiding weight for the model to choose a reasonable motion trajectory between the two endpoints. Breaking down the actual workflow, before each storyboard record generates video, the system first calls the arcpictask task to generate the first and last frame images. The taskdes field in arcpictask stores the specific image generation prompt, and the system branches based on storyboard type. If the storyboard contains a character, it first synchronizes the character image from Volcano Engine via drawrole, then uses the character-containing branch of placeaiwords combined with scenetopic for image-to-image synthesis, resulting in an output image containing both the person and the environment. If the storyboard is an empty shot, it goes through the empty-rolex branch of placeaiwords, taking a pure text-to-image path. Regardless of the method, the image generation module ultimately outputs two images with identical dimensions, composition, and lighting. The first image is numbered SCN000245-a.png, representing the static moment at the start of the action; the second is numbered SCN000245-b.png, representing the static moment at the end of the action. These two images must both appear in the local arcpictask output directory, and the filenames must strictly follow the naming rules, or the subsequent Jimeng video task will not be able to read them correctly. Take the sword-swinging action of Lin Xuan on the city wall in Five Elements Dragon Flag as an example. The storyboard text describes: Lin Xuan draws the long blade from his waist, slashes forward, and the blade edge traces a silver arc. When the system generates the first-frame image, the taskdes prompt includes Lin Xuan's right hand gripping the sword hilt, the blade still in the sheath, the action not yet unfolded, focus on his face, the environment as an ancient city wall, and dusk lighting. The last-frame prompt, meanwhile, emphasizes Lin Xuan's right arm fully extended, the long blade pointing forward, the blade parallel to the ground, the tip outward, and his robes blown backward by the wind, in the same environment and lighting. When Jimeng receives these two images and the text prompt, the model needs to automatically infer the intermediate motion process from drawing the blade to slashing down. The larger the visual gap between the first and last frames, the more intermediate frames the model needs to fill in, the longer the generated video, and the more likely subtle motion changes will go out of control. Therefore, in the Yuncao Academy system, the taskdes template for arcpictask is deliberately designed to favor dual-frame images with clear contrast but not excessive exaggeration, ensuring motion coherence. This dual-frame driven approach has an obvious hard requirement: the first and last frames must be generated as a pair. If for some reason—such as model generation failure, network interruption, or task timeout—only the -a image is generated for a shot without the -b image, then when the system checks the arcpictask table status, it will leave the secondpic field as the STCODE.png placeholder. This placeholder is the most intuitive failure signal in the entire system. It means that the video generation task for that storyboard cannot start, because the Jimeng interface does not accept single-frame input; forcibly passing a single frame will cause the interface to directly return an error code. During the entire production cycle of "The First Avenue," this placeholder situation occurred three times. Once was a location image generation task where the -b image timed out due to temporary overload on the Volcano Engine side. The other two times, the first and last frames were generated with inconsistent dimensions, and the system refused to submit two images of different sizes to Jimeng simultaneously. The solution to these problems was simple: re-run the arcpictask task to regenerate the missing last frame or unify the dimensions, then submit to Jimeng again. This requirement for paired image generation may seem stringent, but it genuinely guarantees the stability of video generation quality. If the first and last frames were replaced with a single frame plus plain-text prompts, the Jimeng model would have far more freedom to guess the motion, but the guessed result often does not match the original storyboard intent. For instance, with the same sword-slashing action, if you input only a static image of someone holding a blade, the model might interpret the action as returning the blade to the sheath rather than slashing forward. The existence of the last frame fixes the endpoint of the motion, leaving only one path to take. This constraint is especially important for multi-shot splicing. In "The First Avenue," 1,029 shots needed to be assembled into a complete film in script order. If the actions of a character cannot connect between adjacent shots—for example, if the previous shot ends with drawing a sword but the next shot's first frame shows sheathing it—then the edit will have an obvious jump cut. But with the first-frame and last-frame design, each storyboard's final frame (the -b image) is properly exposed, and the editing system can precisely check the action relationships between adjacent shots, adjusting or regenerating mismatched shots in advance. There is also an easily overlooked detail in actual operation: the -a and -b suffixes in the image filenames are not just naming conventions; they also serve a task-differentiation function in the scheduling system. When three computers are generating images in parallel, each machine handles different arcpictask tasks, but all generated images are stored in the same directory structure. The system uses the -a and -b suffixes in the filenames, along with the scenecode, to uniquely identify a pair of images, ensuring that last frames from different storyboards are never mixed up. This naming rule makes debugging and tracing extremely straightforward. When a video generation fails, you only need to look at the corresponding arcpictask record's secondpic field. If it is the STCODE.png placeholder, you immediately locate the missing last-frame task number and restart that task. If the secondpic field contains a normal image filename, then the problem lies in Jimeng's own generation channel, and the response is to check whether the uid bound to CRTOR is valid. In the end, the first-frame and last-frame dual-image driven methodology yields a clear conclusion: in image-to-video models like Jimeng, text prompts are responsible for expressing intent, but what truly determines the physical laws of the video is the visual difference between the two image endpoints. Therefore, the effort you invest in generating the first and last frames should be far greater than the polish of the text prompt. You should know that even if you write the prompt with extraordinary nuance, Jimeng will not execute any action that is not aligned with the image content in the text. It only generates intermediate frames based on the difference between the two images. Instead of spending time piling up literary verbs and adjectives, it is better to carefully plan the start and end state of each shot, ensuring that the first frame and the last frame contain sufficient spatial displacement, expression changes, or camera motion signals. In other words, thinking clearly about where this shot starts and where it ends is more valuable than thinking about how to describe this shot. A key reason this system could complete 1,029 shots in eleven days with three computers is that it transformed dynamic descriptions that require creativity into static layouts that require planning. This transformation drastically reduced trial-and-error costs and made the video generation pipeline fully predictable.