From 9e2628925bcfa6950e714febca4724fd5cc278c4 Mon Sep 17 00:00:00 2001 From: Nick Sullivan Date: Wed, 17 Jul 2024 14:44:33 +0200 Subject: [PATCH] Refactor prompt template initialization and update black dependency Refactor the initialization of the sidekick prompt template for better readability. Remove version pinning for the black dependency in requirements-dev.txt. --- aicodebot/prompts.py | 4 +++- requirements/requirements-dev.txt | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/aicodebot/prompts.py b/aicodebot/prompts.py index 6d83994..9bb495b 100644 --- a/aicodebot/prompts.py +++ b/aicodebot/prompts.py @@ -449,7 +449,9 @@ def get_prompt(command, structured_output=False): "commit": PromptTemplate(template=COMMIT_TEMPLATE, input_variables=["diff_context", "languages"]), "debug": PromptTemplate(template=DEBUG_TEMPLATE, input_variables=["command_output", "languages"]), "fun_fact": PromptTemplate(template=FUN_FACT_TEMPLATE, input_variables=["topic"]), - "sidekick": PromptTemplate(template=SIDEKICK_TEMPLATE, input_variables=["task", "context", "languages"]), + "sidekick": PromptTemplate( + template=SIDEKICK_TEMPLATE, input_variables=["task", "context", "languages"] + ), } try: diff --git a/requirements/requirements-dev.txt b/requirements/requirements-dev.txt index dbfcea6..87a8cf5 100644 --- a/requirements/requirements-dev.txt +++ b/requirements/requirements-dev.txt @@ -6,7 +6,7 @@ aicodebot # For committing, formatting, and dependency management -black==24.4.2 +black isort pip-tools pre-commit