Route references found in full chunk prompts
tests / test (push) Canceled after 0s
tests / windows-storage (push) Canceled after 0s

This commit is contained in:
2026-10-15 20:59:33 +00:00
parent 92ed0cfc31
commit 6aae047401
2 changed files with 33 additions and 1 deletions
+22
View File
@@ -100,3 +100,25 @@ def test_builder_routes_connected_references_only_to_mentioning_chunks():
assert bundle.reference_use == "Per chunk"
assert bundle.selectors == ("1", "1,2", "off", "off", "off", "off", "off", "off", "off")
assert bundle.images[0] is not None and bundle.images[1] is not None
def test_builder_routes_references_mentioned_anywhere_in_each_chunk_prompt():
value = {
"clips": [
{"slots": [{"start": 0, "end": 4, "text": "The subject walks."}]},
{"slots": [{"start": 0, "end": 4, "text": "The subject stops."}]},
]
}
result = DumasH3SequencePromptBuilder().build(
2,
4,
"Preserve the environment from @R1.",
json.dumps(value),
"Use ambience from @R2.",
"Music follows @R3.",
reference_image_1=object(),
reference_image_2=object(),
reference_image_3=object(),
)
assert result[3].selectors[:3] == ("1,2", "1,2", "1,2")