Skip to content

Upgrade ThaiNER from PyThaiNLP 1.7 to PyThaiNLP 2.0

bact edited this page Apr 14, 2019 · 2 revisions

After upgrading from PyThaiNLP 1.7 to PyThaiNLP 2.0, you have to update ThaiNER model files.

If you use it with your own model, you have to retrain the model.

Updating ThaiNER model

>>> from pythainlp.corpus import download
>>> download("thainer")
Download : thainer
Alert: New version is ready to be updated.
from thainer 0.44 update to thainer 1.0
yes or no (y / n) : y

API change : https://thainlp.org/pythainlp/docs/2.0/notes/pythainlp-1_7-2_0.html#named-entity-recognition