Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Spell Check modules?

by coldfingertips (Pilgrim)
on Aug 02, 2003 at 14:59 UTC ( #280285=perlquestion: print w/replies, xml ) Need Help??

coldfingertips has asked for the wisdom of the Perl Monks concerning the following question:

Does anyone know of a fast and accurate (or any spell checker at all) spell checker where you can feed @words to and have it scan each word? I came across Net::Google::Spelling but that's only used for one or few words, not paragraphs at a time.

Thanks everyone

Replies are listed 'Best First'.
Re: Spell Check modules?
by Cine (Friar) on Aug 02, 2003 at 16:41 UTC

      Somebody's got to write a better search engine for CPAN...

Re: Spell Check modules?
by Anonymous Monk on Aug 02, 2003 at 15:09 UTC
Re: Spell Check modules?
by Anonymous Monk on Aug 02, 2003 at 15:14 UTC

    Here ya go:

    my %dictionary = (); open(DICTIONARY, "<your_dictionary") or die $!; while (<DICTIONARY>) { chomp; $dict{$_} = 1; } close(DICTIONARY); while (doc_to_check) { unless ($dict{$_}) { print "$_ is spelled incorrectly.\n"; } }

    The key is finding a good dictionary, and providing alternative spellings when a word isn't found.

Re: Spell Check modules?
by Anonymous Monk on Aug 02, 2003 at 15:07 UTC

    The closest thing I know of is GTK2::Spell.

    Due to the nature of the task, you're obviously going to need an external dictionary. I'd recommend you find one appropriate for your performance requirements and platform first, then writing a Perl wrapper should be straightforward, if it isn't already done.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://280285]
Approved by allolex
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (3)
As of 2022-09-30 15:23 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    I prefer my indexes to start at:




    Results (126 votes). Check out past polls.

    Notices?