From be3c06a1587601ddb3658d3ad1079f735d8fd812 Mon Sep 17 00:00:00 2001 From: Linchen Xiao Date: Tue, 22 Oct 2024 14:35:45 +0800 Subject: [PATCH] [Fix] Update common summarizer regex extraction (#1631) --- opencompass/summarizers/subjective/common_summarizer.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/opencompass/summarizers/subjective/common_summarizer.py b/opencompass/summarizers/subjective/common_summarizer.py index 4793a91f1..7ba7341cd 100644 --- a/opencompass/summarizers/subjective/common_summarizer.py +++ b/opencompass/summarizers/subjective/common_summarizer.py @@ -28,7 +28,7 @@ def post_process_single_rate(judgement: str): xxx[[5]]xxx, and extract the score """ - pattern = r'Rating:\s*\[\[([\d.]+)\]\]' + pattern = r'\[\[([\d.]+)\]\]' matched_result = re.findall(pattern, judgement) if matched_result: score = float(matched_result[0])