maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   [ANNOUNCE] Auto-Complete Editor (https://talk.maemo.org/showthread.php?t=55884)

Rob1n 2010-06-25 09:30

Re: [ANNOUNCE] Auto-Complete Editor
 
Quote:

Originally Posted by Rob1n (Post 719522)
I'll have a look at this next week, once the current version's into -testing. It should be easy enough to add command-line options to auto-remove entries from a blacklist. Then an integrated blacklist editor would allow interaction with the blacklist similarly to with the dictionary.

I've just uploaded version 0.0.8 onto -devel. This includes a blacklist feature. You can set the delete mode to "Blacklist" to move words from the main dictionary to the blacklist, or you can use the blacklist editor (via the main app menu) to add/remove words from the blacklist. The blacklist is split by language, in the same way as the main dictionary. Entries are saved either when you exit the blacklist editor, or when you save the main dictionary. Finally, you can apply the blacklist from the command line (without launching the GUI) or via a script, by calling "/opt/AutoCompleteEditor/AutoCompleteEditor.pt --apply-blacklist".

Currently the blacklist does an exact match for entries (all entries are lower-cased anyway), but I may look at allowing regex-based entries in a future version.

Rob1n 2010-06-29 12:18

Re: [ANNOUNCE] Auto-Complete Editor
 
Quote:

Originally Posted by Rob1n (Post 723401)
As no-one's posted any new bugs over the weekend, I've now promoted 0.0.7 to extras-testing. Please give it a test and vote.

Thanks to those who've tested it. Unfortunately there are obviously still issues for several people (which indicates the parsing is still not correct), so I've flagged it for demotion again. Unfortunately none of those with issues have sent me example files, so unless I can manage to generate a failing case myself, there's no possibility of fixes either.

pelago 2010-06-29 12:44

Re: [ANNOUNCE] Auto-Complete Editor
 
Quote:

Originally Posted by Rob1n (Post 733951)
Unfortunately none of those with issues have sent me example files.

As long as it's disabled by default and clearly described, maybe you could implement a feature where dodgy dictionary files can be automatically uploaded for analysis? For some people, having to delve into the Terminal is just one step too hard.

Rob1n 2010-06-29 13:04

Re: [ANNOUNCE] Auto-Complete Editor
 
Quote:

Originally Posted by pelago (Post 733992)
As long as it's disabled by default and clearly described, maybe you could implement a feature where dodgy dictionary files can be automatically uploaded for analysis? For some people, having to delve into the Terminal is just one step too hard.

In all the cases so far, the issue has been (understandably) a concern about private data. I may revisit the error-handling code and think about what other alternatives I can offer the user though.

ndi 2010-06-29 16:06

Re: [ANNOUNCE] Auto-Complete Editor
 
A prompt should suffice?

Anyway, mine no longer works, but is there an option to start fresh? I mean, instead of delete all, simply rewite a known good, empty dictionary.

Mine crashes right now on startup. Most likey because I disabled completion. Not sure.

Rob1n 2010-06-29 18:29

Re: [ANNOUNCE] Auto-Complete Editor
 
Quote:

Originally Posted by ndi (Post 734267)
Anyway, mine no longer works, but is there an option to start fresh? I mean, instead of delete all, simply rewite a known good, empty dictionary.

Mine crashes right now on startup. Most likey because I disabled completion. Not sure.

Deleting the dictionary file (/home/user/.osso/dictionaries/.personal.dictionary) and killing hildon-input-method will force it to create a new file. Not sure how this will work if you don't have auto-complete enabled though - I'll have to do some tests with that.

I've actually managed to create a dictionary file which won't load now, which gives me something to work on. Unfortunately it looks to be using a totally non-standard encoding for the characters (0x9A and 0x9E is what I've currently got) - they don't fit in any ISO8859 character set, nor are they valid UTF-8.

ndi 2010-06-29 19:22

Re: [ANNOUNCE] Auto-Complete Editor
 
1 Attachment(s)
Well, I get that:

Rob1n 2010-06-29 19:29

Re: [ANNOUNCE] Auto-Complete Editor
 
Quote:

Originally Posted by ndi (Post 734495)
Well, I get that:

It works fine on mine with auto-complete disabled, and comes up with a missing file error if I've just deleted the dictionary file. Any chance you can upload the dictionary file (or email it to me - maemo at robinhill.me.uk)?

ndi 2010-06-29 19:43

Re: [ANNOUNCE] Auto-Complete Editor
 
Sent. Please note that the sent dictionary contains passwords. The e-mail message contains all the needed info.

Rob1n 2010-06-30 11:08

Re: [ANNOUNCE] Auto-Complete Editor
 
Quote:

Originally Posted by Rob1n (Post 734446)
I've actually managed to create a dictionary file which won't load now, which gives me something to work on. Unfortunately it looks to be using a totally non-standard encoding for the characters (0x9A and 0x9E is what I've currently got) - they don't fit in any ISO8859 character set, nor are they valid UTF-8.

Apparently, they're using CP1252. Ho-hum. Looks like I'm definitely going to need a static lookup for the encodings to use as they seem to be being plucked out of thin air :mad:

Oleg 2010-06-30 19:33

Re: [ANNOUNCE] Auto-Complete Editor
 
I've tested 0.0.8 and it work fine for me except that when I close the application in "blacklist mode" and reopen it I see "Delete selected" button where "Blacklist" normally is - after switching modes "Blacklist" button is back again.
Not a big deal but it may be confusing.

I heard cp1252 is what they use in Ukraine.

Oleg 2010-06-30 19:49

Re: [ANNOUNCE] Auto-Complete Editor
 
I wonder why I have ~40 English words in my Russian dictionary - could they get there if I switch layout too fast?

Also I noticed 2 words that I couldn't look up anywhere in my dictionaries but they show up in auto-complete in some applications (I've tried Notes and Email and I even rebooted). Shall you need my dictionary file just tell me and I'll send it too you with detailed description

Rob1n 2010-06-30 21:42

Re: [ANNOUNCE] Auto-Complete Editor
 
Quote:

Originally Posted by Oleg (Post 735982)
I've tested 0.0.8 and it work fine for me except that when I close the application in "blacklist mode" and reopen it I see "Delete selected" button where "Blacklist" normally is - after switching modes "Blacklist" button is back again.
Not a big deal but it may be confusing.

That's odd - I'll have a look into that one - it must be failing to either save or load the setting.

Quote:

Originally Posted by Oleg (Post 735982)
I heard cp1252 is what they use in Ukraine.

It's the standard Windows codepage for English (and possibly most of Western Europe) - or was, I think they've switched to unicode now (as every sensible system has).

Quote:

Originally Posted by Oleg (Post 736006)
I wonder why I have ~40 English words in my Russian dictionary - could they get there if I switch layout too fast?

The dictionary will store whatever words are written - switching the keyboard layout doesn't (I think) switch the dictionary used automatically. Certainly I can select to use any dictionary without changing the keyboard layout/system language.

Quote:

Originally Posted by Oleg (Post 736006)
Also I noticed 2 words that I couldn't look up anywhere in my dictionaries but they show up in auto-complete in some applications (I've tried Notes and Email and I even rebooted). Shall you need my dictionary file just tell me and I'll send it too you with detailed description

Are these definitely user-added words - they aren't coming from the system dictionary?

Oleg 2010-07-01 06:34

Re: [ANNOUNCE] Auto-Complete Editor
 
Quote:

Originally Posted by Rob1n (Post 736185)
It's the standard Windows codepage for English (and possibly most of Western Europe) - or was, I think they've switched to unicode now (as every sensible system has).

Oh, I see now.

Quote:

Originally Posted by Rob1n (Post 736185)
Are these definitely user-added words - they aren't coming from the system dictionary?

I'm sure they are mine, one of them is misspelled and the other is correct variant. I found both words in my '.used.dictionary' file. Any ideas?

Rob1n 2010-07-01 08:00

Re: [ANNOUNCE] Auto-Complete Editor
 
Quote:

Originally Posted by Oleg (Post 736654)
I'm sure they are mine, one of them is misspelled and the other is correct variant. I found both words in my '.used.dictionary' file. Any ideas?

I've pretty much ignored that file - it looked to only store information on the history of usage of system dictionary terms (so it can offer the most recently used ones first when auto-completing). I'll take another look, but it doesn't make a lot of sense to store the information in two separate files (though using random codepages to store the words doesn't make much sense either, so it's not as though Nokia were striving for common-sense solutions).

Rob1n 2010-07-01 12:55

Re: [ANNOUNCE] Auto-Complete Editor
 
I've just released version 0.0.9 :)

Changes are:
  • Fix label shown on Delete/Blacklist button
  • Handle dictionary files with truncated last entry
  • Allow override of codepage used for character encoding
  • Better error handling

Dictionaries with a truncated last entry (usually due to the hildon-input-method being killed while writing) will load with a warning, and the last (incomplete) entry will be dropped.

Failure to decode dictionary entries no longer causes the application to exit, instead it starts with no dictionary data loaded. You can then alter the character encoding (via the Settings menu) until you find one that will allow the file to load (see here for a description of what each encoding is likely to be used for). You can change the encoding at any point, but this will discard any unsaved changes, and saving the dictionary with an incorrect codepage is likely to cause issues with the auto-complete functionality.

EDIT:
Version 0.0.10 released as well. I just realised that the apply-blacklist functionality wouldn't work as it wasn't restarting hildon-input-method. I've moved the relevant bit of code so it's called whenever the dictionary is written.

Oleg 2010-07-02 12:07

Re: [ANNOUNCE] Auto-Complete Editor
 
Default encoding doesn't work for Russian language and there is no cp1251 in the list...

Rob1n 2010-07-02 12:25

Re: [ANNOUNCE] Auto-Complete Editor
 
Quote:

Originally Posted by Oleg (Post 738499)
Default encoding doesn't work for Russian language and there is no cp1251 in the list...

Aargh - sorry, I must have removed that override. I'll get a new version out ASAP (as soon as my home network connection starts working reliably anyway).

EDIT: New version (0.0.11) uploaded, so should be out soon. It re-adds the CP1251 default for Russian, and also adds the standard selection of Windows codepages to the selector.

Rob1n 2010-07-08 10:56

Re: [ANNOUNCE] Auto-Complete Editor
 
Version 0.0.12 has just been uploaded.

It's now using gconf to disable auto-completion before reading the dictionary, and re-enable it afterwards (it is was enabled in the first place). This forces the cached data to be flushed and makes sure any newly added words show up. This disable/enable process is also done when writing the dictionary, forcing the system to re-load the dictionary after it's been written (and preventing the need to kill hildon-input-method).

I've also found where the language names are defined, so I'm now reading them in from there instead of having them hardcoded. Unfortunately I've still not found anything mapping the language IDs used in the dictionary file to something useful, so there's still some hardcoded data.

ivgalvez 2010-07-08 14:14

Re: [ANNOUNCE] Auto-Complete Editor
 
AutoComplete Editor is working great.

Just a minor annoyance. After pressing the 'save' button, the icon that indicates that there is an operation in progress (an spinning star in the Hildon menu) never stop so the user can think that the save operation is hung.

ivgalvez 2010-07-08 14:20

Re: [ANNOUNCE] Auto-Complete Editor
 
Feature request:

It could be very useful if the 'Apply Blacklist' feature could be invoked via command line. This way, it would be easy to add a custom event to 'Alarmed' and apply everyday the blacklist filter.

I'd like to see this kind of feature as there are some abbreviations, and passwords that are almost daily appearing in my dictionary and I have to enter to AutoComplete Editor and apply manually the Blacklist.

Thank you and regards.

ivgalvez 2010-07-08 19:05

Re: [ANNOUNCE] Auto-Complete Editor
 
I didn´t noticed that you had released a new version today. Once updated I can finally see the popup and the spinner stops.

Great work!

Nozu 2010-07-12 15:43

AutoComp Edit truncated my dictionary? Please help.
 
I think some earlier version of AutoComp Edit truncated my dictionary. Now when I try to start AutoComp I get the following message:

"
Dictionary load error
Error reading dictionary
Dictionary truncated for Suomi (Suomi)
"

So now my Finnish (Suomi) dictionary is somehow broken. Does someone have an idea how to fix this? Is there some file for dictionaries? If so, where are they located and could somebody post the original file?


Thanks in advance!

Rob1n 2010-07-12 17:10

Re: AutoComp Edit truncated my dictionary? Please help.
 
The error indicates that it's found an inconsistency between the indicated overall size of the dictionary data, and the combined size of the individual entries. Does auto-complete still work? If so, it may be that the data isn't structured as I'm expecting (in which case, please could you send me a copy to maemo at robinhill.me.uk), otherwise it's probably a corrupted file (in which case, hitting "Save" in Auto-Complete Editor will write out a new file that it thinks is consistent).

Nozu 2010-07-12 19:11

Re: AutoComp Edit truncated my dictionary? Please help.
 
Thanks for your help! I thought it wasn't working because after starting the app it gave the meantioned error and had "done" button. After pressing "done" the app started but the screen view had no words in it. This time I tried scrolling down and noticed there were several empty rows in the beginning. Saving the dictionary solved the error problem as you said. Scandinavian letters shows funny though. They work elsewhere in maemo with autocomplete, so it's just in Autocomp Edit. And I guess it could be solved from settings by selecting the right character encoding. But how do I know which one? It's the default that's selected now. Now scandinavian letters like Ä shows up like À and Ö like ö (if they show to you as I mean.) =)

