From 291b456a45b848479098a79b90c901c68d2b986d Mon Sep 17 00:00:00 2001 From: Paul Gauthier Date: Thu, 12 Sep 2024 13:05:25 -0700 Subject: [PATCH] hack for o1-mini: no system prompt, no temperature --- aider/coders/base_coder.py | 3 ++- aider/sendchat.py | 2 +- benchmark/benchmark.py | 3 ++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/aider/coders/base_coder.py b/aider/coders/base_coder.py index 1cb6b6395..823b418a0 100755 --- a/aider/coders/base_coder.py +++ b/aider/coders/base_coder.py @@ -967,7 +967,8 @@ class Coder: chunks = ChatChunks() chunks.system = [ - dict(role="system", content=main_sys), + dict(role="user", content=main_sys), + dict(role="assistant", content="Ok."), ] chunks.examples = example_messages diff --git a/aider/sendchat.py b/aider/sendchat.py index 7301a602a..af3d126e0 100644 --- a/aider/sendchat.py +++ b/aider/sendchat.py @@ -60,7 +60,7 @@ def send_completion( kwargs = dict( model=model_name, messages=messages, - temperature=temperature, + # temperature=temperature, stream=stream, ) diff --git a/benchmark/benchmark.py b/benchmark/benchmark.py index 3d559b9be..2b459a1f7 100755 --- a/benchmark/benchmark.py +++ b/benchmark/benchmark.py @@ -549,7 +549,8 @@ def run_test_real( chat_history_file=history_fname, ) - main_model = models.Model(model_name) + weak_model = "gpt-4o-mini" + main_model = models.Model(model_name, weak_model) edit_format = edit_format or main_model.edit_format dump(main_model)