Text Generation
GGUF
English
llama.cpp
bitnet
ternary
1.58-bit
quantized
q4_k_m
edge
efficient-inference
cpu
tool-calling
Instructions to use Qapdex/SLM750-Edge-1.58-bit with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use Qapdex/SLM750-Edge-1.58-bit with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf Qapdex/SLM750-Edge-1.58-bit:Q4_K_M_QUANT # Run inference directly in the terminal: llama cli -hf Qapdex/SLM750-Edge-1.58-bit:Q4_K_M_QUANT
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf Qapdex/SLM750-Edge-1.58-bit:Q4_K_M_QUANT # Run inference directly in the terminal: llama cli -hf Qapdex/SLM750-Edge-1.58-bit:Q4_K_M_QUANT
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf Qapdex/SLM750-Edge-1.58-bit:Q4_K_M_QUANT # Run inference directly in the terminal: ./llama-cli -hf Qapdex/SLM750-Edge-1.58-bit:Q4_K_M_QUANT
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf Qapdex/SLM750-Edge-1.58-bit:Q4_K_M_QUANT # Run inference directly in the terminal: ./build/bin/llama-cli -hf Qapdex/SLM750-Edge-1.58-bit:Q4_K_M_QUANT
Use Docker
docker model run hf.co/Qapdex/SLM750-Edge-1.58-bit:Q4_K_M_QUANT
- LM Studio
- Jan
- vLLM
How to use Qapdex/SLM750-Edge-1.58-bit with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Qapdex/SLM750-Edge-1.58-bit" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Qapdex/SLM750-Edge-1.58-bit", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Qapdex/SLM750-Edge-1.58-bit:Q4_K_M_QUANT
- Ollama
How to use Qapdex/SLM750-Edge-1.58-bit with Ollama:
ollama run hf.co/Qapdex/SLM750-Edge-1.58-bit:Q4_K_M_QUANT
- Unsloth Studio
How to use Qapdex/SLM750-Edge-1.58-bit with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for Qapdex/SLM750-Edge-1.58-bit to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for Qapdex/SLM750-Edge-1.58-bit to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for Qapdex/SLM750-Edge-1.58-bit to start chatting
- Docker Model Runner
How to use Qapdex/SLM750-Edge-1.58-bit with Docker Model Runner:
docker model run hf.co/Qapdex/SLM750-Edge-1.58-bit:Q4_K_M_QUANT
- Lemonade
How to use Qapdex/SLM750-Edge-1.58-bit with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull Qapdex/SLM750-Edge-1.58-bit:Q4_K_M_QUANT
Run and chat with the model
lemonade run user.SLM750-Edge-1.58-bit-Q4_K_M_QUANT
List all available models
lemonade list
- Atomic Chat
| set -euo pipefail | |
| REPO_DIR="${1:-$HOME/BitNet}" | |
| PY_SITE="$PREFIX/lib/python3.13/site-packages" | |
| BACKUP_DIR="$REPO_DIR/.backup_no_torch_$(date +%s)" | |
| echo "Working in: $REPO_DIR" | |
| cd "$REPO_DIR" | |
| # 1. Backup wichtiger Dateien | |
| mkdir -p "$BACKUP_DIR" | |
| cp -v requirements.txt "$BACKUP_DIR/" 2>/dev/null || true | |
| cp -v 3rdparty/llama.cpp/requirements.txt "$BACKUP_DIR/" 2>/dev/null || true | |
| echo "Backups saved to $BACKUP_DIR" | |
| # 2. Remove torch lines from any requirements files found | |
| find . -type f -name "requirements*.txt" -o -path "./3rdparty/llama.cpp/requirements.txt" | while read -r f; do | |
| if grep -q "torch" "$f"; then | |
| echo "Patching $f (removing torch entries)" | |
| # create patched copy then replace | |
| grep -v -E "^\s*torch\b" "$f" > "$f.tmp" || true | |
| mv "$f.tmp" "$f" | |
| fi | |
| done | |
| # 3. Install core python deps without torch | |
| echo "Installing Python dependencies (torch excluded)..." | |
| # If repo has top-level requirements.txt | |
| if [ -f requirements.txt ]; then | |
| grep -v "torch" requirements.txt | python3 -m pip install -r /dev/stdin | |
| fi | |
| # Also try llama.cpp requirements if present | |
| if [ -f 3rdparty/llama.cpp/requirements.txt ]; then | |
| grep -v "torch" 3rdparty/llama.cpp/requirements.txt | python3 -m pip install -r /dev/stdin | |
| fi | |
| # 4. Ensure sentencepiece / gguf etc are present | |
| python3 -m pip install --upgrade setuptools wheel pybind11 || true | |
| python3 -m pip install --upgrade gguf sentencepiece protobuf numpy || true | |
| # 5. Optional: create a minimal torch stub to satisfy imports | |
| STUB="${PY_SITE}/torch.py" | |
| if [ ! -f "$STUB" ]; then | |
| echo "Creating minimal torch stub at $STUB" | |
| mkdir -p "$(dirname "$STUB")" | |
| cat > "$STUB" <<'PY' | |
| # Minimal torch stub for environments without real PyTorch. | |
| # Only used to satisfy import checks. Not for real torch functionality. | |
| class _Dummy: | |
| def __getattr__(self, name): | |
| raise ImportError("PyTorch is not installed on this device. This is a stub.") | |
| import types | |
| torch = types.SimpleNamespace() | |
| torch.__version__ = "0+stub" | |
| torch.Tensor = _Dummy | |
| torch.nn = _Dummy | |
| torch.optim = _Dummy | |
| torch.cuda = _Dummy | |
| PY | |
| else | |
| echo "Torch stub already exists at $STUB" | |
| fi | |
| echo "Done. You can now run BitNet without torch. To revert, restore backups from $BACKUP_DIR." | |