Skip to content

Commit

Permalink
Merge pull request #1350 from NxPKG/patch-1
Browse files Browse the repository at this point in the history
Remove unused deployment_id variable.
  • Loading branch information
mrT23 authored Nov 8, 2024
2 parents e6a1f14 + 6339845 commit f9380c2
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions pr_agent/algo/ai_handlers/openai_ai_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ def deployment_id(self):
tries=OPENAI_RETRIES, delay=2, backoff=2, jitter=(1, 3))
async def chat_completion(self, model: str, system: str, user: str, temperature: float = 0.2):
try:
deployment_id = self.deployment_id
get_logger().info("System: ", system)
get_logger().info("User: ", user)
messages = [{"role": "system", "content": system}, {"role": "user", "content": user}]
Expand All @@ -65,4 +64,4 @@ async def chat_completion(self, model: str, system: str, user: str, temperature:
raise
except (Exception) as e:
get_logger().error("Unknown error during OpenAI inference: ", e)
raise
raise

0 comments on commit f9380c2

Please sign in to comment.