Prerequisites
Before you begin, ensure you have the following installed on your development machine:Android Studio
Latest stable version of Android Studio (recommended: Hedgehog or newer)
JDK 17
Java Development Kit 17 or higher is required for building the project
Android SDK
Android SDK API 29+ (Android 10) - installed via Android Studio SDK Manager
Git
Git for cloning the repository
The app targets API 35 (Android 15) and has a minimum SDK requirement of API 29 (Android 10).
Installation steps
Clone the repository
Clone the GemAI repository to your local machine:
Replace
yourusername with the actual repository owner’s username.Open in Android Studio
Launch Android Studio and open the cloned project:
- Click File > Open
- Navigate to the cloned
gemaidirectory - Click OK to open the project
Sync Gradle dependencies
Wait for Gradle to sync all dependencies. This may take a few minutes on the first build.The project uses the following key dependencies:
build.gradle.kts
Configure build variant
GemAI uses standard Android build configurations:
- compileSdk: 35
- minSdk: 29
- targetSdk: 35
- JVM Target: 17
app/build.gradle.kts:app/build.gradle.kts
Build the project
Build the project to ensure everything is configured correctly:Or use Android Studio:
- Click Build > Make Project or press
Ctrl+F9(Windows/Linux) /Cmd+F9(Mac)
Run on device or emulator
Connect an Android device via USB or create an Android Virtual Device (AVD):For physical device:
- Enable Developer Options on your Android device
- Enable USB Debugging
- Connect via USB and select your device in Android Studio
- Open AVD Manager in Android Studio
- Create a new virtual device with API 29 or higher
- Launch the emulator
Shift+F10.Build variants
GemAI currently supports two build types:| Build Type | Minify Enabled | ProGuard | Use Case |
|---|---|---|---|
| Debug | No | No | Development and testing |
| Release | No | Yes | Production builds |
Currently, minification is disabled for release builds. You can enable it by setting
isMinifyEnabled = true in app/build.gradle.kts.Troubleshooting
Gradle sync fails with 'Unsupported Java version'
Gradle sync fails with 'Unsupported Java version'
This error occurs when Android Studio is using a JDK version older than 17.Solution:
- Download and install JDK 17 or newer
- In Android Studio, go to File > Project Structure > SDK Location
- Set the JDK location to your JDK 17 installation
- Click Apply and sync Gradle again
Build fails with 'Cannot resolve symbol'
Build fails with 'Cannot resolve symbol'
This usually indicates incomplete dependency downloads or cache issues.Solution:
- Click File > Invalidate Caches
- Select Invalidate and Restart
- After restart, try File > Sync Project with Gradle Files
App crashes on startup
App crashes on startup
If the app builds successfully but crashes on launch, check the following:Solution:
- Ensure your device/emulator is running Android API 29 or higher
- Check Logcat in Android Studio for error messages
- Verify all dependencies synced correctly
- Try a clean rebuild: Build > Clean Project, then Build > Rebuild Project
KSP annotation processing errors
KSP annotation processing errors
GemAI uses KSP for Room, Hilt, and Compose Destinations code generation.Solution:
- Ensure KSP plugin version matches Kotlin version in
gradle/libs.versions.toml: - Clean and rebuild the project
Verify installation
Once the app launches successfully, you should see the API key setup screen. This confirms that:- All dependencies are properly installed
- The database is initialized correctly
- The app is ready for configuration

Next steps
Now that you have GemAI installed, proceed to the Quick Start guide to configure your Gemini AI API key and start chatting.Quick Start Guide
Learn how to get your API key and send your first message to Gemini AI