Sorry but I don't understand, you asked me to send you a copy, but a copy of what? And do you still need one? =)

Thanks for your help anyways! =)

EDIT:
Correction. I just found some words showing scandinavian letters just fine. So the question is... why most of the words have the letters incorrectly? And apparently these ones show up wrong everywhere in maemo.

Rob1n 2010-07-12 20:33

Re: AutoComp Edit truncated my dictionary? Please help.
 
Quote:

Originally Posted by Nozu (Post 749537)
Thanks for your help! I thought it wasn't working because after starting the app it gave the meantioned error and had "done" button. After pressing "done" the app started but the screen view had no words in it. This time I tried scrolling down and noticed there were several empty rows in the beginning.

Those must be the extra entries that took it past the expected size. You'd best delete those, otherwise they could cause issues elsewehere.

Quote:

Originally Posted by Nozu (Post 749537)
Saving the dictionary solved the error problem as you said. Scandinavian letters shows funny though. They work elsewhere in maemo with autocomplete, so it's just in Autocomp Edit. And I guess it could be solved from settings by selecting the right character encoding. But how do I know which one? It's the default that's selected now. Now scandinavian letters like Ä shows up like À and Ö like ö (if they show to you as I mean.) =)

They show up as two characters? That's very odd - it suggests perhaps UTF-8 would be appropriate, though you could also try CP1252. Anyway, there's no danger is changing the encoding, so just go through all of them and see whether any of them work.

