Skip to content

[feat] Add GGUF conversion and inference support for BitNet embedding 270m (Gemma3)#562

Open
isHuangXin wants to merge 3 commits into
microsoft:mainfrom
isHuangXin:dev-bitnet-embedding-270m
Open

[feat] Add GGUF conversion and inference support for BitNet embedding 270m (Gemma3)#562
isHuangXin wants to merge 3 commits into
microsoft:mainfrom
isHuangXin:dev-bitnet-embedding-270m

Conversation

@isHuangXin
Copy link
Copy Markdown

@isHuangXin isHuangXin commented May 21, 2026

  • Add convert-bitnet-embedding-270m-to-gguf.py for Gemma3-based 270m models
  • Support f32, f16, and I2_S ternary quantization output types
  • Add AVX512BW SIMD paths for I2_S dot product in ggml-bitnet-mad.cpp
  • Add immintrin.h include and bitnet-lut-kernels.h guard in ggml-bitnet-lut.cpp
  • Add documentation for Gemma3 GGUF conversion implementation
  • Update llama.cpp submodule with Gemma3 architecture support

…nversion

- Add GGUF conversion tool for bitnet-embeddings-0.6b (safetensors -> F16/I2_S GGUF)
- Add Qwen3 architecture support in llama.cpp submodule with per-projection RMSNorm
- Add I2_S ternary quantization (2-bit packed -1/0/+1) for lossless precision
- Add f16 norm weight support for correct embedding inference
- Add AVX512BW SIMD paths for I2_S kernel (~2x throughput on AVX512-capable CPUs)
- Guard bitnet-lut-kernels.h include with TL1/TL2 preprocessor checks
- Update llama.cpp submodule to dev-bitnet-embedding-0.6b branch
- Document F16 (from multilingual-e5-0.6b) and I2_S (from bitnet-embeddings-0.6b) conversion process
@isHuangXin isHuangXin changed the title [feat] Add GGUF conversion and inference support for BitNet embedding… [feat] Add GGUF conversion and inference support for BitNet embedding 270m (Gemma3) May 21, 2026
@isHuangXin
Copy link
Copy Markdown
Author

@microsoft-github-policy-service agree

… 270m (Gemma3)

- Add convert-bitnet-embedding-270m-to-gguf.py for Gemma3-based 270m models
- Support f32, f16, and I2_S ternary quantization output types
- Add AVX512BW SIMD paths for I2_S dot product in ggml-bitnet-mad.cpp
- Add immintrin.h include and bitnet-lut-kernels.h guard in ggml-bitnet-lut.cpp
- Add documentation for Gemma3 GGUF conversion implementation
- Update llama.cpp submodule with Gemma3 architecture support
…edding models

- Merge convert-bitnet-embedding-270m-to-gguf.py into convert-bitnet-embedding-to-gguf.py
  with auto-detection of model architecture (qwen3/gemma3_text) from config.json
- Merge separate Qwen3 and Gemma3 conversion docs into a single
  bitnet-embeddings-gguf-conversion.md
- Remove redundant per-architecture scripts and docs
@isHuangXin isHuangXin force-pushed the dev-bitnet-embedding-270m branch from 86e63a1 to 5720fc7 Compare May 24, 2026 10:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant