spellcheck-using-dictionary-in-python icon indicating copy to clipboard operation
spellcheck-using-dictionary-in-python copied to clipboard

ImportError: cannot import name 'SpellCheck'

Open pallavi-xtage opened this issue 6 years ago • 11 comments

Hey,

An error is coming in importing. Can you please tell me how to install this package, so that this error wouldn't come.

pallavi-xtage avatar Feb 11 '19 09:02 pallavi-xtage

Try this..

from spellcheck import SpellCheck

satishp962 avatar Feb 11 '19 11:02 satishp962

Yeah I have tried this only before. The error is coming after using this statement mentioned by you for importing.

pallavi-xtage avatar Feb 11 '19 11:02 pallavi-xtage

How to install this package?Using pip?

pallavi-xtage avatar Feb 11 '19 11:02 pallavi-xtage

How to install this package?Using pip?

Sorry for the inconvenience. This library is yet not indexed on PIP. So you have to download and use the file. Please let me know if the problem persists.

satishp962 avatar Feb 11 '19 13:02 satishp962

Hey, Yeah I am using the program now as you said.But it returns me the list of suggested words and pick the first word from it which I don't want it to pick.Similarly for other texts as well.For example:- if someone types:--

text= "ell me something?" Then it outputs the result as:- ['hello', 'tell', 'well', 'me', 'something'] Returned output is--hello me something Expected output--tell me something

For this I can pick position 1 of list for this question but what about others.What if a user can ask any question having words presented in words.txt and it returns the same type as a list having different elements and the corrected element could be at any position in a list.But this code always pick first one.So what to do?

So what to do if a user asks different types of questions.

pallavi-xtage avatar Feb 12 '19 05:02 pallavi-xtage

Like for: text="what" suggestions----["what's", 'what'] output----what's

pallavi-xtage avatar Feb 12 '19 07:02 pallavi-xtage

Resolved.

Talk to you soon regarding some more errors. Thank you.

pallavi-xtage avatar Feb 12 '19 07:02 pallavi-xtage

Hey, Yeah I am using the program now as you said.But it returns me the list of suggested words and pick the first word from it which I don't want it to pick.Similarly for other texts as well.For example:- if someone types:--

text= "ell me something?" Then it outputs the result as:- ['hello', 'tell', 'well', 'me', 'something'] Returned output is--hello me something Expected output--tell me something

For this I can pick position 1 of list for this question but what about others.What if a user can ask any question having words presented in words.txt and it returns the same type as a list having different elements and the corrected element could be at any position in a list.But this code always pick first one.So what to do?

So what to do if a user asks different types of questions.

This issue is not resolved.

pallavi-xtage avatar Feb 12 '19 08:02 pallavi-xtage

Try changing the Fuzzywuzzy match percentage. Hope it helps.

satishp962 avatar Feb 13 '19 09:02 satishp962

Hey,

Sorted out after long work.

Thank you for your help.

pallavi-xtage avatar Feb 13 '19 09:02 pallavi-xtage

Great. Can you please create a pull request?

satishp962 avatar Feb 13 '19 09:02 satishp962