From b5c7a7a0e1dcc12d4c4dd66a52dc965beb4b0934 Mon Sep 17 00:00:00 2001 From: Jialiang Xu Date: Fri, 13 Dec 2024 15:25:23 -0800 Subject: [PATCH] formatting --- src/helm/benchmark/run_specs/lite_run_specs.py | 6 +++--- src/helm/benchmark/scenarios/wildbench_scenario.py | 9 +++++---- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/src/helm/benchmark/run_specs/lite_run_specs.py b/src/helm/benchmark/run_specs/lite_run_specs.py index f9dafe34cb..6dc83be0f6 100644 --- a/src/helm/benchmark/run_specs/lite_run_specs.py +++ b/src/helm/benchmark/run_specs/lite_run_specs.py @@ -457,11 +457,11 @@ def get_ifeval_spec() -> RunSpec: def get_wildbench_spec(subset: str, use_model_outputs: str = "False") -> RunSpec: scenario_spec = ScenarioSpec( - class_name = "helm.benchmark.scenarios.wildbench_scenario.WildBenchScenario", - args = { + class_name="helm.benchmark.scenarios.wildbench_scenario.WildBenchScenario", + args={ "subset": subset, "use_model_outputs": use_model_outputs == "True", - } + }, ) adapter_spec = AdapterSpec( diff --git a/src/helm/benchmark/scenarios/wildbench_scenario.py b/src/helm/benchmark/scenarios/wildbench_scenario.py index 061d6169aa..100efa9661 100644 --- a/src/helm/benchmark/scenarios/wildbench_scenario.py +++ b/src/helm/benchmark/scenarios/wildbench_scenario.py @@ -71,7 +71,10 @@ def get_instances(self, output_path: str) -> List[Instance]: checklist = [f"- {checklist_item}" for checklist_item in row["checklist"]] input = Input( - text = history_text + "\n\n" + "USER: " + user_query_text, # For frontend display only, not used for evaluation + text=history_text + + "\n\n" + + "USER: " + + user_query_text, # For frontend display only, not used for evaluation ) instance = Instance( input=input, @@ -80,9 +83,7 @@ def get_instances(self, output_path: str) -> List[Instance]: extra_data={ "conversation": conversation, "baseline_outputs": { - model: baseline_outputs[model][idx]["output"][0] - if self.use_model_outputs - else None + model: baseline_outputs[model][idx]["output"][0] if self.use_model_outputs else None for model in REFERENCE_MODELS }, "history": history_text,