Text Generation
Transformers
Safetensors
mistral
mergekit
Merge
ties
medical
biology
conversational
text-generation-inference
Instructions to use BioMistral/BioMistral-7B-TIES with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use BioMistral/BioMistral-7B-TIES with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="BioMistral/BioMistral-7B-TIES") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("BioMistral/BioMistral-7B-TIES") model = AutoModelForCausalLM.from_pretrained("BioMistral/BioMistral-7B-TIES") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use BioMistral/BioMistral-7B-TIES with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "BioMistral/BioMistral-7B-TIES" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "BioMistral/BioMistral-7B-TIES", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/BioMistral/BioMistral-7B-TIES
- SGLang
How to use BioMistral/BioMistral-7B-TIES 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 "BioMistral/BioMistral-7B-TIES" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "BioMistral/BioMistral-7B-TIES", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'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 "BioMistral/BioMistral-7B-TIES" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "BioMistral/BioMistral-7B-TIES", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use BioMistral/BioMistral-7B-TIES with Docker Model Runner:
docker model run hf.co/BioMistral/BioMistral-7B-TIES
Adding Evaluation Results
Browse filesThis is an automated PR created with https://huggingface.co/spaces/Weyaxi/open-llm-leaderboard-results-pr
The purpose of this PR is to add evaluation results from the Open LLM Leaderboard to your model card.
If you encounter any issues, please report them to https://huggingface.co/spaces/Weyaxi/open-llm-leaderboard-results-pr/discussions
README.md
CHANGED
|
@@ -1,17 +1,4 @@
|
|
| 1 |
---
|
| 2 |
-
base_model:
|
| 3 |
-
- mistralai/Mistral-7B-Instruct-v0.1
|
| 4 |
-
- BioMistral/BioMistral-7B
|
| 5 |
-
library_name: transformers
|
| 6 |
-
tags:
|
| 7 |
-
- mergekit
|
| 8 |
-
- merge
|
| 9 |
-
- ties
|
| 10 |
-
- medical
|
| 11 |
-
- biology
|
| 12 |
-
license: apache-2.0
|
| 13 |
-
datasets:
|
| 14 |
-
- pubmed
|
| 15 |
language:
|
| 16 |
- fr
|
| 17 |
- en
|
|
@@ -21,7 +8,123 @@ language:
|
|
| 21 |
- ro
|
| 22 |
- de
|
| 23 |
- nl
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24 |
pipeline_tag: text-generation
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 25 |
---
|
| 26 |
# BioMistral-7B-mistral7instruct-ties
|
| 27 |
|
|
@@ -147,3 +250,17 @@ Arxiv : [https://arxiv.org/abs/2402.10373](https://arxiv.org/abs/2402.10373)
|
|
| 147 |
|
| 148 |
**CAUTION!** Both direct and downstream users need to be informed about the risks, biases, and constraints inherent in the model. While the model can produce natural language text, our exploration of its capabilities and limitations is just beginning. In fields such as medicine, comprehending these limitations is crucial. Hence, we strongly advise against deploying this model for natural language generation in production or for professional tasks in the realm of health and medicine.
|
| 149 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 2 |
language:
|
| 3 |
- fr
|
| 4 |
- en
|
|
|
|
| 8 |
- ro
|
| 9 |
- de
|
| 10 |
- nl
|
| 11 |
+
license: apache-2.0
|
| 12 |
+
library_name: transformers
|
| 13 |
+
tags:
|
| 14 |
+
- mergekit
|
| 15 |
+
- merge
|
| 16 |
+
- ties
|
| 17 |
+
- medical
|
| 18 |
+
- biology
|
| 19 |
+
datasets:
|
| 20 |
+
- pubmed
|
| 21 |
+
base_model:
|
| 22 |
+
- mistralai/Mistral-7B-Instruct-v0.1
|
| 23 |
+
- BioMistral/BioMistral-7B
|
| 24 |
pipeline_tag: text-generation
|
| 25 |
+
model-index:
|
| 26 |
+
- name: BioMistral-7B-TIES
|
| 27 |
+
results:
|
| 28 |
+
- task:
|
| 29 |
+
type: text-generation
|
| 30 |
+
name: Text Generation
|
| 31 |
+
dataset:
|
| 32 |
+
name: AI2 Reasoning Challenge (25-Shot)
|
| 33 |
+
type: ai2_arc
|
| 34 |
+
config: ARC-Challenge
|
| 35 |
+
split: test
|
| 36 |
+
args:
|
| 37 |
+
num_few_shot: 25
|
| 38 |
+
metrics:
|
| 39 |
+
- type: acc_norm
|
| 40 |
+
value: 55.46
|
| 41 |
+
name: normalized accuracy
|
| 42 |
+
source:
|
| 43 |
+
url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=BioMistral/BioMistral-7B-TIES
|
| 44 |
+
name: Open LLM Leaderboard
|
| 45 |
+
- task:
|
| 46 |
+
type: text-generation
|
| 47 |
+
name: Text Generation
|
| 48 |
+
dataset:
|
| 49 |
+
name: HellaSwag (10-Shot)
|
| 50 |
+
type: hellaswag
|
| 51 |
+
split: validation
|
| 52 |
+
args:
|
| 53 |
+
num_few_shot: 10
|
| 54 |
+
metrics:
|
| 55 |
+
- type: acc_norm
|
| 56 |
+
value: 79.59
|
| 57 |
+
name: normalized accuracy
|
| 58 |
+
source:
|
| 59 |
+
url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=BioMistral/BioMistral-7B-TIES
|
| 60 |
+
name: Open LLM Leaderboard
|
| 61 |
+
- task:
|
| 62 |
+
type: text-generation
|
| 63 |
+
name: Text Generation
|
| 64 |
+
dataset:
|
| 65 |
+
name: MMLU (5-Shot)
|
| 66 |
+
type: cais/mmlu
|
| 67 |
+
config: all
|
| 68 |
+
split: test
|
| 69 |
+
args:
|
| 70 |
+
num_few_shot: 5
|
| 71 |
+
metrics:
|
| 72 |
+
- type: acc
|
| 73 |
+
value: 56.29
|
| 74 |
+
name: accuracy
|
| 75 |
+
source:
|
| 76 |
+
url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=BioMistral/BioMistral-7B-TIES
|
| 77 |
+
name: Open LLM Leaderboard
|
| 78 |
+
- task:
|
| 79 |
+
type: text-generation
|
| 80 |
+
name: Text Generation
|
| 81 |
+
dataset:
|
| 82 |
+
name: TruthfulQA (0-shot)
|
| 83 |
+
type: truthful_qa
|
| 84 |
+
config: multiple_choice
|
| 85 |
+
split: validation
|
| 86 |
+
args:
|
| 87 |
+
num_few_shot: 0
|
| 88 |
+
metrics:
|
| 89 |
+
- type: mc2
|
| 90 |
+
value: 52.2
|
| 91 |
+
source:
|
| 92 |
+
url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=BioMistral/BioMistral-7B-TIES
|
| 93 |
+
name: Open LLM Leaderboard
|
| 94 |
+
- task:
|
| 95 |
+
type: text-generation
|
| 96 |
+
name: Text Generation
|
| 97 |
+
dataset:
|
| 98 |
+
name: Winogrande (5-shot)
|
| 99 |
+
type: winogrande
|
| 100 |
+
config: winogrande_xl
|
| 101 |
+
split: validation
|
| 102 |
+
args:
|
| 103 |
+
num_few_shot: 5
|
| 104 |
+
metrics:
|
| 105 |
+
- type: acc
|
| 106 |
+
value: 73.72
|
| 107 |
+
name: accuracy
|
| 108 |
+
source:
|
| 109 |
+
url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=BioMistral/BioMistral-7B-TIES
|
| 110 |
+
name: Open LLM Leaderboard
|
| 111 |
+
- task:
|
| 112 |
+
type: text-generation
|
| 113 |
+
name: Text Generation
|
| 114 |
+
dataset:
|
| 115 |
+
name: GSM8k (5-shot)
|
| 116 |
+
type: gsm8k
|
| 117 |
+
config: main
|
| 118 |
+
split: test
|
| 119 |
+
args:
|
| 120 |
+
num_few_shot: 5
|
| 121 |
+
metrics:
|
| 122 |
+
- type: acc
|
| 123 |
+
value: 0.23
|
| 124 |
+
name: accuracy
|
| 125 |
+
source:
|
| 126 |
+
url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=BioMistral/BioMistral-7B-TIES
|
| 127 |
+
name: Open LLM Leaderboard
|
| 128 |
---
|
| 129 |
# BioMistral-7B-mistral7instruct-ties
|
| 130 |
|
|
|
|
| 250 |
|
| 251 |
**CAUTION!** Both direct and downstream users need to be informed about the risks, biases, and constraints inherent in the model. While the model can produce natural language text, our exploration of its capabilities and limitations is just beginning. In fields such as medicine, comprehending these limitations is crucial. Hence, we strongly advise against deploying this model for natural language generation in production or for professional tasks in the realm of health and medicine.
|
| 252 |
|
| 253 |
+
|
| 254 |
+
# [Open LLM Leaderboard Evaluation Results](https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard)
|
| 255 |
+
Detailed results can be found [here](https://huggingface.co/datasets/open-llm-leaderboard/details_BioMistral__BioMistral-7B-TIES)
|
| 256 |
+
|
| 257 |
+
| Metric |Value|
|
| 258 |
+
|---------------------------------|----:|
|
| 259 |
+
|Avg. |52.91|
|
| 260 |
+
|AI2 Reasoning Challenge (25-Shot)|55.46|
|
| 261 |
+
|HellaSwag (10-Shot) |79.59|
|
| 262 |
+
|MMLU (5-Shot) |56.29|
|
| 263 |
+
|TruthfulQA (0-shot) |52.20|
|
| 264 |
+
|Winogrande (5-shot) |73.72|
|
| 265 |
+
|GSM8k (5-shot) | 0.23|
|
| 266 |
+
|