[Kbabel] KBabel after 1.0 (Roadmap)

Stanislav Visnovsky visnovsky@nenya.ms.mff.cuni.cz
Tue, 12 Nov 2002 19:40:35 +0100 (CET)


On Tue, 12 Nov 2002, Andrea Rizzi wrote:

> There many ways to guess the right translation from older one.
> 
> Examples:
> we can guess the translation of a single word looking at the correlation
> between a english word and the translated word. This is quite easy using 
> the word indexes and upgrading the correlation every time we add an entry to 
> the database.
> This will improve a lot the consistency of the translation and allow us to put 
> warnings if a word is translated in an unconsistent way.
> 
> Another example is:
> suppose you have msgstrs
> "Change to desktop one"
> "Change to desktop two"
> It is quite easy to guess the translation of the second if you have the 
> translation of the first...
> The idea is to implement an algorithm that try to substitute one word:
> -Find a sentence where n-1 words match (i.e. I know there is "Change", "to", 
> "desktop").
> -Search a translation for the unmatching words (i.e. "one" and "two" )
> -Search the translation of "one" in the translated full string
> -Substitute that translation with the translation of "two"

Hmmm, this would work only for some languages, for example Slovak would 
not like this kind of partial translations.

> 
> If we have the "correlation glossary" we can easly propose consistent 
> translation for a lot of sentences.
> 
> Another example of very important new stuff is a "tokenizer" that search for
> partial msgstr:
> "Failed! Try again?"
> search for "Failed!" and then for "Try again?"
> This will be very useful for long sentences like kcm-on-line-help.
> 
> Finally we should write a "restyler" i.e. something that adds all the 
> necessary stuff like "...", capital letters(we should write some rules for 
> different languages), &, :
> Example
> "&Name" -> "&Nome"
> "Name:" --search--> "&Nome" --restyler--> "Nome:"

I'm currently working on KDataTool-based validation. The checks
will not be hard-wired in KBabel, but will be loaded on demand. So, it 
will be easy to add another check. 
One of my goals is to allow "fixing" if possible. And the "restyler" seems 
like a something to be used, for example to stop msgfmt complaining about 
missing "\n".

> 
> The actual interface (API) of kbabeldict do not allow all this nice stuff, so 
> I think after 1.0 is a good moment to modify that interface.

Yes, but should we extend KBabelDict API? Is this related to dictionaries 
only? I don't think so, at least for the "restyler" stuff.

So, how should we proceed with implementing this?

Stanislav