bitsandbytes-foundation/bitsandbytes

Accessible large language models via k-bit quantization for PyTorch.

View on GitHub ↗Jump to charts ↓

Summary Information

Updated 31 minutes ago
Added to GitGenius on September 7th, 2026
Created on June 4th, 2021
Open Issues & Pull Requests: 79 (+0)
GitHub issues: Enabled
Number of forks: 923
Total Stargazers: 8,465 (+0)
Total Subscribers: 53 (+0)

Repository Insights (GitGenius)

Median issue/PR response: 2.1 days
Mean response time: 75.3 days
90th percentile: 342.4 days
Tracked items: 446

How this project is maintained

Around half of the issues opened in the past year never receive a reply. 95% of open issues come from outside the core team, so the backlog reflects real-world use rather than internal planning. Work labelled "Build" is answered fastest, typically in about 13 hours, while "Bug" waits about 3 weeks. Only 5% of issues opened in the past year have been closed. Three people close 88% of everything that gets resolved.

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Open issues: 42
New in 7 days: 2
Closed in 7 days: 0
Avg open age: 406 days
Stale 30+ days: 31
Stale 90+ days: 24

Recent activity

Opened in 7 days: 2
Closed in 7 days: 0
Comments in 7 days: 0
Events in 7 days: 0

Top labels

  • CUDA Setup (73)
  • Cross Platform (34)
  • Optimizers (25)
  • Proposing to Close (25)
  • Question (24)
  • Build (23)
  • ROCm (23)
  • Windows (23)

Detailed Description

bitsandbytes is a PyTorch library that enables k-bit quantization for large language models.

The library addresses the memory constraints of training and deploying large language models by providing three quantization approaches. 8-bit optimizers use block-wise quantization to maintain 32-bit optimizer performance while drastically reducing memory overhead. LLM.int8() performs 8-bit quantization through vector-wise techniques, quantizing most weights to 8-bits while handling outliers separately with 16-bit operations, cutting inference memory requirements in half without performance loss. QLoRA extends this with 4-bit quantization combined with low-rank adaptation weights, enabling full model training on consumer hardware by quantizing model weights to 4-bits while keeping a small set of trainable LoRA parameters at higher precision. The library exposes these capabilities through dedicated modules: Linear8bitLt and Linear4bit layers for quantized operations, and an optim module for quantized optimizers.

Developers should adopt this tool if they need to run or fine-tune large language models on hardware with limited memory. It suits projects where reducing memory footprint is critical without sacrificing model quality—particularly fine-tuning scenarios where QLoRA's approach of training only adapter weights proves effective. The tool requires Python 3.10 or later and PyTorch 2.4 or later, with support varying across different accelerator types.

The project maintains nightly unit tests to catch regressions. Development targets broad hardware compatibility, with the current branch reflecting planned and partially supported accelerator backends beyond those in the latest stable release.