gemma-3-4b-it-pms-16384

This model is a 14.63% smaller version of google/gemma-3-4b-it optimized for Piedmontese language via vocabulary size reduction using the trimming method.

This trimmed model should perform similarly to the original model with only 16,384 tokens and a much smaller memory footprint. However, it may not perform well for other languages as tokens not commonly used in Piedmontese were removed from the vocabulary.

Model Statistics

Metric Original Trimmed Reduction
Vocabulary size 262,144 tokens 16,384 tokens 93.75%
Model size 4,300,079,472 params 3,670,770,032 params 14.63%

Mining Dataset Statistics

Usage

from transformers import AutoModelForCausalLM, AutoTokenizer

model_name = "AlphaEdge-AI/gemma-3-4b-it-pms-16384"

tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModelForCausalLM.from_pretrained(
    model_name,
    torch_dtype="auto",
    device_map="auto"
)

prompt = "Your prompt in Piedmontese."
messages = [{"role": "user", "content": prompt}]
text = tokenizer.apply_chat_template(
    messages,
    tokenize=False,
    add_generation_prompt=True
)
model_inputs = tokenizer([text], return_tensors="pt").to(model.device)

generated_ids = model.generate(**model_inputs, max_new_tokens=256)
output_ids = generated_ids[0][len(model_inputs.input_ids[0]):]
response = tokenizer.decode(output_ids, skip_special_tokens=True)
print(response)

Citation

Gemma 3

@misc{gemmateam2025gemma3technicalreport,
      title={Gemma 3 Technical Report},
      author={Gemma Team},
      year={2025},
      eprint={2503.19786},
      archivePrefix={arXiv},
      primaryClass={cs.CL},
      url={https://arxiv.org/abs/2503.19786},
}
Downloads last month
9
Safetensors
Model size
4B params
Tensor type
BF16
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for alphaedge-ai/gemma-3-4b-it-pms-16384

Quantized
(466)
this model

Dataset used to train alphaedge-ai/gemma-3-4b-it-pms-16384

Collection including alphaedge-ai/gemma-3-4b-it-pms-16384

Paper for alphaedge-ai/gemma-3-4b-it-pms-16384