Spaces:
Sleeping
Sleeping
Update pdf_generator.py
Browse files- pdf_generator.py +1 -1
pdf_generator.py
CHANGED
@@ -155,7 +155,7 @@ def process_quantitative_criteria(answer, styles):
|
|
155 |
|
156 |
def parse_quantitative_criteria(input_string):
|
157 |
# Match both "Name: value [min-max]" and "Name [min-max]" formats
|
158 |
-
match = re.match(r'(.+?)
|
159 |
if match:
|
160 |
name, value, min_val, max_val = match.groups()
|
161 |
name = name.strip()
|
|
|
155 |
|
156 |
def parse_quantitative_criteria(input_string):
|
157 |
# Match both "Name: value [min-max]" and "Name [min-max]" formats
|
158 |
+
match = re.match(r'(.+?)\s*:\s*([-+]?(?:\d*\.*\d+)(?:%)?)\s*\[([-+]?(?:\d*\.*\d+)(?:%)?)\s*-\s*([-+]?(?:\d*\.*\d+)(?:%)?)?\]', input_string)
|
159 |
if match:
|
160 |
name, value, min_val, max_val = match.groups()
|
161 |
name = name.strip()
|