huggingface / huggingface/candle

1.58 bit implementation

Open
#1,956 6 comments 1 reaction 0 assignees View on GitHub
Dominant language
Rust
Stars
21k
Forks
1.8k
Avg merge
16h 42m
Merged PRs (30d)
25

Description

Would it possible to implement 1.58 bit quantization on candle ? It was proposed in the following paper,

https://arxiv.org/pdf/2402.17764.pdf

The main inspiration behind using 1.58 bit implementation is that you could replace matrix multiplication with addition. If that is feasible, with apple accelerate framework's SIMD instructions, we could expect better training and inference on large language models.

A couple of Llama.cpp discussions here

https://github.com/ggerganov/llama.cpp/issues/5761
https://github.com/ggerganov/llama.cpp/pull/5999

There is also a training library which was released a couple of days ago,
https://github.com/rafacelente/bllama

Any thoughts ?

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reading the referenced paper, the linked llama.cpp discussion and pull request, and the bllama training library to understand the proposed 1.58-bit approach. No Candle files, tests, or entry points are named; the work would need a defined implementation scope and measurable training or inference outcome before completion can be assessed.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
machine-learning, performance
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.