Re-upload didn't land — file on main is still the original build

#2
by Tgata - opened

Hi — I tried re-downloading, but the file on main still looks like the original build: same SHA256 89fc9b6bca47a164a0898695e3e109123b83d6c9c46d89135d7648132297b090, and ollama pull hf.co/haven-ai-companion/haven-chat-v3.0.3 still fails with the same GGUF parse error. The copy under Zzzz9645664/haven-chat-v3.0.3 has the identical hash. It looks like the re-upload didn't land.

On the original cause: the string-length prefix for tokenizer.chat_template is 16,804 while the actual template is 16,996 bytes — 192 bytes short. 16,804 is the character count, so it looks like len(template) was used instead of len(template.encode('utf-8')). Patching those 8 bytes in place was enough to make the file load in Ollama; the size of the template was never the issue.

One thing to flag for whenever the fix does go up: Gemma 4's chat format needs <|turn> / <turn|>, plus <|think|> and <|channel>thought<channel|> for thinking mode and <|tool_call> / <|tool_response> for tools. A 180-byte template can't express those branches, so the thinking-channel and tool-calling formatting would be lost.

Separately, haven_v3_0_3_identity_dpo.jsonl mixes template generations: the prompts use <start_of_turn> / <end_of_turn> (Gemma 3), while chosen/rejected use <|channel> (Gemma 4). Gemma 4's delimiters are <|turn> / <turn|>:
https://ai.google.dev/gemma/docs/core/prompt-formatting-gemma4

So the training context never matches inference. At temperature 0, Who are you? — the first prompt in that file — returns the rejected answer almost verbatim, thought channel included. The same Gemma 3 template also appears in the Modelfile on the org card, so it may be worth checking the SFT data too.

Haven AI Companion org

Thank you so much @Tgata for the thorough breakdown!

You were spot on — the UTF-8 byte length prefix for tokenizer.chat_template was calculated using string character count instead of raw byte length.

We have patched the GGUF header in-place and re-uploaded haven-chat-v3.0.3.gguf directly to main. It is now 100% parseable and ready to pull via Ollama / llama-server! Thanks again for catching this! 🎉

Haven AI Companion org

Hey @Tgata , just wanted to send an official confirmation that the re-uploaded haven-chat-v3.0.3.gguf file with the exact UTF-8 byte-length fix has now completed uploading to main!

You can pull the updated GGUF file directly now:
ollama pull hf.co/haven-ai-companion/haven-chat-v3.0.3

Thanks again for testing and providing the precise SHA256 & byte offset details! 🙌

Sign up or log in to comment