Tech10 min read

Anima 4-char LoRA put the outfit on whoever stood foreground-right, 12/12

IkesanContents

In the previous run, where I split a complex 4-character scene into three factors, Kurara and Kei talking in front, Koharu with her arms crossed on the right, and Kana waving at the back all came out on all 3 seeds. But the gray skirt and black tights assigned to Kana were worn 3/3 by Koharu, who stands foreground-right.

This time I swap the standing position and the outfit assignment for Kana and Koharu independently. The point is to see whether Kana keeps the black tights after the swap, or whether whoever ends up standing foreground-right wears them.

Test environment

ItemSetting
EnvironmentComfyUI on an M4 Mac mini
modelanima-base-v1.0
text encoderqwen_3_06b_base
4-character LoRAanima-4char-v1_epoch100
Turbonone
samplerer_sde / simple
steps / cfg25 / 4.0
Resolution1344×768
seed42, 1234, 9999

Position and outfit swapped separately

Did Koharu wear the outfit assigned to Kana? Or did the gray skirt and black tights simply happen to come out foreground-right? The original 111 on its own cannot tell the two apart.

For Kana and Koharu only, I varied the two instructions that could be responsible, one at a time.

Instruction01
P: rolesKana waving at the back / Koharu with arms crossed foreground-rightKoharu waving at the back / Kana with arms crossed foreground-right
O: outfitgray skirt and black tights on the character at the backgray skirt and black tights on the character foreground-right

Kurara and Kei’s conversation, the classroom, the camera, the ID anchors, the remaining uniforms, the negative prompt, the seeds and the generation settings were all fixed. The order of the characters inside the outfit sentence was always kanachan then koharu. P0O0 is the same prompt as the original 111, and the three regenerated images matched the original ones down to the RGB pixel values.

The grid below is the overview; I judged the details from the individual images that follow.

Four conditions × 3 seeds, swapping Kana and Koharu's roles and outfits independently

At P0O0 the black tights assigned to Kana at the back came out foreground-right

P0O0 seed 42. The gray skirt and black tights assigned to Kana at the back were worn by Koharu, standing foreground-right P0O0 seed 1234. Kana at the back ended up in a navy skirt and white legwear, and Koharu foreground-right wore the gray skirt and black tights P0O0 seed 9999. In the third image too, the black tights were on Koharu foreground-right

At P0O1 the character named and the foreground-right position lined up

P0O1 seed 42. The black tights were assigned to Koharu foreground-right, and that is where they came out P0O1 seed 1234. Koharu foreground-right wore the black tights, but Kana at the back got white legwear that was never requested P0O1 seed 9999. Koharu wore the black tights, while the skirt looks navy rather than the gray that was requested

At P1O0 the black tights stayed foreground-right after the position swap

I swapped the roles so that Koharu waves at the back and Kana crosses her arms foreground-right, and assigned the gray skirt and black tights to Koharu at the back.

P1O0 seed 42. Koharu waving at the back and Kana with her arms crossed foreground-right both came out, but the gray skirt and black tights were on Kana P1O0 seed 1234. The position and action swap worked, and the lower-body outfit stayed on Kana foreground-right P1O0 seed 9999. In the third image too, Koharu at the back is in a navy skirt while Kana foreground-right wears the gray skirt and black tights

At P1O1 the assignment to Kana foreground-right also matched the output

P1O1 seed 42. The black tights were assigned to Kana foreground-right, and that is where they came out P1O1 seed 1234. Kana foreground-right wore the gray skirt and black tights P1O1 seed 9999. Character, action and the target of the black tights all lined up foreground-right

In the scoring, the head count and character separation plus the rough roles were 3/3 in all four conditions. The black tights coming out foreground-right was 3/3 in every condition as well. The table narrows to whether the character I named wore them. I did not merge the gray skirt and the black tights into one item, and counted the color and the legwear separately.

cellBlack tights on the named characterGray skirt on the named character
P0O00/30/3
P0O13/32/3
P1O00/30/3
P1O13/33/3

The named character wore the black tights in 6/12, while the reacting character foreground-right wore them 12/12. Taking only P0O0 and P1O0, where the named character and the foreground-right position are set against each other, the named character is 0/6 and foreground-right is 6/6.

