Text Generation
Transformers
Safetensors
PyTorch
English
slm
medical
healthcare
supervised-fine-tuning
clinical-reasoning
Instructions to use aman0419/Vitallm-50M with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use aman0419/Vitallm-50M with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="aman0419/Vitallm-50M")# Load model directly from transformers import SLM model = SLM.from_pretrained("aman0419/Vitallm-50M", dtype="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use aman0419/Vitallm-50M with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "aman0419/Vitallm-50M" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "aman0419/Vitallm-50M", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/aman0419/Vitallm-50M
- SGLang
How to use aman0419/Vitallm-50M 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 "aman0419/Vitallm-50M" \ --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": "aman0419/Vitallm-50M", "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 "aman0419/Vitallm-50M" \ --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": "aman0419/Vitallm-50M", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use aman0419/Vitallm-50M with Docker Model Runner:
docker model run hf.co/aman0419/Vitallm-50M
Update README.md
Browse files
README.md
CHANGED
|
@@ -114,12 +114,11 @@ Before running any code, you need the following files. Download them directly fr
|
|
| 114 |
|
| 115 |
| File | Source | Description |
|
| 116 |
|:---|:---|:---|
|
| 117 |
-
| `vital_lm_50m_sft_weights.pt` | [Hugging Face](https://huggingface.co/aman0419/Vitallm-50M-Instruct) | Model weights (SFT) |
|
| 118 |
| `model.py` | [GitHub](https://github.com/Aman041902/VitalLM-50M/blob/main/model.py) | Custom model architecture |
|
| 119 |
| `vocab_50m.json` | [Hugging Face](https://huggingface.co/aman0419/Vitallm-50M-Instruct) | Tokenizer vocabulary |
|
| 120 |
| `merges_50m.txt` | [Hugging Face](https://huggingface.co/aman0419/Vitallm-50M-Instruct) | BPE merge rules |
|
| 121 |
|
| 122 |
-
> ⚠️ All
|
| 123 |
|
| 124 |
---
|
| 125 |
|
|
|
|
| 114 |
|
| 115 |
| File | Source | Description |
|
| 116 |
|:---|:---|:---|
|
|
|
|
| 117 |
| `model.py` | [GitHub](https://github.com/Aman041902/VitalLM-50M/blob/main/model.py) | Custom model architecture |
|
| 118 |
| `vocab_50m.json` | [Hugging Face](https://huggingface.co/aman0419/Vitallm-50M-Instruct) | Tokenizer vocabulary |
|
| 119 |
| `merges_50m.txt` | [Hugging Face](https://huggingface.co/aman0419/Vitallm-50M-Instruct) | BPE merge rules |
|
| 120 |
|
| 121 |
+
> ⚠️ All files must be present in the **same working directory** before running inference. `model.py` contains the custom `SLM` and `SLMConfig` classes which are not available in the standard `transformers` library and cannot be skipped.
|
| 122 |
|
| 123 |
---
|
| 124 |
|