Search code examples
javac++android-studiodictionaryandroid-source

Binary dictionary for LatinIME - how to build or where to find?


So far i have managed to build the LatinIME (AOSP) by following this git guide. I have build the libjni_latinime.so files using this git by changing all the references of the package name used in this project to my own package name and then moved them to my project src/main/jniLibs. And finaly the keyboard works! Now i would like to add dictionaries for more languages like greek and arabic in order to have predictive words. Allthough from what i understand the dictionaries used by latinIME need to be in binary format and so u have to build them using dicttool aosp. Is there any other method to build them other than building from aosp tree or are there any link to download prebuild .dict files for greek and arabic? I dont have enough space ( and really bad connection, would need ages) to download the whole aosp tree as the Requirements specified tell u need 100 gb for checkout the git and extra 150 gb to build it .

I have read:

LatinIME dicttool for use with a V401 Binary Dictionary

Android LatinIME Dictionaries

softkeyboard - BinaryDictionaries.wiki

and the majority of questions on the matter, but i didnt manage to find any detailed answer, as i'm really new to building on latinIME.

The dictionaries from latinIME can be found here and i think those are the ones u have to build using the dicttool. Any help on building the dictionaries for greek and arabic language is appreciated, thank you very much.

EDIT 1: i managed to include greek dictionary and auto correction for greek using main_el.dict from this project. It includes all the prebuilt dict files from aosp dictionaries. Now could anyone help me with prebuilt (binary) arabic dictionary?


Solution

  • Its been a while but managed to find the answer to add more dictionaries for the last version of the LatinIME.

    in this github folder one can find dicttool_aosp.jar file. now in order to create the dict you need an combined wordlist. Many languages are provided by latinIME official repository here After you download and uncompress the gz files you can run java -jar dicttool_aosp.jar makedict -s your_wordlist.combined -d main_your.dict

    If someone want to create a dict for an language not included in these files, can download an archive dump of wikipedia for this language and with the tools found here he can create a wordlist and continue with the steps above.

    Edit: fixed the link