Instructions to use Tiiny/SmallThinker-21BA3B-Instruct with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Tiiny/SmallThinker-21BA3B-Instruct with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Tiiny/SmallThinker-21BA3B-Instruct")# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("Tiiny/SmallThinker-21BA3B-Instruct", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Tiiny/SmallThinker-21BA3B-Instruct with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Tiiny/SmallThinker-21BA3B-Instruct" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Tiiny/SmallThinker-21BA3B-Instruct", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Tiiny/SmallThinker-21BA3B-Instruct
- SGLang
How to use Tiiny/SmallThinker-21BA3B-Instruct with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "Tiiny/SmallThinker-21BA3B-Instruct" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Tiiny/SmallThinker-21BA3B-Instruct", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "Tiiny/SmallThinker-21BA3B-Instruct" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Tiiny/SmallThinker-21BA3B-Instruct", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use Tiiny/SmallThinker-21BA3B-Instruct with Docker Model Runner:
docker model run hf.co/Tiiny/SmallThinker-21BA3B-Instruct
Commit History
-
Improve model card: Add paper title and abstract (#4)
Yixin Song +1: nielsrVerified signature- Improve model card: Add paper title and abstract (6d471e8fe96a8d8e7cba94d136318a792d157ca7) Co-authored-by: Niels Rogge <nielsr@users.noreply.huggingface.co>9df52ed
-
Improve model card: Add library, paper, GitHub links, and MoE tag (#2)
Yixin Song +1: nielsrVerified signature- Improve model card: Add library, paper, GitHub links, and MoE tag (359ea43473315fcd041f9c7f1b72e5b14b05555a) Co-authored-by: Niels Rogge <nielsr@users.noreply.huggingface.co>0ad4904
-
Update README.md
Yixin SongVerified signatureb5bd753 -
Update README.md
Yixin SongVerified signature8c5b3a3
-
Update README.md
Yixin SongVerified signature7883805
-
Update README.md
Verified signatureeddd5e2 -
Update README.md
Verified signature45e4585 -
Update README.md
Verified signaturefe1da60 -
Update README.md
Yixin SongVerified signature109a2c4 -
Update README.md
Yixin SongVerified signatureeb58b5c -
Update README.md
Yixin SongVerified signature9b05bde -
Update README.md
Yixin SongVerified signatureb95a223 -
Update README.md
Verified signatureeeda259 -
Update README.md
Verified signature0c1dea5 -
Update README.md
Verified signature3abcff8 -
Update README.md
Verified signatured2557f8 -
Update README.md
Verified signaturee726dc8 -
Update README.md
Yixin SongVerified signaturebcd1a1f -
Update README.md
Yixin SongVerified signature4859198 -
Update README.md
Verified signatureb87c829 -
Update README.md
Yixin SongVerified signature5f20f2f -
Update README.md
Yixin SongVerified signature003b904 -
Upload model_lm_head.pt with huggingface_hub
Yixin SongVerified signature92c4144 -
Upload model-00003-of-00009.safetensors with huggingface_hub
Verified signatured7ef047 -
Upload model-00004-of-00009.safetensors with huggingface_hub
Verified signature9096ac6 -
Upload model-00005-of-00009.safetensors with huggingface_hub
Verified signatureaa89d6f -
Upload model-00006-of-00009.safetensors with huggingface_hub
Verified signature787be73 -
Upload model-00007-of-00009.safetensors with huggingface_hub
Verified signature1d1e6d6 -
Upload model-00008-of-00009.safetensors with huggingface_hub
Verified signatureef0fb1c -
Upload model-00009-of-00009.safetensors with huggingface_hub
Verified signature41e16d0 -
upload weight
yixinsongc801fda -
upload weight
yixinsongf547afd -
minor
yixinsongbfd2371 -
upload
yixinsonge36ff24
-
minor
yixinsongac8cfe2 -
upload config
yixinsong1040800 -
initial commit
Yixin SongVerified signature3bfc484