Merge pull request #27 from InfernalDread/patch-1

Update agent.py to fix decode error
This commit is contained in:
Martin 2025-03-15 18:46:45 +01:00 committed by GitHub
commit 2d413dcd70
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -58,7 +58,7 @@ class Agent():
def load_prompt(self, file_path: str) -> str:
try:
with open(file_path, 'r') as f:
with open(file_path, 'r', encoding="utf-8") as f:
return f.read()
except FileNotFoundError:
raise FileNotFoundError(f"Prompt file not found at path: {file_path}")