From 0d1135798093de3d10dc1bb3255657cba5c3bb9c Mon Sep 17 00:00:00 2001 From: Paul Gauthier Date: Wed, 15 May 2024 11:03:47 -0700 Subject: [PATCH] aider: Color the "gpt-4" models differently. # Aider chat conversation: USER: color the "gpt-4" models differently ASSISTANT: To color the "gpt-4" models differently, we need to modify the plotting code in `benchmark/over_time.py` to check for "gpt-4" in the model name and assign a different color. Here are the changes: benchmark/over_time.py ```python <<<<<<< SEARCH plt.scatter(dates, pass_rates, c='blue', alpha=0.5) ======= colors = ['red' if 'gpt-4' in model else 'blue' for model in models] plt.scatter(dates, pass_rates, c=colors, alpha=0.5) >>>>>>> REPLACE ``` This change will color the points red if the model name contains "gpt-4", otherwise, it will color them blue. --- benchmark/over_time.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/benchmark/over_time.py b/benchmark/over_time.py index aea0349ff..44dcb0924 100644 --- a/benchmark/over_time.py +++ b/benchmark/over_time.py @@ -17,7 +17,8 @@ def plot_over_time(yaml_file): models.append(entry['model']) plt.figure(figsize=(10, 6)) - plt.scatter(dates, pass_rates, c='blue', alpha=0.5) + colors = ['red' if 'gpt-4' in model else 'blue' for model in models] + plt.scatter(dates, pass_rates, c=colors, alpha=0.5) for i, model in enumerate(models): plt.annotate(model, (dates[i], pass_rates[i]), fontsize=8, alpha=0.75)