mirror of
https://github.com/vegu-ai/talemate.git
synced 2025-09-01 09:59:08 +00:00
fix issue where narration responses starting with # would result in empty messages
This commit is contained in:
parent
5b88700660
commit
5afff02f28
1 changed files with 5 additions and 3 deletions
|
@ -252,13 +252,15 @@ class NarratorAgent(
|
|||
|
||||
result = result.strip().strip(":").strip()
|
||||
|
||||
if "#" in result:
|
||||
result = result.split("#")[0]
|
||||
|
||||
character_names = [c.name for c in self.scene.get_characters()]
|
||||
|
||||
cleaned = []
|
||||
for line in result.split("\n"):
|
||||
|
||||
# skip lines that start with a #
|
||||
if line.startswith("#"):
|
||||
continue
|
||||
|
||||
log.debug("clean_result", line=line)
|
||||
|
||||
character_dialogue_detected = False
|
||||
|
|
Loading…
Add table
Reference in a new issue