Browse Source

Fix inline variable j

pull/298/head
Alexey Matveev 5 years ago
parent
commit
4be71c6603
1 changed files with 2 additions and 3 deletions
  1. 5
      app/api/utils.py

5
app/api/utils.py

@ -278,10 +278,9 @@ class CoNLLParser(FileParser):
words.append(word) words.append(word)
# Create JSONL
j = {'text': ' '.join(words), 'labels': labels}
# Create and add JSONL
data.append({'text': ' '.join(words), 'labels': labels})
data.append(j)
except conllu.parser.ParseException as e: except conllu.parser.ParseException as e:
raise FileParseException(line_num=-1, line=str(e)) raise FileParseException(line_num=-1, line=str(e))

Loading…
Cancel
Save