How to install microsoft/BitNet. Official installation instructions. Project installation guide. Framework or library installation. Build installation instructions. How to setup and install from GitHub. Installation steps and setup instructions. Official docs and installation instructions GitHub.
microsoft/BitNet Installation Guide
How to install microsoft/BitNet. Official project installation instructions and setup guide.
⚡
Automated Install (Recommended)
Quick installation instructions for microsoft/BitNet. This is the fastest way to complete project installation and setup.
Install via curl
curl -fsSL https://hexmos.com/ipm-install | bash &&
ipm i microsoft/BitNetor
Install via npx
npx @hexmos/ipm i microsoft/BitNetPrerequisites
Python
languageVersion: >=3.6.0
Git
system_toolFor cloning the repository and managing code changes.
Docker
system_toolTo build and run containerized applications. (Optional)
Manual Installation Methods
Manual installation instructions. How to install from GitHub source.
Source Installation (Manual)
git clone --recursive https://github.com/microsoft/BitNet.git
cd BitNet
conda create -n bitnet-cpp python=3.9
conda activate bitnet-cpp
pip install -r requirements.txt
huggingface-cli download microsoft/BitNet-b1.58-2B-4T-gguf --local-dir models/BitNet-b1.58-2B-4T
python setup_env.py -md models/BitNet-b1.58-2B-4T -q i2_sConvert from .safetensors Checkpoints
git clone --recursive https://github.com/microsoft/BitNet.git
cd BitNet
huggingface-cli download microsoft/bitnet-b1.58-2B-4T-bf16 --local-dir ./models/bitnet-b1.58-2B-4T-bf16
python ./utils/convert-helper-bitnet.py ./models/bitnet-b1.58-2B-4T-bf16Run inference with the quantized model
git clone --recursive https://github.com/microsoft/BitNet.git
cd BitNet
conda create -n bitnet-cpp python=3.9
conda activate bitnet-cpp
pip install -r requirements.txt
python run_inference.py -m models/BitNet-b1.58-2B-4T/ggml-model-i2_s.gguf -p "You are a helpful assistant" -cnvBenchmark
git clone --recursive https://github.com/microsoft/BitNet.git
cd BitNet
python utils/e2e_benchmark.py -m /path/to/model -n 200 -p 256 -t 4Generate Dummy Model and Benchmark
git clone --recursive https://github.com/microsoft/BitNet.git
cd BitNet
python utils/generate-dummy-bitnet-model.py models/bitnet_b1_58-large --outfile models/dummy-bitnet-125m.tl1.gguf --outtype tl1 --model-size 125M
python utils/e2e_benchmark.py -m models/dummy-bitnet-125m.tl1.gguf -p 512 -n 128Post Installation Steps
- Start the server using the command: `npm start`
- Run database migrations with the command: `npx sequelize db:migrate`
