Instructions to use Locutusque/TinyMistral-248M with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Locutusque/TinyMistral-248M with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Locutusque/TinyMistral-248M")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Locutusque/TinyMistral-248M") model = AutoModelForCausalLM.from_pretrained("Locutusque/TinyMistral-248M") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use Locutusque/TinyMistral-248M with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Locutusque/TinyMistral-248M" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Locutusque/TinyMistral-248M", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Locutusque/TinyMistral-248M
- SGLang
How to use Locutusque/TinyMistral-248M 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 "Locutusque/TinyMistral-248M" \ --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": "Locutusque/TinyMistral-248M", "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 "Locutusque/TinyMistral-248M" \ --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": "Locutusque/TinyMistral-248M", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use Locutusque/TinyMistral-248M with Docker Model Runner:
docker model run hf.co/Locutusque/TinyMistral-248M
Adding Evaluation Results
#2
by leaderboard-pr-bot - opened
README.md
CHANGED
|
@@ -16,4 +16,17 @@ inference:
|
|
| 16 |
---
|
| 17 |
A pre-trained language model, based on the Mistral 7B model, has been scaled down to approximately 248 million parameters. Currently, this model has been trained on 2,120,000 examples. The batch size will remain low for future epochs. This model isn't intended for direct use but for fine-tuning on a downstream task.
|
| 18 |
|
| 19 |
-
During evaluation on InstructMix, this model achieved an average perplexity score of 6.3. More training sessions are planned for this model.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 16 |
---
|
| 17 |
A pre-trained language model, based on the Mistral 7B model, has been scaled down to approximately 248 million parameters. Currently, this model has been trained on 2,120,000 examples. The batch size will remain low for future epochs. This model isn't intended for direct use but for fine-tuning on a downstream task.
|
| 18 |
|
| 19 |
+
During evaluation on InstructMix, this model achieved an average perplexity score of 6.3. More training sessions are planned for this model.
|
| 20 |
+
# [Open LLM Leaderboard Evaluation Results](https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard)
|
| 21 |
+
Detailed results can be found [here](https://huggingface.co/datasets/open-llm-leaderboard/details_Locutusque__TinyMistral-248m)
|
| 22 |
+
|
| 23 |
+
| Metric | Value |
|
| 24 |
+
|-----------------------|---------------------------|
|
| 25 |
+
| Avg. | 24.18 |
|
| 26 |
+
| ARC (25-shot) | 20.82 |
|
| 27 |
+
| HellaSwag (10-shot) | 26.98 |
|
| 28 |
+
| MMLU (5-shot) | 23.11 |
|
| 29 |
+
| TruthfulQA (0-shot) | 46.89 |
|
| 30 |
+
| Winogrande (5-shot) | 50.75 |
|
| 31 |
+
| GSM8K (5-shot) | 0.0 |
|
| 32 |
+
| DROP (3-shot) | 0.74 |
|