diff --git a/frontend/src/NewApp/Pages/GenerateCandidate.tsx b/frontend/src/NewApp/Pages/GenerateCandidate.tsx index 347c4b4..7b00907 100644 --- a/frontend/src/NewApp/Pages/GenerateCandidate.tsx +++ b/frontend/src/NewApp/Pages/GenerateCandidate.tsx @@ -123,7 +123,7 @@ const GenerateCandidate = (props: BackstoryElementProps) => { } else { setTimestamp(Date.now()) } - if (data.message) { + if (data.message !== '') { setStatus(data.message); } break; @@ -296,7 +296,7 @@ const GenerateCandidate = (props: BackstoryElementProps) => { } else { setTimestamp(Date.now()) } - if (data.message) { + if (data.message !== '') { setStatus(data.message); } break; @@ -366,24 +366,26 @@ const GenerateCandidate = (props: BackstoryElementProps) => { } - + - {processing && } - + sx={{ + width: 80, + height: 80, + border: '2px solid #e0e0e0', + }} + /> + {processing && } + + diff --git a/src/utils/agents/persona_generator.py b/src/utils/agents/persona_generator.py index f0b74c9..ab97583 100644 --- a/src/utils/agents/persona_generator.py +++ b/src/utils/agents/persona_generator.py @@ -218,6 +218,7 @@ class PersonaGenerator(Agent): self.username = persona.get("username", None) if not self.username: raise ValueError("LLM did not generate a username") + self.username = re.sub(r'\s+', '.', g) user_dir = os.path.join(defines.user_dir, persona["username"]) while os.path.exists(user_dir): match = re.match(r"^(.*?)(\d*)$", persona["username"])