At the same time, swapping Kana and Koharu’s positions and actions (P1O0/P1O1) passed 6/6. Four characters, the front-to-back arrangement, the conversation, the crossed arms and the waving at the back all come out. In P1O0 only the position and the action swapped, and the lower-body outfit was on Kana, who was standing foreground-right.

The black tights are an outfit item I wrote into the prompt for this dress-up test, and they are present in 12/12 of the outputs. What fits the results is that in this checkpoint’s inference, character separation, the role in the scene and the swappable outfit are represented separately, and at the stage that decides who wears the outfit, a shortcut to the foreground-right position takes priority.

The successes at P0O1 and P1O1 do not necessarily reproduce once the target of the assignment changes. Generating a single condition in the normal way cannot separate an output that understood the prompt from an output where the assignment target happened to coincide with where the shortcut leads. This 2×2 was run to split those apart.

Restating it explicitly at the end did not fix it

I also checked whether an appended sentence alone could override it. I added exactly one of two sentences to P1O0 and generated 3 seeds each. One restates the assignment exclusively by character name, as in koharu alone wears ... / kanachan ... no tights; the other restates it by the spatial role, as in only the small background waving girl ... / foreground-right arms-crossed girl ... no tights.

With the name-based restatement, the black tights stayed on Kana foreground-right on all 3 seeds.

Name-based restatement, seed 42. Even written as Koharu alone in black tights and Kana with no tights, Kana foreground-right wore the black tights Name-based restatement, seed 1234. The outfit was not fixed, and Kei moved to the background as well, breaking the conversation pair Name-based restatement, seed 9999. The black tights are still on Kana foreground-right

With the role-based restatement, Koharu never wore the black tights either, and at seed 1234 the count dropped to three and the scene broke with it.

Role-based restatement, seed 42. Koharu at the back is in a navy skirt with bare legs, and the gray skirt came out foreground-right. The foreground-right legs are out of frame, so the black tights cannot be judged Role-based restatement, seed 1234. The count dropped to three, Koharu is gone, and it is Kei waving in the background. The black tights are on Kana foreground-right Role-based restatement, seed 9999. The 4-character scene held, but the black tights stayed on Kana foreground-right

Images where Koharu at the back wore the black tights: 0/6. Across the 5 images where Kana’s legs are visible foreground-right, she wore them 5/5. On top of that, 2 of the 6 broke either the head count or the conversation pair.

Neither repeating the character names at the end of the same long prompt nor restating the assignment exclusively by spatial role worked as a stable countermeasure. With this structure, the more sentences I add the more the other slots break, and getting one correct image by re-rolling seeds stays the way it works.

Shortening it and writing the outfit next to the name did not fix it either

111 came to 435 Qwen tokens and 518 T5 tokens. The ComfyUI Anima implementation pads a T5 sequence up to 512 when it is shorter, but does not truncate one that goes past 512. This 111 enters the LLMAdapter at its full 518 positions.

The outfit sentences sit at the end, starting at T5 positions 400 for Kurara, 425 for Kei, 456 for Kana and 484 for Koharu. I suspected the outfit was weak because the prompt is long and the assignment sits near the back.

I rewrote the same scene into three other prompt structures and compared them. Images usable as a finished illustration were 0/3 in every structure.

StructureQwen / T5 tokensChangeScene held
v1435 / 518The original text used in the previous run3/3
v2293 / 341Duplication removed, one character’s information gathered into a single slot2/3
v3424 / 498v1’s structure kept, with only the outfit moved into each character’s description sentence0/3
v4433 / 512v3 with the four names listed again at the end0/3

The v1 seed 42 image is the same one as in the previous article, so only the seed 42 image of each rewritten structure is placed here.

v2 seed 42. Kana's black tights came back, but Koharu's exasperated expression got weaker v3 seed 42. Moving the outfit into each character's action sentence made Koharu disappear, and someone else was doing the arm-crossing v4 seed 42. Listing the four names again at the end did not bring Koharu back

