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.
- Libraries
- llama-cpp-python
How to use Qapdex/SLM750-Edge-1.58-bit with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="Qapdex/SLM750-Edge-1.58-bit", filename="quantized_q4km.gguf", )
output = llm( "Once upon a time,", max_tokens=512, echo=True ) print(output)
- 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
- Atomic Chat new
- 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
| set -euo pipefail | |
| LOGFILE="$HOME/bitnet_install_$(date +%Y%m%d_%H%M%S).log" | |
| exec > >(awk '{ print strftime("[%Y-%m-%d %H:%M:%S]"), $0; fflush(); }' | tee -a "$LOGFILE") 2>&1 | |
| echo "=== BitNet Auto-Installer gestartet ===" | |
| echo "Logdatei: $LOGFILE" | |
| echo | |
| # --- System prep. --- | |
| pkg update -y && pkg upgrade -y | |
| pkg install clang cmake make git pkg-config python libffi openssl freetype libpng libjpeg-turbo zlib ninja rust moreutils -y | |
| ln -sf /system/lib64/liblog.so $PREFIX/lib/liblog.so 2>/dev/null || true | |
| export LDFLAGS="-llog" | |
| export CXXFLAGS="-fPIC" | |
| export PKG_CONFIG_PATH="$PREFIX/lib/pkgconfig:$PKG_CONFIG_PATH" | |
| # --- Python-Toolchain --- | |
| python3 -m pip install --upgrade setuptools wheel build pybind11 | |
| # --- SentencePiece Build --- | |
| echo "=== Building SentencePiece ===" | |
| python3 -m pip uninstall -y sentencepiece || true | |
| python3 -m pip install --no-binary=:all: sentencepiece -v | |
| # --- Verify Sentencepiece Build --- | |
| python3 -c "import sentencepiece, sys; print('SentencePiece Version:', getattr(sentencepiece,'__version__','unknown'))" | |
| # --- .pc-Files if necessary --- | |
| SPM_PC="$PREFIX/lib/pkgconfig/sentencepiece.pc" | |
| if [ ! -f "$SPM_PC" ]; then | |
| echo "Erstelle fehlende sentencepiece.pc..." | |
| mkdir -p "$(dirname "$SPM_PC")" | |
| cat > "$SPM_PC" <<'EOF' | |
| prefix=/data/data/com.termux/files/usr | |
| exec_prefix=${prefix} | |
| libdir=${exec_prefix}/lib | |
| includedir=${prefix}/include | |
| Name: sentencepiece | |
| Description: SentencePiece library | |
| Version: 0.2.1 | |
| Libs: -L${libdir} -lsentencepiece | |
| Cflags: -I${includedir} | |
| EOF | |
| fi | |
| # --- gguf-py Build --- | |
| echo "=== Baue gguf-py ===" | |
| cd ~/BitNet/3rdparty/llama.cpp/gguf-py | |
| python3 -m pip install -v || { | |
| echo "Fehler beim gguf-py Build, versuche Workaround..." | |
| export CMAKE_PREFIX_PATH="$PREFIX/lib/python3.13/site-packages/sentencepiece" | |
| python3 -m pip install -v | |
| } | |
| # --- BitNet Setup --- | |
| echo "=== Setup BitNet Umgebung ===" | |
| cd ~/BitNet | |
| python3 setup_env.py || echo "setup_env.py meldete Warnungen, prüfe Logdatei." | |
| # --- Finish Setup --- | |
| echo "=== Installation ===" | |
| python3 -c "import sentencepiece; print('SentencePiece OK:', sentencepiece.__file__)" | |
| python3 -c "import gguf; print('gguf OK:', gguf.__file__)" | |
| echo "Logdatei gespeichert unter: $LOGFILE" | |
| echo "=== Done ===" | |