dhafapermadi commited on
Commit
44d2860
ยท
0 Parent(s):

Duplicate from dhafapermadi/Blueboop-Jigsaw-1.8

Browse files
.gitattributes ADDED
@@ -0,0 +1,40 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ *.7z filter=lfs diff=lfs merge=lfs -text
2
+ *.arrow filter=lfs diff=lfs merge=lfs -text
3
+ *.bin filter=lfs diff=lfs merge=lfs -text
4
+ *.bz2 filter=lfs diff=lfs merge=lfs -text
5
+ *.ckpt filter=lfs diff=lfs merge=lfs -text
6
+ *.ftz filter=lfs diff=lfs merge=lfs -text
7
+ *.gz filter=lfs diff=lfs merge=lfs -text
8
+ *.h5 filter=lfs diff=lfs merge=lfs -text
9
+ *.joblib filter=lfs diff=lfs merge=lfs -text
10
+ *.lfs.* filter=lfs diff=lfs merge=lfs -text
11
+ *.mlmodel filter=lfs diff=lfs merge=lfs -text
12
+ *.model filter=lfs diff=lfs merge=lfs -text
13
+ *.msgpack filter=lfs diff=lfs merge=lfs -text
14
+ *.npy filter=lfs diff=lfs merge=lfs -text
15
+ *.npz filter=lfs diff=lfs merge=lfs -text
16
+ *.onnx filter=lfs diff=lfs merge=lfs -text
17
+ *.ot filter=lfs diff=lfs merge=lfs -text
18
+ *.parquet filter=lfs diff=lfs merge=lfs -text
19
+ *.pb filter=lfs diff=lfs merge=lfs -text
20
+ *.pickle filter=lfs diff=lfs merge=lfs -text
21
+ *.pkl filter=lfs diff=lfs merge=lfs -text
22
+ *.pt filter=lfs diff=lfs merge=lfs -text
23
+ *.pth filter=lfs diff=lfs merge=lfs -text
24
+ *.rar filter=lfs diff=lfs merge=lfs -text
25
+ *.safetensors filter=lfs diff=lfs merge=lfs -text
26
+ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
27
+ *.tar.* filter=lfs diff=lfs merge=lfs -text
28
+ *.tar filter=lfs diff=lfs merge=lfs -text
29
+ *.tflite filter=lfs diff=lfs merge=lfs -text
30
+ *.tgz filter=lfs diff=lfs merge=lfs -text
31
+ *.wasm filter=lfs diff=lfs merge=lfs -text
32
+ *.xz filter=lfs diff=lfs merge=lfs -text
33
+ *.zip filter=lfs diff=lfs merge=lfs -text
34
+ *.zst filter=lfs diff=lfs merge=lfs -text
35
+ *tfevents* filter=lfs diff=lfs merge=lfs -text
36
+ gemma4-coding-Q2_K.gguf filter=lfs diff=lfs merge=lfs -text
37
+ gemma4-coding-Q4_K_M.gguf filter=lfs diff=lfs merge=lfs -text
38
+ gemma4-coding-Q6_K.gguf filter=lfs diff=lfs merge=lfs -text
39
+ gemma4-coding-Q8_0.gguf filter=lfs diff=lfs merge=lfs -text
40
+ gemma4-coding-Q3_K_M.gguf filter=lfs diff=lfs merge=lfs -text
README.md ADDED
@@ -0,0 +1,155 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ base_model: google/gemma-4-12B-it
4
+ library_name: gguf
5
+ pipeline_tag: text-generation
6
+ tags: [gemma4, coding, code, reasoning, thinking, gguf, llama.cpp, local-llm]
7
+ ---
8
+
9
+ # ๐Ÿ’ป Blueboop Jigsaw (GGUF)
10
+ ### ๐Ÿฃ Tiny footprint, big brain โ€” a local **coding** model for *everyone*
11
+
12
+ > **No matter your GPU. No matter your RAM.** If you've got **~4.5 GB** of VRAM *or* unified memory free,
13
+ > you can run your own private, offline coding assistant right now. ๐Ÿš€
14
+ > This is the **v1 / code edition** โ€” distilled from **real chain-of-thought** so it *thinks through* a problem
15
+ > before writing the solution. ๐Ÿง ๐Ÿ’ป All local, all yours, no API, no cloud.
16
+
17
+ ### ๐ŸŽฏ What it is
18
+ A focused fine-tune of Gemma 4 12B on **verifiable Python coding** data โ€” every training example's reasoning leads to
19
+ code that **actually passed its tests**. The result reasons in the open (edge cases, complexity, approach) and then
20
+ emits a clean, runnable solution. ๐Ÿ’š
21
+
22
+ ---
23
+
24
+ ## ๐Ÿ“Œ Announcements
25
+
26
+ **๐Ÿš€๐Ÿ”ฅ BIG NEWS โ€” v2 drops EARLY!** I'm pushing it **ahead of schedule: tomorrow, 5โ€“8 PM (US Pacific), sharp.** โฐ
27
+ It lands in **both** formats at once, in **two repos** โ€” **GGUF** (ready to run) **+ the full `safetensors` master**
28
+ (build / fine-tune on top). v2 is **agentic + coding** focused โ€” the piece v1 was missing.
29
+
30
+ **A sneak peek ๐Ÿ‘€ (yep, I'm spoiling it early).** When I saw v2's **tau2-bench `telecom`** result โ€” an agentic tool-use
31
+ benchmark where the model has to *diagnose โ†’ fix โ†’ verify*, exactly like real terminal/debugging work โ€” I literally got
32
+ **launched out of my chair** (โ€ฆokay, *kidding* ๐Ÿ˜„). The jump in **actually solving the problem** is wild:
33
+
34
+ | tau2-bench **telecom** ยท local, same harness, **Q8_0** | score |
35
+ |---|---|
36
+ | official `gemma-4-12B-it` (base) | **~15%** |
37
+ | ๐ŸŸข **v2 (dropping tomorrow)** | **~55%** |
38
+
39
+ The base model tends to **give up early** (hands the problem off to a human); **v2 keeps going** and works it the way a
40
+ much bigger model would. Full benchmark details land in the v2 card tomorrow. ๐Ÿ”ง
41
+
42
+ **โœ… safetensors master (this v1 model) is UP.** Full-precision weights are live โ†’
43
+ **[dhafapermadi/blueboop-jigsaw-1.8](https://huggingface.co/dhafapermadi/blueboop-jigsaw-1.8)**
44
+ โ€” roll your own GGUF / MLX / AWQ quants or fine-tune straight from the master. ๐ŸŽ‰
45
+
46
+ ---
47
+
48
+ ## ๐Ÿ“ฃ Context length fixed: now **256K** (was 131K) โ€” thanks, community! ๐Ÿ’š
49
+
50
+ A community member spotted that this model was reporting only a **131K** context window. That turned out to be
51
+ the well-known upstream **Gemma 4 metadata bug** โ€” Google's initial `config.json` shipped with
52
+ `max_position_embeddings: 131072` instead of the real **262144 (256K)**, and that value got baked into a lot of
53
+ downstream finetunes and quants (including this one) before it was fixed upstream.
54
+
55
+ The weights were always fine โ€” it was purely a metadata field. **All GGUF quants have been re-patched to the
56
+ full 256K context** (`gemma4.context_length = 262144`). Just re-download if you grabbed an earlier copy. ๐Ÿ™
57
+
58
+ ---
59
+
60
+ ## ๐Ÿ“š Training data (the interesting part ๐Ÿณ)
61
+
62
+ This is a **distillation** of two complementary chain-of-thought sources, both over verifiable Python coding tasks
63
+ (algorithmic / function-level problems that come with deterministic tests):
64
+
65
+ - **๐Ÿฅ‡ Main set โ€” Composer 2.5 *real* CoT.** Genuine, model-authored reasoning traces. The teacher solved each problem,
66
+ its code was **run against the task's tests, and only the passing solutions were kept**. So the reasoning you're
67
+ learning from leads to code that *actually works*.
68
+ - **๐Ÿฅˆ Aux set โ€” Fable 5 (released today! ๐ŸŽ‰).** A clever twist: we took the problems where **Composer 2.5 got it wrong**
69
+ and handed them to **Fable 5** to *redo* โ€” re-deriving a fresh, self-consistent chain-of-thought and a correct
70
+ solution, again **gated on passing the tests**. This recovers the hard cases the main teacher missed. These traces
71
+ are **synthetic** (rationalized CoT), and are tagged separately so the two sources stay distinguishable.
72
+
73
+ The recipe: real CoT for the bulk of solid coverage, plus synthetic "second-attempt" CoT to patch the failures โ€”
74
+ both verified by execution before anything entered training. โœ…
75
+
76
+ ---
77
+
78
+ ## ๐Ÿ“ฆ Pick your size (GGUF quants)
79
+
80
+ | Quant | Size | Vibe |
81
+ |------|------|------|
82
+ | ๐ŸŸข **Q2_K** | **4.5 GB** | tiniest โ€” runs almost anywhere |
83
+ | ๐ŸŸก **Q3_K_M** | **5.7 GB** | great for 8 GB VRAM โ€” much better than Q2 |
84
+ | ๐Ÿ”ต **Q4_K_M** | **6.87 GB** | the sweet spot ๐Ÿ‘Œ (recommended) |
85
+ | ๐ŸŸฃ **Q6_K** | **9.11 GB** | near-lossless |
86
+ | โšช **Q8_0** | **11.8 GB** | basically full quality |
87
+
88
+ ---
89
+
90
+ ## ๐Ÿงฎ "Will it fit?" โ€” context length cheat-sheet
91
+
92
+ Rough estimates ๐Ÿค“ (assumes `q8_0` KV cache + ~1.5 GB overhead; **use `q4_0` KV cache for โ‰ˆ2ร— more context!**).
93
+ Max context is **256K**. "โ€”" = won't fit, pick a smaller quant. โœ‚๏ธ
94
+
95
+ | Your VRAM / unified mem | ๐ŸŸข Q2_K (4.5G) | ๐ŸŸก Q3_K_M (5.7G) | ๐Ÿ”ต Q4_K_M (6.87G) | ๐ŸŸฃ Q6_K (9.11G) | โšช Q8_0 (11.8G) |
96
+ |---|---|---|---|---|---|
97
+ | **8 GB** | ~16K ctx | ~10K | tight (~2โ€“4K) | โ€” | โ€” |
98
+ | **12 GB** | ~48K | ~38K | ~30K | ~12K | โ€” |
99
+ | **16 GB** | ~80K | ~72K | ~64K | ~44K | ~22K |
100
+ | **24 GB** | ~200K | ~160K | ~128K | ~110K | ~88K |
101
+ | **32 GB** | 256K (max) ๐ŸŽ‰ | 256K | 256K | ~230K | ~190K |
102
+
103
+ > ๐Ÿ’ก Apple Silicon / integrated GPUs with **unified memory** count too โ€” same numbers, just slower than a dGPU.
104
+ > ๐Ÿ’ก Low on room? Drop a quant or switch KV cache to `q4_0` and your context roughly doubles.
105
+
106
+ ---
107
+
108
+ ## ๐Ÿš€ How to run it (super easy)
109
+
110
+ ### Option A โ€” llama.cpp (recommended) ๐Ÿฆ™
111
+ 1. Grab a quant above (e.g. `โ€ฆ-Q4_K_M.gguf`) and `llama-server` from [llama.cpp](https://github.com/ggml-org/llama.cpp).
112
+ > โš ๏ธ Needs a **recent llama.cpp** (this is the `gemma4_unified` architecture โ€” older builds won't load it).
113
+ 2. Run a server (Windows `.bat` shown โ€” tweak `--port`, `--ctx-size` to taste):
114
+
115
+ ```bat
116
+ @echo off
117
+ cd /d C:\llama.cpp
118
+ llama-server.exe ^
119
+ -m C:\models\gemma4-coding-Q4_K_M.gguf ^
120
+ --ctx-size 16384 ^
121
+ --n-gpu-layers 99 ^
122
+ --no-mmap ^
123
+ -fa on ^
124
+ --cache-type-k q8_0 --cache-type-v q8_0 ^
125
+ --temp 1.0 --top-p 0.95 --top-k 64 ^
126
+ --host 0.0.0.0 --port 18080
127
+ pause
128
+ ```
129
+ 3. Open `http://localhost:18080` and chat. ๐ŸŽ‰ (Tip: bump `--ctx-size` per the table; use `q4_0` KV for more.)
130
+
131
+ ### Option B โ€” one-click apps ๐Ÿ–ฑ๏ธ
132
+ Works in **LM Studio**, **Jan**, **Ollama**, etc. โ€” just import the GGUF, pick your quant, go. ๐Ÿพ
133
+
134
+ ### ๐Ÿง  Thinking mode
135
+ This model thinks in Gemma's native thought channel before answering โ€” exactly how it was trained. Keep
136
+ **`enable_thinking=true`** (the default chat template handles it). Recommended sampling: `temp 1.0, top_p 0.95, top_k 64`.
137
+ For coding you can also go greedy (`temp 0`) for more deterministic solutions.
138
+
139
+ ---
140
+
141
+ ## โš ๏ธ Good to know
142
+ - **Reduced refusals:** the training data is task-focused with no safety hedging, so this refuses less than the base
143
+ model. It is **not** safety-aligned โ€” add your own guardrails for production. Use responsibly. ๐Ÿ™
144
+ - Specialized for **Python / algorithmic** coding. Reasoning quality is strongest in that domain; general-knowledge
145
+ facts/numbers should still be double-checked.
146
+ - English-centric.
147
+
148
+ ---
149
+
150
+ ## ๐Ÿ“š Base & License
151
+ - **License: Apache 2.0.** Gemma 4 is released by Google under
152
+ **[Apache 2.0](https://ai.google.dev/gemma/apache_2)** (unlike the older Gemma 1/2/3 terms), so this fine-tune is
153
+ **Apache 2.0** too โ€” free to use, modify, and redistribute. ๐ŸŽ‰
154
+ - **Base model:** [`google/gemma-4-12B-it`](https://huggingface.co/google/gemma-4-12B-it).
155
+ - Personal/hobby project โ€” shared as-is, no warranty. Have fun, and happy hacking! ๐Ÿพโœจ
gemma4-coding-Q2_K.gguf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:adbd331a74121b78f223b40b3a51f4418aa6f55122c1fa3711b0615f56bf8729
3
+ size 4830147104
gemma4-coding-Q3_K_M.gguf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b2d2ca4e1fc592a7ba77225032224938b9f159ef6431f57e1db1b5e612f50b54
3
+ size 6087086624
gemma4-coding-Q4_K_M.gguf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1fe90b72e105d7bc71650aa59883edece3e84751af489075217a7ae717b1fe8d
3
+ size 7381381664
gemma4-coding-Q6_K.gguf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9a4aa42ef5c540afedaeec47194c39abc9268745662dc44b8351f658e979b4b1
3
+ size 9786020384
gemma4-coding-Q8_0.gguf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:18629e26f7b800357fe95ae3804c9be49af58ebc73e80754c301ebe997e29fbb
3
+ size 12669645344