
Offers a multiplatform SDK for integrating Google's Gemini through Vertex AI, enabling text generation on Android and iOS. Suitable for prototyping, not production-ready.
Kotlin Multiplatform SDK to access Google’s Gemini via Vertex AI on Android and iOS
This SDK provides a simple and idiomatic way to integrate Google’s Gemini (powered by Vertex AI) into your Android and iOS applications using Kotlin Multiplatform.
2.1.10 or highergcloud auth print-access-token
Use the generated key in your application wherever the API_KEY is required.
// composeApp/build.gradle.kts
kotlin {
commonMain.dependencies {
implementation(libs.vertexgsoc)
}
}
// gradle/libs.versions.toml
[versions]
vertexgsoc = "1.0.0"
[libraries]
vertexgsoc = { group = "io.github.seanchinjunkai", name = "vertexgsoc", version.ref = "vertexgsoc" }val model = GenerativeModel(key = "API_KEY", model = "gemini-1.5-flash-002", RequestOptions(projectId = "gemini-kmp"))
val response: String? = result.response?.text Try these apps built with this SDK by the community:
| Feature | Currently Supported |
|---|---|
| Generate text (text-only input) | ✅ |
| Generate text (multimodal input) | ❌ |
| Generate structured output (JSON) | ❌ |
| Generate images | ❌ |
| Multi-turn chat | ❌ |
| Function calling (tools) | ❌ |
| Count tokens and billable characters | ❌ |
This library is currently in its initial development stages and is not intended for production use. The following reasons should be considered:
If you choose to use this library, it is highly recommended to do so for prototyping, experimentation, or non-critical applications only. For production-grade solutions, consider implementing or integrating rigorously tested alternatives or tools.
Kotlin Multiplatform SDK to access Google’s Gemini via Vertex AI on Android and iOS
This SDK provides a simple and idiomatic way to integrate Google’s Gemini (powered by Vertex AI) into your Android and iOS applications using Kotlin Multiplatform.
2.1.10 or highergcloud auth print-access-token
Use the generated key in your application wherever the API_KEY is required.
// composeApp/build.gradle.kts
kotlin {
commonMain.dependencies {
implementation(libs.vertexgsoc)
}
}
// gradle/libs.versions.toml
[versions]
vertexgsoc = "1.0.0"
[libraries]
vertexgsoc = { group = "io.github.seanchinjunkai", name = "vertexgsoc", version.ref = "vertexgsoc" }val model = GenerativeModel(key = "API_KEY", model = "gemini-1.5-flash-002", RequestOptions(projectId = "gemini-kmp"))
val response: String? = result.response?.text Try these apps built with this SDK by the community:
| Feature | Currently Supported |
|---|---|
| Generate text (text-only input) | ✅ |
| Generate text (multimodal input) | ❌ |
| Generate structured output (JSON) | ❌ |
| Generate images | ❌ |
| Multi-turn chat | ❌ |
| Function calling (tools) | ❌ |
| Count tokens and billable characters | ❌ |
This library is currently in its initial development stages and is not intended for production use. The following reasons should be considered:
If you choose to use this library, it is highly recommended to do so for prototyping, experimentation, or non-critical applications only. For production-grade solutions, consider implementing or integrating rigorously tested alternatives or tools.