Downloads · 30 days
0
ravikadam/ganesh-gemma4-e4b
ganesh-gemma4-e4b is a text generation model from ravikadam. Use it when you need the model to write or continue text. It is set up for litert. The card lists the license as gemma.
An offline assistant fine-tuned on Shri Ganesha's shlokas, stotras, aartis, rituals and stories, for Ganeshotsav 2026. Answers in Marathi, Hindi or English. No RAG — the canon is in the weights.
Downloads · 30 days
0
Access
Public
Updated Aug 25, 2026
Parameters
7.9B
15.9 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors15.9 GB · 100%
From the Hugging Face model README
An offline assistant fine-tuned on Shri Ganesha's shlokas, stotras, aartis, rituals and stories, for Ganeshotsav 2026. Answers in Marathi, Hindi or English. No RAG — the canon is in the weights.
Created in service of Shri Ganesh by Ravi Kadam — https://www.linkedin.com/in/ravikadam/
Recites, verbatim and exactly:
Also covers puja vidhi (pranapratishtha, shodashopachara, durva and the 21 patri, uttarpuja, visarjan), the Puranic stories, the Ashtavinayak, Mumbai's mandals, and 2026 festival dates.
Every dated answer is year-stamped ("In 2026...") so it never reads as a claim about the current year, and every muhurat names its city (Mumbai's 2026 window is 11:20–13:48, about 18 minutes later than the generic figure — which is exactly why a bare time is wrong).
Small curated corpus (32 units) → deterministic pair generation. Canonical Devanagari is spliced byte-exact from YAML and never passes through a generative model; only the question side is varied. Unverified texts are gated out of training entirely. 1,959 training pairs (1,216 verbatim / 405 calendar / 338 prose).
LoRA r=64, alpha=128, 3 epochs, lr 1e-4, bf16, seq 2048, on an L40S.
Adapters scoped to the language model — Gemma 4's E-series wraps vision/audio projections in
Gemma4ClippableLinear, which PEFT cannot target.
Final train loss 0.46, train token accuracy 0.97.
from transformers import AutoTokenizer, AutoModelForCausalLM
import torch
m_id = "ravikadam/ganesh-gemma4-e4b"
tok = AutoTokenizer.from_pretrained(m_id)
model = AutoModelForCausalLM.from_pretrained(m_id, dtype=torch.bfloat16, device_map="auto")
msgs = [
{"role": "system", "content": "You are an offline assistant fine-tuned on Shri Ganesha's shlokas, stotras, aartis, rituals and stories. Answer in the language the user writes in. Never invent a verse."},
{"role": "user", "content": "सुखकर्ता दुखहर्ता आरती म्हण."},
]
enc = tok.apply_chat_template(msgs, add_generation_prompt=True, tokenize=True,
return_dict=True, return_tensors="pt").to(model.device)
out = model.generate(**enc, max_new_tokens=700, do_sample=False)
print(tok.decode(out[0][enc["input_ids"].shape[-1]:], skip_special_tokens=True))
गणपती बाप्पा मोरया 🙏