alimpfard/gemma-4-12b-ft-grammar-gguf overview
Finetune of gemma 4 12b it to process fiction or narrative text in general and fix grammatical and prose errors while maintaining the author's style, voice, an…
Runs locally from ~11.80 GB disk (12 GB VRAM class GPUs with llama.cpp / guIDE).
Repository Files & Downloads
| File | Type | Quantization | Size | Link |
|---|---|---|---|---|
| gemma-4-12b-ft-grammar.Q8_0.gguf | GGUF | GGUF | 11.80 GB | Download |
Model Details
Model README
---
language:
- en
base_model:
- google/gemma-4-12b-it
---
Finetune of gemma-4-12b-it to process fiction (or narrative text in general) and fix grammatical and prose errors while maintaining the author's style, voice, and word choices.
Prompt as user with "correct author-grammar.\n" prepended to the input contents; result is markdown or plain, depending on input format. Feed ~350-word chunks for best results; greedy decoding recommended.
Trained behavior (verified on held-out chunks):
- minimal diffs: only grammar/spelling/punctuation/tense fixes, ~0-1% of words touched; clean text returns byte-identical
- no preamble, no commentary, no length drift; paragraph structure preserved exactly
- em dashes never emitted: pairs -> parentheses, clause joins -> comma/semicolon/colon, interrupted speech -> ellipsis
- author's quote style (curly vs straight) and inline formatting (
italics,bold, headers) preserved
Training: QLoRA r8/alpha16 on all language-model attention+MLP projections, 593 minimal-edit pairs from long-form fanfiction, assistant-only loss, best-eval checkpoint merged to bf16 and quantized Q8_0.
Note on the chat template: this GGUF embeds a custom channel-free template (<|turn>user\n...<turn|>\n<|turn>model\n, no thought channels). The model was trained and validated with this exact format; using the stock gemma-4 template (which opens an empty thought channel in the generation prompt) is untested. Standard llama.cpp/LM Studio usage picks the embedded template automatically.
Sibling model: meta-llama-3.1-8b-ft-grammar-gguf (same dataset, smaller/faster, has a rare single-word-substitution quirk this one didn't exhibit).
Run alimpfard/gemma-4-12b-ft-grammar-gguf with guIDE
Download guIDE — the AI-native code editor with local LLM inference and 69 built-in tools.
Source: Hugging Face · Compare models