fix(characters): map tricorn hats to a period helm in image prompts

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
mARTin-B78 2026-09-20 16:13:50 +02:00
parent fb4cdbba0c
commit 4b59d06479
2 changed files with 4 additions and 0 deletions

View File

@ -1740,6 +1740,7 @@ _PERIOD_WORDING = (
(r"jacken?\b|jacket\w*", "wool tunic"),
(r"westen?\b|waistcoat\w*|vest\b", "sleeveless leather jerkin"),
(r"schals?\b|scarf|scarves", "wool neck-wrap"),
(r"dreispitz\w*|dreimaster|tricorn\w*|dreieckshut|three-cornered hat", "plain iron helm"),
(r"h[üu]te?\b(?!\w)|\bhats?\b", "soft wool hood"),
(r"sporen|spurs?", "stitched leather boots"),
(r"hosen?\b|trousers|pants", "wool leggings"),

View File

@ -189,6 +189,9 @@ class PromptHygieneTests(unittest.TestCase):
self.assertNotIn("blut", text.lower())
self.assertNotIn("verbunden", text.lower())
def test_a_tricorn_hat_becomes_a_helm(self):
self.assertNotIn("dreispitz", self.facts(clothing="Rüstung mit Dreispitz").lower())
def test_soot_and_dirt_are_not_painted_on(self):
text = self.facts(physical="Wallendes Haar, rußverschmierte Backen.")
self.assertIn("Wallendes Haar", text)