Quote:

Originally Posted by Nozu (Post 749537)
Sorry but I don't understand, you asked me to send you a copy, but a copy of what? And do you still need one? =)

No, now you've saved a fixed copy, it'll have overwritten the old one. The dictionary file itself is at /home/user/.osso/dictionaries/.personal.dictionary

Quote:

Originally Posted by Nozu (Post 749537)
Correction. I just found some words showing scandinavian letters just fine. So the question is... why most of the words have the letters incorrectly? And apparently these ones show up wrong everywhere in maemo.

You're probably best deleting those then - they must have been saved with an incorrect encoding. Can you try re-adding them (just type them into Notes or something, just so they get added to the custom dictionary) and see whether they still show up incorrectly?

Nozu 2010-07-12 20:58

Re: AutoComp Edit truncated my dictionary? Please help.
 
Quote:

Originally Posted by Rob1n (Post 749603)

They show up as two characters? That's very odd - it suggests perhaps UTF-8 would be appropriate, though you could also try CP1252. Anyway, there's no danger is changing the encoding, so just go through all of them and see whether any of them work.

You're probably best deleting those then - they must have been saved with an incorrect encoding. Can you try re-adding them (just type them into Notes or something, just so they get added to the custom dictionary) and see whether they still show up incorrectly?

Didn't work with any of the encodings. I just ended up deleting the faulty ones. It adds everything ok when I retype the words in leafpad for example. Is there any way to reset the dictionary to factory default? Any other way than flashing the whole device I mean...

