Skip to content
ModelVerifiedExternal
Download

Gemma 3 1b Kbd Q4km

A fine-tuned Gemma 3 1B (INT4) for context-aware text prediction on Android, quantized to GGUF Q4KM for on-device inference via llama.cpp.

KindLoRABase modelgoogle/gemma-3-1b-ptVersionRevision 7226576Publisher@RitwikSehrawatCgrade

Model source

Kind
LoRA
File size
777 MB
Base model
google/gemma-3-1b-pt
Version
vRevision 7226576
Updated
Oct 4, 2026
Downloads
40
Parameters
1B
Source
Hugging Face

Source description

Gemma 3 1B — Context-Aware Keyboard (Q4_K_M GGUF)

A fine-tuned Gemma 3 1B (INT4) for context-aware text prediction on Android, quantized to GGUF Q4_K_M for on-device inference via llama.cpp.

Model Details

  • Base model: google/gemma-3-1b-pt
  • Fine-tuning: LoRA via Unsloth on a single RTX 3060
  • Quantization: Q4_K_M via llama.cpp convert_hf_to_gguf.py
  • Target device: Android (HeliBoard keyboard fork)

Training Data

~3B token conversational corpus from five sources with per-source cleaning, thread reconstruction, and synthetic typo augmentation:

  • Reddit conversations
  • OpenSubtitles
  • Enron email corpus
  • Hacker News comments
  • MS MARCO queries

Prompt Format

The model uses custom special tokens to condition predictions on app context:

<|app|>messaging<|ctx|>
[on-screen conversation history]
<|cursor|>
  • <|app|> — app category (messaging, email, search, social, etc.)
  • <|ctx|> — marks start of on-screen conversational context
  • <|cursor|> — marks the cursor position; model predicts the next tokens

Evaluation

MetricGemma (LLM)N-gram baseline
MRR (top-5)0.37720.0509
Hit@552.4%9.9%
Win rate92.2%4.5%

Evaluated on 1,865 examples.

Usage

Designed for integration with HeliBoard via llama.cpp's Android NDK build. Load the GGUF, feed the structured prompt, and use top-k token predictions as keyboard suggestions.

Limitations

  • English-only
  • Trained on informal/conversational text; may underperform on formal or technical writing
  • ~800MB model size requires download on first app launch

Sources

1 source
Hugging FacePrimaryVersion 7226576b4fced75993bf23594cd35c54f6c23ba0
huggingface.co/RitwikSehrawat/gemma-3-1b-kbd-q4km/tree/7226576b4fced75993bf23594cd35c54f6c23ba0

Verified Oct 4

Model artifacts

1 artifact

gemma-3-1b-kbd-q4km.gguf

gguf · 777 MB · SHA-256 22a8bb3794f5…2e4e · Hugging Face

Download file

Source excerpts

3 excerpts

--- license: apache-2.0 base_model: google/gemma-3-1b-pt tags: - gemma - keyboard - on-device - android - gguf - lora - unsloth language: - en --- # Gemma 3 1B — Context-Aware Keyboard (Q4_K_M GGUF) A fine-tuned Gemma 3 1B (INT4) for context-aware text prediction on Android, quantized to GGUF Q4_K_M for on-device inference via llama.cpp. ## Model Details - **Base model:** [google/gemma-3-1b-pt](https://huggingface.co/google/gemma-3-1b-pt) - **Fine-tuning:** LoRA via Unsloth on a single RTX 3060 - **Quantization:** Q4_K_M via llama.cpp `convert_hf_to_gguf.py` - **Target device:** Android (HeliBoard keyboard fork) ## Training Data ~3B token conversational corpus from five sources with per-source cleaning, thread reconstruction, and synthetic typo augmentation: - Reddit conversations - OpenSubtitles - Enron email corpus - Hacker News comments - MS MARCO queries ## Prompt Format The model uses custom special tokens to condition predictions on app context: ``` <|app|>messaging<|ctx|> [on-screen conversation history] <|cursor|> ``` - `<|app|>` — app category (messaging, email, search, social, etc.) - `<|ctx|>` — marks start of on-screen conversational context - `<|cursor|>` — marks the cursor position; model predicts the next tokens ## Evaluation | Metric | Gemma (LLM) | N-gram baseline | |--------|-------------|-----------------| | MRR (top-5) | 0.3772 | 0.0509 | | Hit@5 | 52.4% | 9.9% | | Win rate | 92.2% | 4.5% | Evaluated on 1,865 examples. ## Usage Designed for integration with [HeliBoard](https://github.com/Helium314/HeliBoard) via llama.cpp's Android NDK build. Load the GGUF, feed the structured prompt, and use top-k token predictions as keyboard suggestions. ## Limitations - English-only - Trained on informal/conversational text; may underperform on formal or technical writing - ~800MB model size requires download on first app launch

Source context: 40 downloads · 1 likes · Repo RitwikSehrawat/gemma-3-1b-kbd-q4km

Source context: 263 downloads · 0 likes · Repo RitwikSehrawat/gemma-3-1b-kbd-q4km