In the Android operating system, text input, dictionary validation, and real-time word suggestions rely on a modular framework managed by the Text Services Manager (TextServicesManagerService). Independent of the active Input Method Editor (IME) or soft keyboard, Android delegates spell checking, linguistic dictionaries, and suggestion lookups to registered spell checker services (such as Google Spell Checker or OEM vendor engines). When diagnosing keyboard input lag, text correction failures, language dictionary mismatch, or testing custom linguistic accessibility services, Android Debug Bridge (ADB) allows developers and QA engineers to query internal engine states using dumpsys textservices.
Architecture of Android Text Services and Spell Checking
The Android text services subsystem acts as an inter-process communication (IPC) intermediary between user-facing text fields (such as EditText or WebView inputs) and background linguistic validation services:
- TextServicesManagerService: The system server service that coordinates spell checker lifecycle events, user locale bindings, and active session tokens.
- SpellCheckerInfo: Manifest metadata provided by applications declaring the
android.service.textservice.SpellCheckerServiceintent filter. - SpellCheckerSession: Ephemeral client sessions created when an application requests spelling suggestions or grammar checks for given text tokens.
- Per-User Binding: Android maintains independent spell checker preferences, custom dictionaries, and active service bindings for each Android profile (such as Personal vs Work profile).
Dumping Text Services State via ADB
Ensure USB debugging is enabled on your Android handset, connect it to your workstation via USB or wireless ADB, and execute the following command in your terminal:
adb shell dumpsys textservices
The diagnostic dump outputs the complete operational state of the text services subsystem, structured into per-user runtime configurations, installed spell checker engines, and active IPC sessions.
Analysing Active Spell Checker Engines and User Preferences
In the diagnostic output, locate the user-specific state block (e.g. User 0:):
User 0:
mCurrentSpellCheckerId=com.google.android.inputmethod.latin/com.google.android.apps.inputmethod.latin.spelling.LatinSpellCheckerService
mSelectedSpellCheckerSubtype=0
mSpellCheckerBindInstant=true
mSpellCheckerSessionListenerMap size=1
Key attributes to inspect include:
- mCurrentSpellCheckerId: Identifies the exact component name currently handling spelling verification for the user.
- mSelectedSpellCheckerSubtype: Represents the active language and locale subtype index (such as English (UK), English (US), or multilingual models). A value of
0or-1indicates default system locale matching. - mSpellCheckerBindInstant: Indicates whether the system server binds immediately to the service process or defers binding until an active input session requests verification.
Listing Available Spell Checkers and Supported Subtypes
Android lists all installed packages that register spell checking capabilities along with their supported languages and internal subtypes:
adb shell dumpsys textservices | grep -E "mId=|mLocale="
For detailed inspection of a specific engine’s manifest declarations:
SpellCheckers:
com.google.android.inputmethod.latin/com.google.android.apps.inputmethod.latin.spelling.LatinSpellCheckerService:
mId=com.google.android.inputmethod.latin/com.google.android.apps.inputmethod.latin.spelling.LatinSpellCheckerService
mSettingsActivity=com.google.android.apps.inputmethod.latin.spelling.SpellingSettingsActivity
Subtypes:
Subtype #0:
mSubtypeName=English (US)
mSubtypeLocale=en_US
mSubtypeLanguageTag=en-US
Subtype #1:
mSubtypeName=English (UK)
mSubtypeLocale=en_GB
mSubtypeLanguageTag=en-GB
This verification confirms whether an application has declared appropriate locale subtags to support spelling correction across diverse regional language variations.
Inspecting Active Spell Checker Sessions and Client Bindings
When an application with an active text field interacts with the text services framework, dumpsys textservices reveals the active session listeners and connection states:
adb shell dumpsys textservices | grep -A 10 "mSpellCheckerSessionListenerMap"
Review the output to identify:
- PID and UID: The process ID of the client application holding an open spell check listener.
- Session State: Whether the connection is active, waiting for suggestion callbacks, or disconnected.
- Orphaned Listeners: Applications that fail to release their
SpellCheckerSessionwhen paused or destroyed will appear as persistent entries, pinpointing memory or IPC resource leaks.
Switching or Disabling Spell Checkers via ADB Settings
You can programmatically configure the active spell checker or toggle the spell checking subsystem directly from ADB using the settings utility.
To audit whether spell checking is enabled globally for the current user:
adb shell settings get secure spell_checker_enabled
To enable or disable the spell checker entirely:
# Disable spell checker
adb shell settings put secure spell_checker_enabled 0
# Enable spell checker
adb shell settings put secure spell_checker_enabled 1
To switch the active spell checker component directly from the command line:
adb shell settings put secure selected_spell_checker com.google.android.inputmethod.latin/com.google.android.apps.inputmethod.latin.spelling.LatinSpellCheckerService
Confirm the change immediately takes effect by re-running adb shell dumpsys textservices and inspecting mCurrentSpellCheckerId.
Troubleshooting Spell Check Latency and Suggestion Failures
If text fields freeze when entering characters or red suggestion squiggles fail to appear, perform a sequential diagnostic check:
- Verify Process Liveness: Check if the spell checker hosting process is alive using
adb shell pidof com.google.android.inputmethod.latin. If the process is absent or frequently crashing, check Logcat:adb logcat -d -s TextServicesManagerService:V SpellCheckerSession:V - Clear Spell Checker Cache: Corrupted personal dictionary databases or neural suggestion models can stall IPC responses. Clear application caches using:
adb shell pm clear com.google.android.inputmethod.latin - Validate Locale Match: Ensure that
mSelectedSpellCheckerSubtypematches the current device language setting underadb shell getprop persist.sys.locale.
Querying dumpsys textservices via ADB provides immediate transparency into Android’s linguistic services layer, ensuring responsive typing and reliable spelling assistance across mobile workflows.