From 50b2070e76ccf4c78eeebd242250803f575af82f Mon Sep 17 00:00:00 2001 From: Jonathan Lucas Date: Tue, 20 Aug 2024 16:48:06 -0500 Subject: [PATCH] UTF encoding when reading system prompt --- base_telegram_inference_bot.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base_telegram_inference_bot.py b/base_telegram_inference_bot.py index 4844d9a..cc0d136 100644 --- a/base_telegram_inference_bot.py +++ b/base_telegram_inference_bot.py @@ -15,7 +15,7 @@ class BaseTelegramInferenceBot(ABC): @staticmethod def load_system_prompt(): - with open(os.environ.get("SYSTEM_PROMPT_PATH"), "r") as file: + with open(os.environ.get("SYSTEM_PROMPT_PATH"), "r", encoding="utf-8") as file: return file.read().strip() @staticmethod