Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
05-08-2002, 08:29 AM
|
#1
|
Member
Registered: Dec 2001
Location: Brisie, Australia
Distribution: Slackware 8.1
Posts: 324
Rep:
|
Developing a Spelling & Grammar Checker
I was wondering how I could develop a spelling and grammar checker.
Eg. what programing language would be most suitable for this, how does a grammar checker actually work properly (I've noticed sometimes it does), would I need have a HUGE list of words from a dictionary or is there an easier way, etc.
Thanks in advance
|
|
|
05-08-2002, 09:43 AM
|
#2
|
Senior Member
Registered: Dec 2001
Location: The Netherlands
Distribution: Ubuntu
Posts: 1,316
Rep:
|
I don't know about a grammer checker. But for a spelling checker I would look for either ispell or aspell at http://freshmeat.net
|
|
|
05-09-2002, 03:35 PM
|
#3
|
Member
Registered: Apr 2002
Location: Michigan
Distribution: Slackware 8.0
Posts: 197
Rep:
|
Well for a spell checker I think that you will need a database that conatins all the words you want, and have a facility to allow users to add words into this dictionary.
Then as the user types in words they are compared with words in the dictonary, and if there is a match then the work is correct, otherwise it will be a spelling mistake. Then it will prompt the user to correct it.
Also for a little more advanced functionality; assuming the word isn't in the dictionary, you can have the program compare the work with other words in the dictonary and have it list those words in the dictionary that most resemble the word that is wrong. That way you can give the user some suggestions to correct the word.
Then you can also add some automatic corrections, ex. a lot of people sometimes right "teh" instead of "the" so have the program automatically change it.
There are a lot of stuff you can do, but I think that this is the basic framework of a spell checker.
About the grammer thing I have no idea. Maybe have a list of nouns, verbs and so on each in a different dictionary, then make sure that they come in a specific order to make a correct sentence or so on. So you would check from a starting "." to an edning "." and that makes one sentence; so the program checks between those that there is a verb, noun, and so on in a specifc order to make a correct word.
|
|
|
05-26-2002, 05:23 PM
|
#4
|
LQ Newbie
Registered: May 2002
Posts: 1
Rep:
|
Did you manage to do it?
I'm curious if you were able to build the Java Grammar checker. Please let me know.
David Jones, djjones@ariasolutions.com
|
|
|
05-26-2002, 06:17 PM
|
#5
|
Member
Registered: Apr 2002
Location: D.C - USA
Distribution: slackware-current
Posts: 488
Rep:
|
Grammar checker, take an English (or whatever language you wanna use) class and listen attentivly to what is being said. Pay close attention to sentance diagrams; as you take in the information, think about how you could relate what is being said to a computer (via a HLL, hopefully ). I would choose perl if you just wanna run through a document and present output. Otherwise I'd use C++ and the STL. This would be my approach, at least. Hope that helps some .
|
|
|
All times are GMT -5. The time now is 01:37 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|