Kofu 4.0 Edge (Gemma 4 E4B Q4_K_M)

Kofu 4.0 Edge is an on-device language model fine-tuned from Google's cutting-edge Gemma 4 E4B-it (google/gemma-4-E4B-it) specifically optimized for real-time mobile execution in the Kofu Mobile Assistant via llama.cpp and Android NDK.

  • Base Architecture: Gemma 4 (E4B multimodal architecture with 42 text transformer layers, 2560 hidden size, 262,144 token vocabulary).
  • Quantization: Q4_K_M (4-bit medium k-quant) utilizing high-precision fp16 scales.
  • Model File: kofu-gemma4-edge-q4_k_m.gguf
  • Effective Size: ~3.2 GB
  • Primary Languages: Spanish (es), English (en)
  • Format: GGUF (v3)

🎯 Fine-Tuning Specialization

Kofu 4.0 Edge is fine-tuned using parameter-efficient Low-Rank Adaptation (LoRA) on curated, high-quality instruction datasets covering:

  1. Mathematical Reasoning & Logic: Step-by-step problem solving in Spanish (Yahir/alpaca-logica-programacion).
  2. Software Engineering & Multi-Language Coding: C++, Kotlin, Python, algorithms, and system programming (sahil2801/CodeAlpaca-20k).
  3. General Knowledge & Conversational Assistant: Polished Spanish instruction following (plncmm/spanish-alpaca).
  4. Defensive Cybersecurity & Safe Systems: Secure coding patterns and threat analysis (murdok1982/gemma4-programacion-seguridad).

πŸ’¬ Prompt Template

Kofu 4.0 Edge uses the official Gemma 4 turn formatting structure:

<|turn>user
{user_prompt}<turn|>
<|turn>model
{model_response}<turn|>

Generation prompt format:

<|turn>user
{user_prompt}<turn|>
<|turn>model

πŸ“± Mobile Integration (Kofu Mobile & llama.cpp)

llama.cpp CLI Execution

./llama-cli -m kofu-gemma4-edge-q4_k_m.gguf   -p "<|turn>user
Explica la diferencia entre punteros y referencias en C++.<turn|>
<|turn>model
"   -n 512 --temp 0.7 --top-p 0.9 --repeat-penalty 1.1

Kofu Assistant Android App

In Kofu Mobile Assistant, you can select Kofu 4.0 Edge (Gemma 4) directly from the top bar model selector. The engine dynamically sets the PromptStyle::GEMMA_4 tokenizer format and allocates Vulkan/OpenCL/CPU acceleration.


βš–οΈ License & Terms of Use

This model is subject to the Google Gemma Terms of Use and incorporates modifications under the Apache License 2.0.

  • Base Model License: Gemma Terms of Use
  • Modifications: Fine-tuning with LoRA on open instruction datasets, merged weights, and quantized to GGUF Q4_K_M.
  • Prohibited Uses: Users must comply with Google's Prohibited Use Policy. Do not use for harmful, illegal, or unethical applications.
  • Attribution: Based on Google's google/gemma-4-E4B-it. Developed for Kofu Mobile by shebxyd.
Downloads last month
252
GGUF
Model size
7B params
Architecture
gemma4
Hardware compatibility
Log In to add your hardware

4-bit

Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support

Model tree for shebxyd/kofu-gemma4-edge

Quantized
(450)
this model