samuelam commited on
Commit
e3c26ba
1 Parent(s): 11edb9f

Update evaluation/evaluator.py

Browse files
Files changed (1) hide show
  1. evaluation/evaluator.py +3 -4
evaluation/evaluator.py CHANGED
@@ -26,10 +26,9 @@ def fix_ans(answer):
26
  def parse_answer(answer):
27
 
28
  if len(answer) == 1:
29
- if answer[0].isnumeric():
30
- ans, is_num = fix_number(answer[0])
31
- if is_num:
32
- return ans, 'number'
33
  try:
34
  ans = json.loads(fix_ans(answer[0]))
35
  return [ans], 'json'
 
26
  def parse_answer(answer):
27
 
28
  if len(answer) == 1:
29
+ ans, is_num = fix_number(answer[0])
30
+ if is_num:
31
+ return ans, 'number'
 
32
  try:
33
  ans = json.loads(fix_ans(answer[0]))
34
  return [ans], 'json'