Instructions to use SupraLabs/Supra-Router-51M with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use SupraLabs/Supra-Router-51M with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="SupraLabs/Supra-Router-51M")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("SupraLabs/Supra-Router-51M") model = AutoModelForCausalLM.from_pretrained("SupraLabs/Supra-Router-51M") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use SupraLabs/Supra-Router-51M with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "SupraLabs/Supra-Router-51M" # 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-Router-51M", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/SupraLabs/Supra-Router-51M
- SGLang
How to use SupraLabs/Supra-Router-51M 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-Router-51M" \ --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-Router-51M", "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-Router-51M" \ --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-Router-51M", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use SupraLabs/Supra-Router-51M with Docker Model Runner:
docker model run hf.co/SupraLabs/Supra-Router-51M
How did you determine the sequence length
What other options of paths did you check, any with conditional branching?
We did not do anything serious with this model.
@LH-Tech-AI made a simple model for our (and your apps) so that some could exist
This is mainly for SupraCode, but we are working on a better one π€π
PS: it can only accept one prompt, and it will generate the routing metadata!
Do you have any plans on releasing a serious version of this model? Not sure why this user prompt failed.
summarize text
Supra-Router-51M is an ultra-lightweight, high-speed infrastructure traffic controller optimized for localized edge orchestration.
With only 51.7 million parameters, this micro-LLM acts as a defensive gateway for multi-model ecosystems, accurately determining
when user requests can be processed locally by an Edge SLM or when they must be triaged to a cloud-hosted frontier intelligence layer.
The model was built by fine-tuning a pre-trained 51M base on the SupraLabs/Prompt-Routing-Dataset (992 rows). Rather than acting
as a naive binary classifier, the model uses Multi-Task Sequence Generation to map out the underlying properties of a prompt before
predicting the final routing token, anchoring its attention heads to robust language and structural logic features.
Domain: Content Creation | Complexity: 4 | Math: False | Code: True | Route: big model | Justification: Automated override: Task complexity is high (4) or involves technical logic (Math: False, Code: True), requiring frontier capabilities.
I mean, edge models should be able to handle that.
Do you have any plans on releasing a serious version of this model? Not sure why this user prompt failed.
wdym serious version lol
wdym serious version lol
@AxionLab-Official Well I was reading the above comment which made it look like this model is basically a toy and not ready for primetime.
We did not do anything serious with this model.
@LH-Tech-AI made a simple model for our (and your apps) so that some could exist
Also take a look at the analysis that I did. The classification seems a bit off.
I would say that this model is conceptually a great idea