Instructions to use CodeSoft/sorbet-25m with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use CodeSoft/sorbet-25m with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="CodeSoft/sorbet-25m")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("CodeSoft/sorbet-25m") model = AutoModelForCausalLM.from_pretrained("CodeSoft/sorbet-25m", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use CodeSoft/sorbet-25m with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "CodeSoft/sorbet-25m" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "CodeSoft/sorbet-25m", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/CodeSoft/sorbet-25m
- SGLang
How to use CodeSoft/sorbet-25m 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 "CodeSoft/sorbet-25m" \ --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": "CodeSoft/sorbet-25m", "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 "CodeSoft/sorbet-25m" \ --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": "CodeSoft/sorbet-25m", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use CodeSoft/sorbet-25m with Docker Model Runner:
docker model run hf.co/CodeSoft/sorbet-25m
Add hfviewer architecture card
Browse filesEmbed the hfviewer architecture visualization card in README.md.
README.md
CHANGED
|
@@ -16,6 +16,16 @@ library_name: transformers
|
|
| 16 |
|
| 17 |
# Sorbet-25M
|
| 18 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 19 |
From-scratch ~25M-parameter Qwen2-style decoder LM trained in under 4h on a single RTX 5060 Ti (16GB).
|
| 20 |
|
| 21 |
## Architecture
|
|
|
|
| 16 |
|
| 17 |
# Sorbet-25M
|
| 18 |
|
| 19 |
+
## Architecture graph
|
| 20 |
+
|
| 21 |
+
<a href="https://hfviewer.com/CodeSoft/sorbet-25m?utm_source=huggingface&utm_medium=embedded_model_card&utm_campaign=CodeSoft_sorbet-25m_card" target="_blank" rel="noopener">
|
| 22 |
+
<img
|
| 23 |
+
src="https://hfviewer.com/api/card.svg?source=CodeSoft%2Fsorbet-25m&granularity=0"
|
| 24 |
+
alt="Architecture graph for CodeSoft/sorbet-25m. Open in hfviewer"
|
| 25 |
+
width="100%"
|
| 26 |
+
/>
|
| 27 |
+
</a>
|
| 28 |
+
|
| 29 |
From-scratch ~25M-parameter Qwen2-style decoder LM trained in under 4h on a single RTX 5060 Ti (16GB).
|
| 30 |
|
| 31 |
## Architecture
|