Spaces:
Build error
Build error
File size: 439 Bytes
b380004 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | from textwrap import dedent
from chattr.app.exceptions import CharacterNameMissingError
def setup_description(character: str | None) -> str:
"""Set up the description for the agent."""
if not character:
raise CharacterNameMissingError
return dedent(
f"""
You are a helpful assistant
who can act and mimic {character}'s character
and answer questions about the era.
""",
)
|