diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java
index f6ba78674e3720dc83905fe65b1917a0200bbf2a..f806286d9cf63f0e39daa9c771e99d29b71db908 100644
--- a/java/src/com/android/inputmethod/latin/LatinIME.java
+++ b/java/src/com/android/inputmethod/latin/LatinIME.java
@@ -470,8 +470,7 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
         // Note that the calling sequence of onCreate() and onCurrentInputMethodSubtypeChanged()
         // is not guaranteed. It may even be called at the same time on a different thread.
         if (null == mPrefs) mPrefs = PreferenceManager.getDefaultSharedPreferences(this);
-        mUserHistoryDictionary = UserHistoryDictionary.getInstance(
-                this, localeStr, Suggest.DIC_USER_HISTORY, mPrefs);
+        mUserHistoryDictionary = UserHistoryDictionary.getInstance(this, localeStr, mPrefs);
         mSuggest.setUserHistoryDictionary(mUserHistoryDictionary);
     }
 
diff --git a/java/src/com/android/inputmethod/latin/Suggest.java b/java/src/com/android/inputmethod/latin/Suggest.java
index 8caa837ef64ffeebe468a70e2ae659646e746972..980d70324beed7b70d5535e6f40906cd4ad7866a 100644
--- a/java/src/com/android/inputmethod/latin/Suggest.java
+++ b/java/src/com/android/inputmethod/latin/Suggest.java
@@ -28,7 +28,6 @@ import java.io.File;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.Comparator;
-import java.util.HashMap;
 import java.util.HashSet;
 import java.util.Locale;
 import java.util.concurrent.ConcurrentHashMap;
@@ -47,16 +46,6 @@ public class Suggest {
     // TODO: rename this to CORRECTION_ON
     public static final int CORRECTION_FULL = 1;
 
-    // It seems the following values are only used for logging.
-    public static final int DIC_USER_TYPED = 0;
-    public static final int DIC_MAIN = 1;
-    public static final int DIC_USER = 2;
-    public static final int DIC_USER_HISTORY = 3;
-    public static final int DIC_CONTACTS = 4;
-    public static final int DIC_WHITELIST = 6;
-    // If you add a type of dictionary, increment DIC_TYPE_LAST_ID
-    // TODO: this value seems unused. Remove it?
-    public static final int DIC_TYPE_LAST_ID = 6;
     public static final String DICT_KEY_USER_TYPED = "user_typed";
     public static final String DICT_KEY_MAIN = "main";
     public static final String DICT_KEY_CONTACTS = "contacts";
@@ -65,17 +54,6 @@ public class Suggest {
     // User history dictionary internal to LatinIME
     public static final String DICT_KEY_USER_HISTORY = "history";
     public static final String DICT_KEY_WHITELIST ="whitelist";
-    // TODO: remove this map. This only serves as backward compatibility with a feature
-    // that has never been used and has been broken for a while.
-    private static final HashMap<String, Integer> sDictKeyToDictIndex
-            = new HashMap<String, Integer>();
-    static {
-        sDictKeyToDictIndex.put(DICT_KEY_MAIN, DIC_MAIN);
-        sDictKeyToDictIndex.put(DICT_KEY_USER, DIC_USER);
-        sDictKeyToDictIndex.put(DICT_KEY_USER_HISTORY, DIC_USER_HISTORY);
-        sDictKeyToDictIndex.put(DICT_KEY_CONTACTS, DIC_CONTACTS);
-        sDictKeyToDictIndex.put(DICT_KEY_WHITELIST, DIC_WHITELIST);
-    }
 
     private static final boolean DBG = LatinImeLogger.sDBG;
 
@@ -246,7 +224,6 @@ public class Suggest {
                     lowerPrevWord = null;
                 }
                 for (final String key : mDictionaries.keySet()) {
-                    final int dicTypeId = sDictKeyToDictIndex.get(key);
                     final Dictionary dictionary = mDictionaries.get(key);
                     final ArrayList<SuggestedWordInfo> localSuggestions =
                             dictionary.getBigrams(wordComposer, prevWordForBigram);
@@ -273,7 +250,6 @@ public class Suggest {
                 // Skip UserUnigramDictionary and WhitelistDictionary to lookup
                 if (key.equals(DICT_KEY_USER_HISTORY) || key.equals(DICT_KEY_WHITELIST))
                     continue;
-                final int dicTypeId = sDictKeyToDictIndex.get(key);
                 final Dictionary dictionary = mDictionaries.get(key);
                 final ArrayList<SuggestedWordInfo> localSuggestions = dictionary.getWords(
                         wordComposerForLookup, prevWordForBigram, proximityInfo);
diff --git a/java/src/com/android/inputmethod/latin/UserHistoryDictionary.java b/java/src/com/android/inputmethod/latin/UserHistoryDictionary.java
index d14006651846a5954e027118c80af8873c04ee73..52b197dca641ad6ca78085c4fd956fff0caa89a3 100644
--- a/java/src/com/android/inputmethod/latin/UserHistoryDictionary.java
+++ b/java/src/com/android/inputmethod/latin/UserHistoryDictionary.java
@@ -115,8 +115,7 @@ public class UserHistoryDictionary extends ExpandableDictionary {
     }
 
     public synchronized static UserHistoryDictionary getInstance(
-            final Context context, final String locale,
-            final int dictTypeId, final SharedPreferences sp) {
+            final Context context, final String locale, final SharedPreferences sp) {
         if (sLangDictCache.containsKey(locale)) {
             final SoftReference<UserHistoryDictionary> ref = sLangDictCache.get(locale);
             final UserHistoryDictionary dict = ref == null ? null : ref.get();