Rob1n 2010-07-13 07:13

Re: AutoComp Edit truncated my dictionary? Please help.
 
Quote:

Originally Posted by Nozu (Post 749615)
Didn't work with any of the encodings. I just ended up deleting the faulty ones. It adds everything ok when I retype the words in leafpad for example. Is there any way to reset the dictionary to factory default? Any other way than flashing the whole device I mean...

If newly added entries show okay, it must have been a problem with an older version of ACE, so it sounds as though the current version is using the correct (or at least a compatible) encoding.

The factory default is an empty dictionary (it only holds your custom entries - the global dictionary is never edited), so just hit the "Delete all" button in Auto-Complete Editor.

Switch_ 2010-07-13 07:39

Re: [ANNOUNCE] Auto-Complete Editor
 
Awesome app Rob1n, I went through and deleted a plethora of mis-pelt words bought about by sausage fingers hitting too many keys at once and deperately trying to keep up with conversations etc. Nice one, good call - thanks for the app :D

pelago 2010-07-13 16:00

Re: [ANNOUNCE] Auto-Complete Editor
 
Rob1n, have you thought about posting a licensing request on bugs.maemo.org asking them to open-source whatever component it is that handles the autocomplete dictionaries? I don't know how likely they will do that, but it's gotta be better than trying to reverse engineer things.

