Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Best way to incorporate spell checkers with a build process

I try to externalize all strings (and other constants) used in any application I write, for many reasons that are probably second-nature to most stack-overflowers, but one thing I would like to have is the ability to automate spell checking of any user-visible strings. This poses a couple problems:

  • Not all strings are user-visible, and it's non-trivial to spearate them, and keep that separation in place (but it is possible)
  • Most, if not all, string externalization methods I've used involve significant text that will not pass a spell checker such as aspell/ispell (eg: theStrName="some string." and comments)
  • Many spellcheckers (once again, aspell/ispell) don't handle many words out of the box (generally technical terms, proper nouns, or just 'new' terminology, like metadata).

How do you incorporate something like this into your build procedures/test suites? It is not feasible to have someone manually spell check all the strings in an application each time they are changed -- and there is no chance that they will all be spelled correctly the first time.

like image 889
rcreswick Avatar asked Sep 03 '08 20:09

rcreswick


People also ask

What is a spell checker in a word processing package How does it work?

The spell checker works by comparing every word typed with thousands of correctly spelled words and then uses algorithms to determine the correct spellings. If a word (e.g., a name) is spelled correctly, you can add it to the program's exceptions list so it's not flagged as misspelled.

How does spelling checker really helps you as a learner?

Recent studies show that spell-checkers help reduce students' surface errors in writing by flagging spelling errors and giving correct spelling suggestions. This study investigates if the error correction provided by the spell-checker tool in word processors are internalized by students.

How is spell check implemented?

Spell checkers can use approximate string matching algorithms such as Levenshtein distance to find correct spellings of misspelled words. An alternative type of spell checker uses solely statistical information, such as n-grams, to recognize errors instead of correctly-spelled words.


1 Answers

We do it manually, if errors aren't picked up during testing then they're picked up by the QA team, or during localization by the translators, or during localization QA. Then we lodge a bug.

Most of our developers are not native English speakers, so it's not an uncommon problem for us. The number that slip through the cracks is so small that this is a satisfactory solution for us.

Nothing over a few hundred lines is ever 100% bug-free (well... maybe the odd piece of embedded code), just think of spelling mistakes as bugs and don't waste too much time on it.

As soon as your application matures, over 90% of strings won't change between releases and it would be a reasonably trivial exercise to compare two versions of your resources, figure out what'ts new (check them first), what's changed/updated (check next) and what hasn't changed (no need to check these)

So think of it more like I need to check ALL of these manually the first time, and I'm only going to have to check 10% of them next time. Now ask yourself if you still really need to automate spell checking.

like image 123
saschabeaumont Avatar answered Nov 07 '22 07:11

saschabeaumont