All,
Predictive texting is technique to reduce the number of key presses used to enter text with SMS. I thought it might be an interesting challenge to see who could implement the best algorithm. Here are the rules:

One winner for each category below will be chosen:

All entries must support the same API to be considered. Digits will be passed in one at a time. The expected return value will be the best "suggestion" for the amount of information provided so far. If instead of a digit, a '+' is passed in, it means that the word is finished being spelled and the correct word has been returned. If instead of a digit, a '-' is passed in, it means that the word is finished being spelled but the "suggested" word is incorrect. Digits will resume following a '+'.

This is of course a silly competition with no real prizes for the winner. Feel free to break any or all rules and you are still likely to get accolades from your fellow competitors. Also, submissions long after the dead line are still encouraged. The reason for picking an arbitrary date is that at some point the secret text will need to be revealed allowing frequency analysis to optimize solutions for that text only.

Any clarifications will be identified below and time stamped.
Update (2007-01-10 11:13 EST): The 2of12.txt dictionary file can be found inside this zip.
Update (2007-01-10 11:25 EST): The keypad will be a standard ITU-T E.161
Update (2007-01-10 12:23 EST): A zero '0' will be used to indicate a space
Update (2007-01-11 08:35 EST): It is obvious that a space is not required to indicate separation of words (+ works fine)

Cheers - L~R


In reply to Challenge: Predictive Texting by Limbic~Region

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.