Downloads · 30 days
14
4% of all-time downloads
typeof/neural-chat-7b-v3-1-sharded
neural-chat-7b-v3-1-sharded is a text generation model from typeof. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as apache-2.0.
This model is a fine-tuned model based on mistralai/Mistral-7B-v0.1 on the open source dataset Open-Orca/SlimOrca. Then we align it with DPO algorithm. For more details, you can refer our blog: The Practice of Supervi…
Downloads · 30 days
14
4% of all-time downloads
All-time downloads
339
Public
Parameters
7.2B
14.5 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors14.5 GB · 100%
From the Hugging Face model README
This model is a fine-tuned model based on mistralai/Mistral-7B-v0.1 on the open source dataset Open-Orca/SlimOrca. Then we align it with DPO algorithm. For more details, you can refer our blog: The Practice of Supervised Fine-tuning and Direct Preference Optimization on Habana Gaudi2.
Neural-chat-7b-v3-1 was trained between September and October, 2023.
We submit our model to open_llm_leaderboard, and the model performance has been improved significantly as we see from the average metric of 7 tasks from the leaderboard.
| Model | Average ⬆️ | ARC (25-s) ⬆️ | HellaSwag (10-s) ⬆️ | MMLU (5-s) ⬆️ | TruthfulQA (MC) (0-s) ⬆️ | Winogrande (5-s) | GSM8K (5-s) | DROP (3-s) |
|---|---|---|---|---|---|---|---|---|
| mistralai/Mistral-7B-v0.1 | 50.32 | 59.58 | 83.31 | 64.16 | 42.15 | 78.37 | 18.12 | 6.14 |
| Intel/neural-chat-7b-v3 | 57.31 | 67.15 | 83.29 | 62.26 | 58.77 | 78.06 | 1.21 | 50.43 |
| Intel/neural-chat-7b-v3-1 | 59.06 | 66.21 | 83.64 | 62.37 | 59.65 | 78.14 | 19.56 | 43.84 |
The following hyperparameters were used during training:
Here is the sample code to reproduce the model: Sample Code.
### System:
{system}
### User:
{usr}
### Assistant:
import transformers
model_name = 'Intel/neural-chat-7b-v3-1'
model = transformers.AutoModelForCausalLM.from_pretrained(model_name)
tokenizer = transformers.AutoTokenizer.from_pretrained(model_name)
def generate_response(system_input, user_input):
# Format the input using the provided template
prompt = f"### System:\n{system_input}\n### User:\n{user_input}\n### Assistant:\n"
# Tokenize and encode the prompt
inputs = tokenizer.encode(prompt, return_tensors="pt")
# Generate a response
outputs = model.generate(inputs, max_length=1000, num_return_sequences=1)
response = tokenizer.decode(outputs[0], skip_special_tokens=True)
# Extract only the assistant's response
return response.split("### Assistant:\n")[-1]
# Example usage
system_input = "You are a chatbot developed by Intel. Please answer all questions to the best of your ability."
user_input = "How does the neural-chat-7b-v3-1 model work?"
response = generate_response(system_input, user_input)
print(response)
neural-chat-7b-v3-1 can produce factually incorrect output, and should not be relied on to produce factually accurate information. neural-chat-7b-v3-1 was trained on Open-Orca/SlimOrca based on mistralai/Mistral-7B-v0.1. Because of the limitations of the pretrained model and the finetuning datasets, it is possible that this model could generate lewd, biased or otherwise offensive outputs.
Therefore, before deploying any applications of neural-chat-7b-v3-1, developers should perform safety testing.
The license on this model does not constitute legal advice. We are not responsible for the actions of third parties who use this model. Please cosult an attorney before using this model for commercial purposes.
The NeuralChat team with members from Intel/DCAI/AISE/AIPT. Core team members: Kaokao Lv, Liang Lv, Chang Wang, Wenxin Zhang, Xuhui Ren, and Haihao Shen.
Detailed results can be found here
| Metric | Value |
|---|---|
| Avg. | 59.06 |
| ARC (25-shot) | 66.21 |
| HellaSwag (10-shot) | 83.64 |
| MMLU (5-shot) | 62.37 |
| TruthfulQA (0-shot) | 59.65 |
| Winogrande (5-shot) | 78.14 |
| GSM8K (5-shot) | 19.56 |
| DROP (3-shot) | 43.84 |