Instructions to use 2796gauravc/kosha-functiongemma-phase0-tflite with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- LiteRT
How to use 2796gauravc/kosha-functiongemma-phase0-tflite with LiteRT:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- Notebooks
- Google Colab
- Kaggle
| language: [en, hi] | |
| license: gemma | |
| tags: | |
| - function-calling | |
| - gemma | |
| - kosha | |
| - android | |
| - on-device | |
| - litert | |
| - mediapipe | |
| - finance | |
| base_model: 2796gauravc/kosha-functiongemma-phase0 | |
| # KOSHA Phase 0 — Android .task File | |
| **KOSHA (कोश)** — Private on-device Indian finance tracker. | |
| This is the **MediaPipe-ready `.task` file** for Android LiteRT deployment. | |
| The fine-tuned merged model is at [2796gauravc/kosha-functiongemma-phase0](https://huggingface.co/2796gauravc/kosha-functiongemma-phase0). | |
| ## File Info | |
| | Property | Value | | |
| |---|---| | |
| | Base model | FunctionGemma 270M | | |
| | Quantization | dynamic_int8 | | |
| | KV cache max len | 1024 | | |
| | Size | ~290 MB | | |
| | Format | MediaPipe `.task` (LiteRT) | | |
| ## Functions | |
| - `log_expense` — Indian bills, UPI, groceries, fuel, dining | |
| - `log_income` — Salary, freelance, UPI received | |
| - `no_expense` — OTP, promotions, non-financial messages | |
| ## Android Integration | |
| ```kotlin | |
| // build.gradle.kts | |
| implementation("com.google.mediapipe:tasks-genai:0.10.22") | |
| // Usage | |
| val options = LlmInference.LlmInferenceOptions.builder() | |
| .setModelPath("/data/local/tmp/kosha_phase0_q8_ekv1024.task") | |
| .setMaxTokens(1024) | |
| .setTopK(64) | |
| .setTopP(0.95f) | |
| .setTemperature(0.1f) // Low temp for deterministic function calls | |
| .setPreferredBackend(LlmInference.Backend.CPU) // CPU recommended for Gemma 270M | |
| .build() | |
| val llm = LlmInference.createFromOptions(context, options) | |
| val result = llm.generateResponse(yourFunctionGemmaPrompt) | |
| // Parse: <start_function_call>call:log_expense{...}<end_function_call> | |
| ``` | |