Debug AIDirectives validation

This commit is contained in:
Reinier van der Leer
2023-10-17 12:50:05 -07:00
parent 2660e5ec8c
commit 70f617ddd6
3 changed files with 3 additions and 3 deletions

View File

@@ -16,7 +16,7 @@ async def generate_agent_for_task(
app_config: "Config",
llm_provider: "ChatModelProvider",
) -> "Agent":
base_directives = AIDirectives.from_file(app_config.ai_settings_file)
base_directives = AIDirectives.from_file(app_config.prompt_settings_file)
ai_profile, task_directives = await generate_agent_profile_for_task(
task=task,
app_config=app_config,

View File

@@ -29,7 +29,7 @@ class AIDirectives(BaseModel):
if not validated:
logger.error(message, extra={"title": "FAILED FILE VALIDATION"})
request_user_double_check()
exit(1)
raise RuntimeError(f"File validation failed: {message}")
with open(prompt_settings_file, encoding="utf-8") as file:
config_params = yaml.load(file, Loader=yaml.FullLoader)

View File

@@ -7,4 +7,4 @@ if [ ! -f .env ]; then
echo "Please add your api keys to the .env file." >&2
# exit 1
fi
poetry run serve
poetry run serve --debug