In v2 Kana’s black tights went from 0/3 to 2/3, while Koharu’s exasperated face went from 3/3 to 0/3. At seed 1234 the depth itself disappeared and the character attributes mixed as well.

In v3 Kana’s black tights came back 3/3. But Koharu was gone on all 3 seeds, and the crossed arms and exasperated face that were supposed to be hers went to Kana once and to Kei twice. In v4, which puts the four names back at the end, Koharu stayed at 0/3.

These results do not support any of the following: that it fails because T5 goes over 512, that shorter prompts are better, that the outfit should be written next to the character’s name, or that recounting the names at the end helps.

The comparisons from here on are fixed to v1’s word order, the one that kept character separation and the rough roles at 3/3. v1 writes the total head count and the front and back counts first, groups the relationships between characters by role, and places the four attribute slots at the end. Moving where the slots sit changes the head count and the roles even when the content is the same, so leaving this alone was the best way to follow the differences. That does not make it an order that reliably produces a finished scene.

Removing the appearance lines the way the old caption design says broke the output

I went back over two things: the features deliberately kept out of the captions so they would burn into the trigger, and the wording that was put into the captions instead.

In v1 of the 3-character LoRA, only Kana had side ponytail, ahoge, medium hair and blue scrunchie written into all 65 of her training captions. Kei and Koharu had almost nothing about hair or eyes. Because of that asymmetry, Kana’s appearance alone was detached from kanachan and moved to the generic attribute side, and with three characters she was absorbed into Kei.

In v2 the hair and eye descriptions were removed from everyone’s solo training captions, Kana included, letting the trigger absorb the appearance. That article also confirmed that writing brown side ponytail and the like back in at inference time makes the attribute show up on the neighboring character, and that using only trigger names and positions fixes it.

The multi-character training captions written for the 4-character LoRA, on the other hand, brought back short ID anchors for telling the characters apart: side ponytail+ahoge for Kana, blonde+blue ribbon for Kei, short dark hair+red eyes for Koharu and rose-brown hair+earrings+makeup for Kurara. The current checkpoint therefore holds two designs at once: absorb the appearance into the trigger for solos, and write the ID anchors into the text for multis.

From v1’s 111 I removed only these four appearance descriptions. Roles, positions, the per-character outfits, the negative prompt, the seeds and the generation settings were left unchanged.

v5 with the appearance descriptions removed, seed 42. The count dropped to three, and both the foreground and the background went brown-haired v5 with the appearance descriptions removed, seed 1234. There are four characters, but all of them are brown-haired and the separation failed v5 with the appearance descriptions removed, seed 9999. The role arrangement survives, but the hair colors and faces converged

The result was 0/3 on character separation and 2/3 on getting exactly four characters. “Don’t write the appearance”, which worked on the 3-character LoRA v2, does not carry over to this 4-character LoRA, and removing the ID anchors alone broke the separation.

The outfit mix-up was not fixed either. At seeds 1234 and 9999 the gray skirt and black tights assigned to Kana were still worn by the reacting character on the right. The mix-up survives removing every appearance description, which rules out the descriptions written back in as the cause.

Kana’s black tights are present in 12/12 of the outputs, so they were not weakly learned either. Outfits were never meant to burn into the trigger in the first place, and the crossing happens at the stage of deciding which character in the scene wears which of the four swappable outfits. Remove the ID anchors and the separation itself breaks instead. The current checkpoint needs the ID anchors for separation, yet as appearance, role and outfit are added at the same time, it gets weaker at putting the outfit on the right character.

Leaving descriptions out means something different for a single-character LoRA and a multi-character one. For a single character, dropping unchanging elements like hairstyle and hair color from the captions and letting the trigger absorb them worked. When four characters go into the same training images, though, dropping too much from everyone also weakens the supervision that separates which element belongs to which trigger. v5 here looks like that over-dropped side reproduced through the inference prompt.

Raising or lowering the amount of description across the board does not fix both of these at once. Keep the minimum ID anchors that tell the characters apart, the hair, the ribbon, the eyes, and write the swappable outfit into the prompt every time. On top of that, the training data used here contains no image where the same character is moved between foreground, background, crossed arms and waving. Until that is added, there is room for the outfit to be decided by position or role rather than by character.