Fix JSON in tokenizer

This commit is contained in:
Matthew Honnibal 2016-10-21 01:44:20 +02:00
parent 6eb73a095f
commit 8ce8803824

View File

@ -43,7 +43,7 @@ cdef class Tokenizer:
path = pathlib.Path(path)
if rules is None:
with (path / 'tokenizer' / 'specials.json').open() as file_:
with (path / 'tokenizer' / 'specials.json').open('r', encoding='utf8') as file_:
rules = json.load(file_)
if prefix_search in (None, True):
with (path / 'tokenizer' / 'prefix.txt').open() as file_: