Why fine-tune four small models
Stock small models are trained to be decent at everything, which makes them shaky on narrow app contracts. Inside LokalBot, four models carry the whole local workflow on a laptop: Qwen3.5 4B writes source-linked meeting notes, decisions, actions, and Personal Context memories; Qwen3-ASR 1.7B and 0.6B handle meeting transcription and push-to-talk dictation; and Gemma 4 E2B drives inline autocomplete.
In version 0.14.0, all four defaults moved to Apache-2.0 fine-tunes published on Hugging Face. Every row in the training data comes from open-license sources (Apache-2.0, ODC-By-1.0, CC-BY-4.0, MIT, and CC0) plus open-weight teacher outputs. Zero private user meetings or recordings were used in training, and every previous stock model stays selectable in Settings > Models if you want to switch back.
1. Qwen3.5 4B (LokalBot v4): training inside the Swift validator loop
LokalBot's meeting pipeline already has a strict Swift evidence and ownership validator in MeetingNotesReplayTests. Every extracted action or decision must cite real transcript segments and assign an owner supported by the text. Early synthetic datasets looked fine to a generic judge and then failed inside the Swift app.
For v4, we ran every synthetic training meeting through the exact compiled Swift validator until all 4,117 rows passed with zero Swift rejections: 2,005 meetings (9,192 actions, 1.4% zero-action rate), 240 on-policy repair examples, 964 Personal Context memory cases (67.8% negative/empty traps), 338 Ask tool-calling trajectories, 170 Day Digest rows, and 400 general replay rows from allenai/tulu-3-sft-mixture.
That loop also exposed a real failure in v3: our synthetic meetings always had named speakers and a confirmed Me track, while real calls often arrive with unnamed diarized rosters (them 1..8, local 1..3, them unclear). That mismatch caused six zero-action collapses on our 28-meeting dev replay. Adding 487 unnamed diarized meetings in v4 brought those collapses to zero.
We trained a rank-32 bf16 LoRA across all 248 language-model linear projections, merged at scale=1.0 in fp32, and quantized to Q4_K_M (2.741 GB, matching stock byte range) with a 64-chunk bilingual English/Serbian/JSON imatrix. Same-GPU replay against stock Qwen3.5-4B-Q4_K_M on pinned llama.cpp v1.0.0 with enable_thinking=false:
| Suite & metric | Stock Qwen3.5 4B | Qwen3.5-4B-LokalBot-v4 |
|---|---|---|
| Memory120 (Personal Context, 120 cases) | 81/120 (67.5%, 12 unwanted) | 118/120 (98.3%, 1 unwanted) |
| Memory120 Serbian recall (13 gold) | 0/13 (9 unwanted) | 13/13 (0 unwanted) |
| Blind21 completed jobs (21 untouched EN calls) | 20/21 | 21/21 |
| Blind21 validator rejections | 175 (56 repair passes) | 69 (-60.6%, 28 repair passes) |
| Blind21 median latency (G4 GPU) | 24.24 s | 13.64 s (1.78x faster) |
| Blind21 decision overlap (40 ref) | 3/40 (7.5%) | 18/40 (45.0%) |
| Blind21 raw action recall (85 ref) | 47/85 (55.3%) | 40/85 (47.1%, McNemar p=0.2478) |
| Private28 dev action recall / rejections | 73/147 (49.7%) / 160 rej | 76/147 (51.7%) / 67 rej (-58.1%) |
| Golden6 Russian drift on Serbian | 21 drift hits | 0 drift hits |
What did not work: honest negative results
Publishing only the green rows makes local model numbers useless, so here are the two clearest misses from this cycle:
- Blind21 raw action recall dropped versus stock. On the 21 untouched English holdout meetings, stock
Qwen3.5-4Bstill recalled47/85(55.3%) reference actions compared to40/85(47.1%) forv4(exact two-sided McNemarp = 0.2478), and stock produced fewer false-positive decisions on the 9 zero-decision meetings (6vs25). Also, when forced intoenable_thinking=trueonThinkOnSmoke6,v4passed4/6with one</think>tag leak, which is why LokalBot defaultsv4to thinking off under Automatic. We shippedv4because118/120memory restraint, zero Serbian/Russian drift, 60.6% fewer validator rejections, and 1.78x faster extraction beat stock in day-to-day use, while keeping stock one click away. - The Astra weight-space pilot moved 5,120 weights and zero outputs. Before spending GPU hours on LoRA, I ran a bounded weight-editing pilot on
Qwen3.5-4Busing a rented RTX 3090 (~$0.14 GPU/disk cost). Guided by four dev traces, we halved two MLP output columns (2416and8819) inlayers.23.mlp.down_proj.weight, editing 5,120 BF16 weights (27,741packed bytes inblk.23.ffn_down.weightafterQ4_K_Mquantization). The tensor change survived quantization intact, and all 40 paired outputs (10 dev plus 30 held-out synthetic memory cases) came back byte-identical:22/30held-out on both arms, zero delta. Two edited columns could not shift behavior on this task; a full rank-32 LoRA across all 248 projections did.
2. Qwen3-ASR 1.7B (v3) and 0.6B (v1): killing silence ghosts and code-switching errors
Stock Qwen3-ASR 1.7B had two bugs that showed up immediately in daily use. First, holding the dictation shortcut in a quiet room with a custom vocabulary prompt caused it to echo the prompt or hallucinate speech (only 8.3% clean silence on our holdout, with 16 prompt echoes and 123 hallucinated words). Second, mid-sentence bilingual code-switching (sr+en and en+de) hit 37.12% WER.
A decoder-only LoRA (v2) fixed dictation silence, but far-field meeting audio barely budged. For Qwen3-ASR-1.7B-LokalBot-v3, we unlocked the top 4 audio_tower transformer layers (layers.20..23) plus audio_tower.proj1 and proj2 with a rank-16 LoRA at a 0.4x differential learning rate alongside the rank-32 decoder LoRA (scale=1.15), anchored with Forward KL on guard languages so English, German, French, Spanish, and Russian would not drift.
- Code-switching holdout WER (
sr+en,en+de): cut from37.12%to12.81%(-24.31 pp). - Dictation silence & ambient noise:
100.0%clean abstention (0prompt echoes,0hallucinated words, up from8.3%/123words on stock). Custom vocabulary recall rose from86.7%to100.0%(4.00%WER vs9.00%) with zero distractor injections. - South Slavic (
sr/hr/bs) auto WER: dropped from24.64%to17.79%(-6.85 pp); out-of-domain Croatian (VoxPopuli hr) fell from24.95%to19.06%. - Expanded AMI-400 meetings (
200 ihm + 200 sdm): close-mic9.79%vs10.24%stock; far-field24.41%vs26.08%(-1.67 pp), at31.24xreal-time on Apple M4 Max Metal (2.52 GBcombined Q8_0 decoder andmmproj). Tradeoff:2/200low-SNR far-field clips abstain vs0/200stock, and guard languages shifted+0.18 pp(4.35%to4.53%).
For smaller machines, Qwen3-ASR-0.6B-LokalBot-v1 (1.02 GB combined, 52.7x real-time on M4 Max Metal) keeps the audio_tower frozen so the stock mmproj stays bit-identical. On the same 466-clip blind holdout, it cut South Slavic auto WER from 52.26% to 30.57% (-21.69 pp), code-switching WER from 49.21% to 20.72% (-28.49 pp), raised custom vocabulary recall from 80.0% to 100.0% with 100% clean silence, and beat stock on AMI-400 (10.72% ihm, 26.23% sdm) while holding 7 guard languages within +0.13 pp.
3. Gemma 4 E2B (LokalBot v4): 56/56 context grounding at 20.2 ms
Inline autocomplete has the opposite problem from chat models: raising recall slightly too aggressively makes the ghost text annoying. Our earlier high-coverage checkpoint (v3) boosted word-boundary recall to 30.71%, but added +39 wrong-shown suggestions and missed 2 of 26 memory recall checks.
For Gemma-4-E2B-LokalBot-v4 (3.845 GB i1-Q6_K), we trained a rank-32 LoRA across 275 matrices in all 35 layers (including 70 Per-Layer Embedding projections) on 45,876 open-license rows using a three-regime Forward KL objective: soft-logit distillation from google/gemma-4-26B-A4B on ungrounded text, grounded window/memory rows, plus 13,400 KL-only calibration anchor rows against stock E2B starting at body token 0.
- Context and memory grounding:
56/56(100%) across all 7 saved-memory and visible-window suites (8/8visible dev,18/18visible held-out,4/4link,6/6memory dev,22/22memory held-out,12/12relevance held-out), with zero stale facts and zero unsafe outputs across 28 safety checks. - Precision without chatter:
199right /182wrong shown vs182/181on stock (+17right completions for+1wrong), raising email precision from74.3%to80.0%. - Latency:
20.2 msmedian boundary latency and80.0 mstyping p95 on M4 Max Metal (faster than stock21.2 ms/103.5 ms). Tradeoff:v4still has 2 forbidden hits onfresh_holdout_v1and 1 onfresh_holdout_v2;v3stays in the repo for users who want maximum coverage.
Download the Apache-2.0 GGUFs
All four checkpoints are Apache-2.0 and work directly with llama-server, Ollama, or LokalBot 0.14.0:
- Think (notes, actions, memory, Ask): stevyhacker/Qwen3.5-4B-LokalBot-GGUF (
Qwen3.5-4B-LokalBot-v4-Q4_K_M.gguf, 2.74 GB) - Transcription (accuracy): stevyhacker/Qwen3-ASR-1.7B-LokalBot-GGUF (
v3Q8_0 + pairedmmproj, 2.52 GB) - Transcription (compact): stevyhacker/Qwen3-ASR-0.6B-LokalBot-GGUF (
v1Q8_0 + stockmmproj, 1.02 GB) - Autocomplete (Cotyping): stevyhacker/Gemma-4-E2B-LokalBot-GGUF (
Gemma-4-E2B-LokalBot-v4-i1-Q6_K.gguf, 3.85 GB)
Fresh installs of LokalBot 0.14.0 pick these defaults automatically. Existing installs keep their current models until you click Upgrade on Today or in Settings > Models. See the full reproducible numbers across every local role on our Local Desktop AI Leaderboard.