kermitt2 / entity-fishing

A machine learning tool for fishing entities
http://nerd.readthedocs.io/
Apache License 2.0
249 stars 24 forks source link

Japanese language alpha 2 misconifgured #150

Closed ChielWH closed 2 years ago

ChielWH commented 2 years ago

Hi!

When trying to use Term look-up in Japanese, I get the following error:

Error encountered while requesting the server.
{ "message": "The language specified is not supported or not valid. " }

I think the source of this error is that jp is used for abbreviating Japanese in the supported languages for term look-up: https://github.com/kermitt2/entity-fishing/blob/c9abe1441429fb2037c324a72155b85b712e4336/src/main/resources/web/nerd/nerd.js#L7 While in the rest of the application it is abbreviated with ja (also on wikipedia itself). A test supporting this is to do a text disambiguation and fill in both the abbreviations in the lang field; providing ja yields expected results, providing jp yields the same error as shown above. I've tested this both on https://cloud.science-miner.com/nerd/ and on a local deployment, results are the same.

Besides this issue, props on this amazing project! We are getting great value from it!

kermitt2 commented 2 years ago

Hi @ChielWH !

Thank you very much for the issue and the explanations, and sorry for the misspelling in the front-end file.

This is corrected with ef92268a7b9d20f00877ec6bf65053ae16f7f59c

kermitt2 commented 2 years ago

Screenshot from 2022-08-25 06-18-56

ChielWH commented 2 years ago

Great! Thanks for the quick response.