Text Generation
GGUF
English
bitnet
ternary
b1.58
quantization
quantization-aware-training
tinystories
edge
esp32
thox
Instructions to use Thox-ai/ThoxMicro-1bit-9M 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 Thox-ai/ThoxMicro-1bit-9M 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 Thox-ai/ThoxMicro-1bit-9M:Q8_0 # Run inference directly in the terminal: llama cli -hf Thox-ai/ThoxMicro-1bit-9M:Q8_0
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf Thox-ai/ThoxMicro-1bit-9M:Q8_0 # Run inference directly in the terminal: llama cli -hf Thox-ai/ThoxMicro-1bit-9M:Q8_0
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 Thox-ai/ThoxMicro-1bit-9M:Q8_0 # Run inference directly in the terminal: ./llama-cli -hf Thox-ai/ThoxMicro-1bit-9M:Q8_0
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 Thox-ai/ThoxMicro-1bit-9M:Q8_0 # Run inference directly in the terminal: ./build/bin/llama-cli -hf Thox-ai/ThoxMicro-1bit-9M:Q8_0
Use Docker
docker model run hf.co/Thox-ai/ThoxMicro-1bit-9M:Q8_0
- LM Studio
- Jan
- vLLM
How to use Thox-ai/ThoxMicro-1bit-9M with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Thox-ai/ThoxMicro-1bit-9M" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Thox-ai/ThoxMicro-1bit-9M", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Thox-ai/ThoxMicro-1bit-9M:Q8_0
- Ollama
How to use Thox-ai/ThoxMicro-1bit-9M with Ollama:
ollama run hf.co/Thox-ai/ThoxMicro-1bit-9M:Q8_0
- Unsloth Studio
How to use Thox-ai/ThoxMicro-1bit-9M 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 Thox-ai/ThoxMicro-1bit-9M 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 Thox-ai/ThoxMicro-1bit-9M to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for Thox-ai/ThoxMicro-1bit-9M to start chatting
- Docker Model Runner
How to use Thox-ai/ThoxMicro-1bit-9M with Docker Model Runner:
docker model run hf.co/Thox-ai/ThoxMicro-1bit-9M:Q8_0
- Lemonade
How to use Thox-ai/ThoxMicro-1bit-9M with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull Thox-ai/ThoxMicro-1bit-9M:Q8_0
Run and chat with the model
lemonade run user.ThoxMicro-1bit-9M-Q8_0
List all available models
lemonade list
- Atomic Chat
File size: 1,332 Bytes
4aa5e0b | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | # ThoxMicro-1bit-9M — BitNet b1.58 ternary LLM, 8,917,248 params, trained from scratch on TinyStories.
# This is a COMPLETION model. It has no chat template and no instruction tuning.
# Do not add a SYSTEM prompt or a chat-style TEMPLATE — it cannot follow instructions.
FROM ./thoxmicro-1bit-9m.TQ2_0.gguf
# Bare prompt passthrough only. This model is not instruction-tuned, so the
# template must not fake a chat turn or add an assistant role.
TEMPLATE """{{ .Prompt }}"""
# Tiny models degenerate into repetition without a repeat penalty; this is the
# main guard against the model looping on a phrase.
PARAMETER repeat_penalty 1.3
# Stop token. Our own 8k BPE declares <pad>/<bos>/<eos>/<unk> -- NOT the
# GPT-style <|endoftext|>, which appears nowhere in this vocabulary and would
# therefore never fire. Verified against artifacts/ternary/tokenizer-8k.json.
PARAMETER stop "<eos>"
# Modest temperature: low enough to stay coherent, high enough to avoid
# collapsing into the most common token on every step.
PARAMETER temperature 0.8
# Slight top_p truncation trims the long tail of unlikely tokens that a tiny
# model tends to over-weight.
PARAMETER top_p 0.9
# License is UNSETTLED — trained on TinyStories (CDLA-Sharing-1.0). Pending
# confirmation before a LICENSE line is added.
|