Closed LucasMagnum closed 6 days ago
To customise avatars is needed to use _ instead of - when naming the files otherwise they won't be find by server.
_
-
avatar_id = avatar_id.strip().lower().replace(" ", "_") avatar_path = os.path.join(APP_ROOT, "public", "avatars", f"{avatar_id}.*")
Example, if your application config name is My Assistant then the avatar should be public/avatars/my_assistant.png.
name
My Assistant
public/avatars/my_assistant.png
Server: https://github.com/Chainlit/chainlit/blob/add72385a2b8013e60718b65e2e82eb385a51773/backend/chainlit/server.py#L914
Thank you for your contribution! Just merged another PR which fixes this issue
To customise avatars is needed to use
_
instead of-
when naming the files otherwise they won't be find by server.Example, if your application config
name
isMy Assistant
then the avatar should bepublic/avatars/my_assistant.png
.Server: https://github.com/Chainlit/chainlit/blob/add72385a2b8013e60718b65e2e82eb385a51773/backend/chainlit/server.py#L914