Text Generation
Transformers
Safetensors
English
llama
small
cpu
supra
v4
tiny
mini
open
open-source
text-generation-inference
Instructions to use SupraLabs/Supra-Mini-v4-2M with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use SupraLabs/Supra-Mini-v4-2M with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="SupraLabs/Supra-Mini-v4-2M")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("SupraLabs/Supra-Mini-v4-2M") model = AutoModelForCausalLM.from_pretrained("SupraLabs/Supra-Mini-v4-2M", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use SupraLabs/Supra-Mini-v4-2M with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "SupraLabs/Supra-Mini-v4-2M" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "SupraLabs/Supra-Mini-v4-2M", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/SupraLabs/Supra-Mini-v4-2M
- SGLang
How to use SupraLabs/Supra-Mini-v4-2M 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 "SupraLabs/Supra-Mini-v4-2M" \ --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": "SupraLabs/Supra-Mini-v4-2M", "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 "SupraLabs/Supra-Mini-v4-2M" \ --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": "SupraLabs/Supra-Mini-v4-2M", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use SupraLabs/Supra-Mini-v4-2M with Docker Model Runner:
docker model run hf.co/SupraLabs/Supra-Mini-v4-2M
Commit History
-
Delete training_args.bin
Verified signature18c56ed
-
Update README.md
Verified signature1a23871
-
Update README.md
Verified signature5a1a8f5 -
Upload 6 files
Verified signaturedbb4d5b -
Update config.json
Verified signature274c8f4 -
Update README.md
Verified signaturebf1bea9
-
Update README.md
Verified signaturecc38ce4 -
Update README.md
Verified signature5c33dbd -
Update readme.md, fix vocab (8192 -> 4096) (#3)
- Update readme.md, fix vocab (8192 -> 4096) (f6a7b5386b746a48a310a2287a82dea027d0b13b) Co-authored-by: Dan P <Datdanboi25@users.noreply.huggingface.co>06d9b0d
-
Update README.md
Verified signature74d1409
-
Update tokenizer_config.json
Verified signature6f975a2 -
Update tokenizer_config.json
Verified signature63ef59a -
Update tokenizer_config.json
Verified signature304b570 -
Update tokenizer_config.json
Verified signaturee56571f -
Update README.md
Verified signature5aa1cce
-
Create train_tokenizer.py
Verified signaturea5e8634 -
Update README.md
Verified signature77bdd2a -
Upload 9 files
Verified signature208972d -
Update README.md
Verified signatured999f97 -
Update README.md
Verified signature4d8695c -
Create README.md
Verified signature5c71983 -
initial commit
Verified signature60adf7e