From 027c3dd27d85794cc4d5fab7ccd23155448b4e24 Mon Sep 17 00:00:00 2001 From: oobabooga <112222186+oobabooga@users.noreply.github.com> Date: Sun, 15 Jan 2023 15:45:25 -0300 Subject: [PATCH] Allow jpg profile images --- README.md | 2 +- html_generator.py | 4 ++++ server.py | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 51eeb7f0..2b5f6d12 100644 --- a/README.md +++ b/README.md @@ -125,7 +125,7 @@ Optionally, you can use the following command-line flags: | `--model MODEL` | Name of the model to load by default. | | `--notebook` | Launch the webui in notebook mode, where the output is written to the same text box as the input. | | `--chat` | Launch the webui in chat mode.| -| `--cai-chat` | Launch the webui in chat mode with a style similar to Character.AI's. If the file profile.png exists in the same folder as server.py, this image will be used as the bot's profile picture.| +| `--cai-chat` | Launch the webui in chat mode with a style similar to Character.AI's. If the file profile.png or profile.jpg exists in the same folder as server.py, this image will be used as the bot's profile picture. | | `--cpu` | Use the CPU to generate text.| | `--auto-devices` | Automatically split the model across the available GPU(s) and CPU.| | `--load-in-8bit` | Load the model with 8-bit precision.| diff --git a/html_generator.py b/html_generator.py index 04224170..755276de 100644 --- a/html_generator.py +++ b/html_generator.py @@ -216,6 +216,10 @@ def generate_chat_html(history, name1, name2): output += f'