If they won't open-source the code, maybe they could at least document the file format. Or maybe there's an undocumented API for manipulating it that they could tell you about.

ivgalvez 2010-09-27 15:29

Re: [ANNOUNCE] Auto-Complete Editor
 
Hi there,

I've been using AutoComplete Editor during the last months without any issue. Combined with Alarmed to apply the blacklist daily works really well.

I've just one feature to request. A "Add to Blacklist" button, so I can add all the selected items to the blacklist with only one touch.

Thanks in advance Rob1n.

Rob1n 2010-09-27 20:56

Re: [ANNOUNCE] Auto-Complete Editor
 
Quote:

Originally Posted by ivgalvez (Post 827526)
Hi there,

I've been using AutoComplete Editor during the last months without any issue. Combined with Alarmed to apply the blacklist daily works really well.

I've just one feature to request. A "Add to Blacklist" button, so I can add all the selected items to the blacklist with only one touch.

Thanks in advance Rob1n.

You can change the delete mode to "Blacklist" to do this. I may have a look at reorganising the buttons to add a specific button for this though - the "Delete all" button should probably be in the menu instead, so that'll free up space for another button.

apvanloo 2010-10-28 06:04

Re: [ANNOUNCE] Auto-Complete Editor
 
I've been using autocomplete editor on a regular basis the last months.

After the 1.3 update the new dev. version won't start up, while the extras version cannot be installed anymore.

Am I the only one facing this issue?

jabba_29 2010-10-28 06:24

Re: [ANNOUNCE] Auto-Complete Editor
 
I haven't tried uninstall etc..
but just tried to open the app and it crashed for me too.

v_n900 2010-10-28 07:32

Re: [ANNOUNCE] Auto-Complete Editor
 
I did remove > reboot > reinstall, twice, no luck. :(
Now I'm waiting for an update of "Auto-Complete Editor".

Rob1n 2010-10-28 08:38

Re: [ANNOUNCE] Auto-Complete Editor
 
Quote:

Originally Posted by v_n900 (Post 854743)
I did remove > reboot > reinstall, twice, no luck. :(
Now I'm waiting for an update of "Auto-Complete Editor".

Auto-Complete Editor is just a python script, so there's no way it's dependent on the firmware version. It would appear that the underlying python libraries are though, so that's what'll need updating. These may not be updated by default, so you could try running (as root) "apt-get upgrade" and see whether it offers anything to upgrade. Unfortunately the PR1.3 update isn't available in the UK yet, so I can't actually test anything at the moment.

apvanloo 2010-10-28 18:14

Re: [ANNOUNCE] Auto-Complete Editor
 
yep the extra testing version needs python2.5-qt4-common (=4.7.4-maemo0).

I am too n00b to know how to correct this error.

The dev version is installable but just quits after about 5 seconds.

Rob1n 2010-10-28 21:18

Re: [ANNOUNCE] Auto-Complete Editor
 
The extras-testing version should have been removed - I'll have to chase up on how to do that. It's outdated and way less stable than the -devel version.

Rob1n 2010-11-01 14:48

Re: [ANNOUNCE] Auto-Complete Editor
 
Quote:

Originally Posted by Rob1n (Post 854834)
Auto-Complete Editor is just a python script, so there's no way it's dependent on the firmware version. It would appear that the underlying python libraries are though, so that's what'll need updating. These may not be updated by default, so you could try running (as root) "apt-get upgrade" and see whether it offers anything to upgrade. Unfortunately the PR1.3 update isn't available in the UK yet, so I can't actually test anything at the moment.

I've updated the scratchbox and have been able to test in there. I've found a solution, though I'm not convinced the real issue isn't in the PyQt4 libraries. Anyway, an updated version should be on its way into extras-devel now. I'll also push it to extras-testing, as there doesn't seem to be any other way to get rid of the broken version that's currently in there.

xxxxts 2010-11-29 18:29

Re: [ANNOUNCE] Auto-Complete Editor
 
I get this error before crashing (PR 1.3);

Traceback (most recent call last):
File "/opt/AutoCompleteEditor/AutoCompleteEditor.py", line 45, in _cmd_run_gui
w.loadData()
File "/opt/AutoCompleteEditor/ACE_gui.py", line 429, in loadData
langName = self._getLangName(langId)
AttributeError: 'NoneType' object has no attribute 'lower'

I really miss this - how do I get it working again???


All times are GMT. The time now is 08:18.

vBulletin® Version 3.8.8