Instructions to use Tiiny/TurboSparse-Mistral-Instruct with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Tiiny/TurboSparse-Mistral-Instruct with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("feature-extraction", model="Tiiny/TurboSparse-Mistral-Instruct", trust_remote_code=True)# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("Tiiny/TurboSparse-Mistral-Instruct", trust_remote_code=True, dtype="auto") - Notebooks
- Google Colab
- Kaggle
problems about sample strategies
#1
by thuzhizhi - opened
In generation_config file, it says that
{
"do_sample": true,
"max_new_tokens": 4096,
"temperature": 0.0,
"transformers_version": "4.41.0"
}
However, I went into error message that says
ValueError: `temperature` (=0.0) has to be a strictly positive float, otherwise your next token scores will be invalid. If you're looking for greedy decoding strategies, set `do_sample=False`.
I want to know if the default setting is wrong?
Thank you for your help!
Thanks for your feedback. Actually you can set the do_sample to false to solve this problem.