Page 3 of 9 FirstFirst 12345678 ... LastLast
Results 41 to 60 of 161
  1. wprater's Avatar
    Posts
    240 Posts
    Global Posts
    251 Global Posts
    #41  
    This is great to have, thanks for putting this together.. now we just need a spell check. Place finger on gesture then hit word (underlined in red) for suggestions!!
  2.    #42  
    Pre->ore was one of the first things I fixed. Try this list instead: drop.io dimfeld

    Yeah, a real spell check would be pretty cool. Much more difficult to implement, but pretty cool
  3. wprater's Avatar
    Posts
    240 Posts
    Global Posts
    251 Global Posts
    #43  
    Palm should also come up with a better way to store and search these auto replacements.. a binary format vs. plain text ?
  4.    #44  
    I assume that the Pre reads the file at boot-time and stores the results in a binary structure like a trie that's better for these sorts of things. At least, I hope that's what they're doing.
  5. wprater's Avatar
    Posts
    240 Posts
    Global Posts
    251 Global Posts
    #45  
    Quote Originally Posted by dimfeld View Post
    I assume that the Pre reads the file at boot-time and stores the results in a binary structure like a trie that's better for these sorts of things. At least, I hope that's what they're doing.
    If it were in memory, it should not slow down app loading times? Maybe they need to break into many smaller trees..
  6.    #46  
    It's really only Webkit loading in email and the browser that was slowed down. Other apps that use text replacement like messaging, memos, etc. seem to perform the same regardless of the file size, at least in my experience.

    I assume they have to do some special loading on the autocorrect stuff for it to work with Webkit that makes it load slower when the file is larger, but I don't know enough about it to really say more than that. With the default 46KB file, the speed probably simply wasn't an issue, but if Palm implements a better autocorrect themselves then I assume they'll switch to a more efficient format, or even revamp the system completely.
  7. as4life's Avatar
    Posts
    577 Posts
    Global Posts
    733 Global Posts
    #47  
    i know this is a dumb question but i'm going to ask anyways. How do u get this on the phone?
  8.    #48  
    If you haven't already, first you need to root your Pre using the directions at pre dev wiki: Enable Root Access

    After that, you should have access to the filesystem, so you just copy one of the autoreplace files from the ZIP file that I uploaded over to your Pre and replace the existing one with that. You can either do that via SCP, or by plugging your Pre into your computer, copying the replacement file to your Pre over the USB connection, and then logging in over SSH and copying it via something like this:
    cp /media/internal/text-edit-autoreplace /etc/palm/autoreplace/en_us/text-edit-autoreplace
  9. #49  
    This is pretty awesome so far. The extra few seconds to load the file is barely noticeable for me if at all.
    Whenever the sdk gets released, hopefully we'll see an app to customize the auto-replace like this. I have about 5+ years worth of irc, aim, and msn logs that I could try getting the most used words out of and generating a list from this. If I do that, I'll post it here in case anyone's interested.
  10. wprater's Avatar
    Posts
    240 Posts
    Global Posts
    251 Global Posts
    #50  
    Im getting lots of pipes in my auto-corrections. Anyone else experiencing this?
  11.    #51  
    Hmm, I haven't noticed that. Are there any particular words that are causing that for you? Are you using one of the files I generated or did you run the script to generate your own autoreplace file?

    If you want to upload your autoreplace file and/or the word lists you used to generate them to drop.io dimfeld, I'll be glad to take a look at it. Might not get to it this weekend but I should be able to early next week.
  12. jngai's Avatar
    Posts
    46 Posts
    Global Posts
    69 Global Posts
    #52  
    I'm getting the same thing. I think what's happening is the script is writing both autocorrection of the same word on to one line. Look at the 2 examples from the autoreplace file I created below:

    ,ag|maf|,ag|mag
    ,ag|mah|,ag|mag

    The mistype is ",ag", but the correction now is "maf|,ag|mag" because 2 autocorrections are written onto one line.

    Maybe I'm running the script incorrectly, but this is what I'm running on command prompt:

    python generate_autoreplace.py text-edit-autoreplace.bak text-edit-autoreplace-combined extra_words.txt text-edit-autoreplace

    I remember an earlier version of the script didn't do this. I think only the newer version that can read multiple input files has this issue.

    I actually didn't come across these issues on my day to day use. Its only when I wanted to add words because my problem is typing one letter faster than the other, the best example is "chciken" instead of "chicken". Also, my "ny" turns into "by", kinda sucks for some one that lives in ny. But I'm glad I can just go into the file and correct those.
  13.    #53  
    Thanks for the added input. It looks like your problem is that you're giving it an autoreplace file for the word list, instead of just a normal word list, so the script is reading in each entry in the autoreplace file and then generating autoreplace entries for each one. I provided the text-edit-autoreplace-* files for convenience and for those who don't have Python installed, but they are the output for the script and shouldn't be used as input to it.

    Instead of text-edit-autoreplace-combined for the second file argument, you should use one of these:
    bnc15knum.txt
    googwords.txt
    combinedwords.txt
    Or whatever other word list you prefer.

    So the command line you would want to generate your autoreplace file based on the combined word list is:
    python generate_autoreplace.py text-edit-autoreplace.bak combinedwords.txt extra_words.txt text-edit-autoreplace

    Hope that fixes your problem. Let me know if you have any other questions
  14. jngai's Avatar
    Posts
    46 Posts
    Global Posts
    69 Global Posts
    #54  
    Yup. That fixed it. Thanks.
  15. diomark's Avatar
    Posts
    752 Posts
    Global Posts
    770 Global Posts
    #55  
    haven't tried this yet, but awesome great job on this...
  16. #56  
    Diomark,

    I was looking at your code and figured I'd try to play with it a little bit if that was okay with you, but I wanted to do was create an optional input before the output that if a person entered a # that would be the max word length but if they didnt or they put in an invalid thing like a character it would default the value stored in the file. My question is do you know of any simple checking routines to make sure the input is a int?

    I tried to send this a private message but it wouldnt let me...

    Thanks
  17.    #57  
    I assume you meant me and not diomark

    Yeah, feel free to do whatever you want with the script. You can use Python's int() function to both check that an input is an integer and do the conversion at the same time. For example, once you have the argument in string form:

    Code:
    try:
        max_length = int(argument_string)
    except ValueError:
        max_length = MAX_WORD_LENGTH
    If the argument is not an integer, then the ValueError exception is raised, and the handler sets the max word length to the constant MAX_WORD_LENGTH
  18. #58  
    I did Dimfeld, I'm sorry abou that the d threw me off.

    I am playing with the code and if i get it to work during my free time i'll post it.

    one other question do the words have to be in alphabetical order or is that just to make it easier does any one know?

    And is there an easier way to add one work rather then create a file to mix in with the existing one that contains one word? Maybe a simple command line program :

    ADDWORD origfile SINGLEWORD WORDTOREPLACE
  19.    #59  
    The words in the word lists don't have to be in alphabetical order, since my script will sort the output before writing it to the file.

    The words in the Pre's default autoreplace file are in alphabetical order, so the script outputs its file also in alphabetical order. I suspect that the words in the autoreplace file don't have to be sorted, but I haven't actually tried it. It would be easy enough to test by adding your own entry to the end of the autoreplace file and trying out the added correction.

    It shouldn't be too hard to modify the script to just add corrections for a single word to an autoreplace list. The resulting script would take arguments something like this:
    python addword.py origfile singleword outputfile

    Here origfile is your existing modified autoreplace file instead of the Pre's default file. Then take out all the logic for reading in word lists and instead just call generate_corrections, or whatever that function is called, with the singleword argument.

    If, instead, you just want to add a single correction, then you need two command-line arguments, and you just add this pair of arguments to the corrections list after the original autoreplace file is read and before the script sorts and writes the output.
  20. diomark's Avatar
    Posts
    752 Posts
    Global Posts
    770 Global Posts
    #60  
    I'm getting alot of pipes in the replacements.. i.e. everytime a word is replaced, it puts a pipe there before it.

    I think this is because I'm running the script from linux.. and it's adding an extra ^M

    i.e.
    bext^M|next^M


    -mark
Page 3 of 9 FirstFirst 12345678 ... LastLast

Tags for this Thread

Posting Permissions