Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevention - Add an ingredients spell checker in the product edit form #937

Open
2 tasks
Tracked by #10272 ...
stephanegigandet opened this issue Nov 10, 2017 · 7 comments
Open
2 tasks
Tracked by #10272 ...
Labels
🧽 Data quality - Prevention 🧽 Data quality https://wiki.openfoodfacts.org/Quality 🥗 Ingredients 🎨 Mockup required Spellcheck Spellchecking ingredient list and product name to increase ingredient recognition.

Comments

@stephanegigandet
Copy link
Contributor

stephanegigandet commented Nov 10, 2017

What

Mockups

Backend documentation

Part of

@teolemon teolemon added 🥗 Ingredients 🧽 Data quality https://wiki.openfoodfacts.org/Quality labels Nov 10, 2017
@stephanegigandet
Copy link
Contributor Author

So, I'm looking at javascript spellcheck plugins. The one linked above is perfect, except it's not free and it's not open source.

Next best candidate I found is http://jquery-spellchecker.badsyntax.co/
It requires php pspell to be installed on the backend.

But it's old (5 years) and not maintained.

I found many other spell checking libraries / plugins for javascript, but they all seem very old and unmaintained.

Any suggestions?

@teolemon
Copy link
Member

Weird, I assume it was free at the time ?

@stephanegigandet
Copy link
Contributor Author

No, it's just that I'm used to "jquery something" libraries to be free and open source.

@teolemon
Copy link
Member

https://github.com/brandonaaron/jquery-spellcheck
Google seems to have a spellcheck API, but not suited to our needs for custom lists, I guess

@stephanegigandet
Copy link
Contributor Author

So, we could try to use the badsyntax javascript from http://jquery-spellchecker.badsyntax.co/html.html , and instead of using the php pspell backend, we create a perl backend that mimics the pspell api. I tried to capture the API call, the response seems simple enough, just a list of the mispellings and suggestions:

First call to get the mispellings:

{"outcome":"success","data":[["denounncing","Noo","consequencse's","caonsequences"]]}

2nd call to get the suggestions:

["denouncing","renouncing","announcing","trouncing","denounce","tenoning","demonizing","defencing","denounced","denounces"]

@teolemon teolemon added the Spellcheck Spellchecking ingredient list and product name to increase ingredient recognition. label Aug 12, 2018
@teolemon teolemon changed the title Add an ingredients spell checker in the product edit form Prevention - Add an ingredients spell checker in the product edit form Oct 11, 2021
@teolemon teolemon moved this to To discuss and validate in 🍊 Open Food Facts Server issues Apr 23, 2024
@teolemon
Copy link
Member

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🧽 Data quality - Prevention 🧽 Data quality https://wiki.openfoodfacts.org/Quality 🥗 Ingredients 🎨 Mockup required Spellcheck Spellchecking ingredient list and product name to increase ingredient recognition.
Projects
Status: To discuss and validate
Status: Todo
Status: To do
Development

No branches or pull requests

2 participants