Audit metadata prompt fallback boundaries

This commit is contained in:
2026-06-27 17:31:30 +02:00
parent 1950ce7bbf
commit c59c9947b2
4 changed files with 83 additions and 1 deletions
+12
View File
@@ -1385,6 +1385,18 @@ def smoke_krea_normal_row_routes() -> None:
"style": "realistic creator-shot photography",
}
_expect_krea_normal_route_parity(single, "krea_normal_single", "metadata(single)")
style_metadata = dict(
single,
style="metadata style phrase",
positive_suffix="metadata suffix phrase",
prompt="Use: stale prompt suffix phrase.",
)
style_prompt, style_method = krea_formatter._normal_row_to_krea(style_metadata, "balanced", "preserve")
_expect(style_method == "metadata(single)", "Krea style metadata route changed method")
style_prompt_lower = style_prompt.lower()
_expect("metadata style phrase" in style_prompt_lower, "Krea metadata route lost structured style")
_expect("metadata suffix phrase" in style_prompt_lower, "Krea metadata route lost structured positive suffix")
_expect("stale prompt suffix" not in style_prompt_lower, "Krea metadata route parsed stale Use prompt text")
couple = {
"subject_type": "couple",