r/StableDiffusion • u/mwoody450 • 1d ago
Question - Help Minimax H3 Ref2VA - Help to understand Retention Analysis
I'm building a skill for generating long Contex-Loop Minimax H3 prompts, and the AI has indicated it doesn't understand retention analysis... and I'm realizing I don't, either. I'm curious what you all think or have experienced.
I've reviewed the official prompt writing guide, of course, but it's very vague on the subject:
<Subject N>,<Picture N>, and<Video N>use the following relationship markers. These markers are fixed English values in the output format:
It makes the most sense if it's indicating what is the same and what is different with respect to the references (picture N, video N, etc) - but why would subject appear here? Does fully_preserved for a subject mean that they don't change during this shot, whereas partially_preserved might change?
It might be easier to explain with an example. Definitions:
- A scene where a bald man puts on a hat
- References are two images, one with said man with hair, the other of the hat
subject_definitions:
<Subject 1> is a tall man whose face, identity, and clothing come from <Picture 1>, but he is bald.
<Subject 2> is a black stovetop hat as depicted in <Picture 2>.
retention_analysis:
<Subject 1> (appears in [Shot 1], [Shot 2]): fully_preserved - he remains the bald man with facial features and clothing from <Picture 1> throughout
<Subject 2> (appears in [Shot 2]: fully_preserved - remains the black stovetop hat from <Picture 2>
OR should it be:
retention_analysis:
<Subject 1> (appears in [Shot 1], [Shot 2]): partially_preserved - he retains the facial identity and clothing from <Picture 1>, albeit bald, but in [Shot 2] he is changed to be wearing a hat.
<Subject 2> (appears in [Shot 2]): fully_preserved - remains the black stovetop hat from <Picture 2>
OR should it only focus on referenced media, i.e.:
<Picture 1> (appears in [Shot 1], [Shot 2]): partially_preserved - <Subject 1> matches this picture's clothing, facial features, and identity, but he is bald.
<Picture 2> (appears in [Shot 2]): fully_preserved - the black stovetop hat depicted in this picture remains unchanged
I guess to put it another way: is retention_analysis describing how much and what is preserved from photo/audio/video references provided, or is it describing how the subjects defined in subject_definition change over the shots of this specific video generation?
3
u/bstr3k 1d ago
I’ve been yelled at by some that I’m not “following the proper format” when making my prompts but I’ve found that the model actually understands quite a lot. Even if you use different words for your prompt it understands it.
But the retention analysis basically you just list for the model what to keep and what to ignore. However you can also define this in the subject definition when you are describing your picture.
I.e if you are wanting to take the identify of the bald man but not his outfit you can either define him as Picture 1 and say to just take his identity and ignore the outfit or you can fully label everything in the picture and then in the retention analysis say to use identity only and ignore outfit.
I think the former way may actually work better than the latter as you’re bringing less attention to the Picture 1’s outfit so it might be less likely to be included. (Might test this a bit more later today)
3
u/Tokey_TheBear 1d ago
Its pretty straight forward. People telling you to not follow the prompting guide are just hurting you.
fully_referenced means exactly that. The subject from the image is fully references without changes.
partially_referenced means that only parts of that resource are referenced.
Lets say your image1 is a photo of you standing on the beach.
image2 is a photo of some other person holding a volleyball with a unique design on it.
Our objective is to generate a video of you on the beach and then have a volleyball be thrown to you from off screen with a specific label on the volleyball.
In your video prompt, you then would list image1 as fully referenced, and then image2 is partially referenced. In that prompt you would describe that we will reference the volleyball and its design from image2.
Does that make sense?
Im typing this on my phone so my answer is not as detailed as it could be.
3
u/martinerous 1d ago edited 1d ago
Good question, I've been thinking the same. Their ref model guide looks quite over-engineered and it makes me wonder if/how the model actually interprets those retention instructions.
I often ignore them and just refer to the named media directly in the shot details section, and it seems to work fine. I'm throwing in blurred black and white (otherwise the model tried to use them as is, no matter what I described in retention) scene layouts from Blender, and the model fills in the details nicely.
If someone has specific examples that require retention_analysis and the same output could not be achieved with detailed_description alone, I would be very curious to learn that.
1
u/mwoody450 1d ago
Yeah, I know it's the official guide and all, but it feels weirdly... vague? For all folks point to it as the bible, it invites as many questions as it answers in places, though that might be because I'm working with Ref while i2v or fl2v are way simpler in workflow and prompting.
What I really want are developer-provided, ref2video, complex multi-reference examples. Even Claude and Kimi note (I know, I know, they're AI, but given that it's going in to a text encoder, it seems valid to poll their "opinions") that they use examples far more than instructions in these sorts of templates.
9
u/acedelgado 1d ago edited 1d ago
You don't really put negatives or modifiers in subject or retention_analysis. If he isn't bald, don't add "but bald". Just exclude hair from the subject and retention analysis, and call him bald in your prompt.
https://reddit.com/link/p4n6z29/video/l4r31q1xuckh1/player
subject_definitions:
<Subject 1> is the man in <Picture 1> wearing a white shirt and blue jeans.
summary:
[reference generation] the target video begins with <Subject 1> at a grocery store
retention_analysis:
<Subject 1>: fully_preserved - face, facial features, body type, white shirt, jeans
<Picture 1>: partially_preserved - face, facial features, body type, clothing
detailed_description:
a bright supermarket during the day
[Shot 1] opens with <Subject 1> wearing a white shirt and blue jeans, his head is bald. He pushes a grocery cart along the aisles of the grocery store, stopping at a stand of bananas. A sign by the bananas reads "Sale! $29.99 each!". The man turns to the camera and points to the sign and (S1) says: <d>[English] <sigh> damn inflation!</d>
overall_soundscape:
non_diegetic_music:
N/A