Skip to content

GoVarnam implementation

Subin Siby requested to merge subins2000/indic-keyboard:govarnam into master

For Developers

To add Varnam support, install this app (code review needed). Once that app is installed, user can enable "Varnam - Malayalam" keyboard from "Languages". APKs below

  • IK & Varnam app communicate via Android Service API.
  • Varnam related files are stored under the support app. Location: Internal Storage/Android/data/org.smc.inputmethod.indic.varnam/files.
  • Initially only gonna support Malayalam. Need people to test other languages in GoVarnam before committing that to IK.

User Flow

  1. User installs Indic Keyboard, goes through getting started setup
  2. New step 4 in getting started: Enable Varnam ? Show what it is, an example. Completely optional. If yes, go to step 4, no go to step 5
  3. If user had enabled any Varnam scheme in "IK -> Languages" and on that keyboard launch, if varnam app (org.smc.inputmethod.indic.varnam) doesn't exist, go to step 4
  4. show Varnam Setup UI
  5. Nothing

Varnam Setup UI

  • Should be similar to Indic Keyboard getting started
  • Step 1: (Show Play Store, F-Droid button) Install Indic Keyboard Varnam Setup app
  • Step 2: Select varnam languages to enable (currently only Malayalam) -> Next
  • Step 3: Show progress bar. Initializing the selected languages using varnam.setupScheme(schemeID) & enable those keyboard layouts in Indic Keyboard (varnam-schemeID. Eg: varnam-ml)
  • Finished

The above steps are mentioned in enableVarnam() in InputLogic.java. It's better if this UX, UI things be handled by @jishnu7. I hope my explanation is clear enough :)

About GoVarnam

GoVarnam has core implementation changes from libvarnam notably:

  • Instead of saving all pattern -> word combination in a database, govarnam stores only the words
  • Every time user inputs something, all possible combinations of words are inferred from the input, searched in dictionary and result obtained.

Because of this change, storage requirement is very less for storing learnings (<20MB (govarnam) vs 100MB+ (libvarnam)).

APKs available here

Edited by Subin Siby

Merge request reports