-
Notifications
You must be signed in to change notification settings - Fork 151
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create DeepSeek-R1-Tutorial.md #1215
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot reviewed 1 out of 1 changed files in this pull request and generated 3 comments.
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Not 100% sure if my approval will work
Co-authored-by: kunal-vaishnavi <[email protected]>
Co-authored-by: kunal-vaishnavi <[email protected]>
Co-authored-by: kunal-vaishnavi <[email protected]>
## 1. Pre-Requisites: Make a virtual environment and install ONNX Runtime GenAI | ||
```bash | ||
# Installing onnxruntime-genai, olive, and dependencies for CPU | ||
python -m venv .venv && source .venv/bin/activate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we show instructions for a virtual environment using conda
so that a Python version can be specified? The GenAI package is only available for Python 3.10, 3.11, and 3.12 currently.
```bash | ||
#GPU Chat inference. If you pulled the model from huggingface, adjust the model directory (-m) accordingly | ||
curl -o https://raw.githubusercontent.com/microsoft/onnxruntime-genai/refs/heads/main/examples/python/model-chat.py | ||
python model-chat.py -m deepseek-r1-distill-qwen-1.5B/model -e cpu --chat_template "<|begin▁of▁sentence|><|User|>{input}<|Assistant|>" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
python model-chat.py -m deepseek-r1-distill-qwen-1.5B/model -e cpu --chat_template "<|begin▁of▁sentence|><|User|>{input}<|Assistant|>" | |
python model-chat.py -m deepseek-r1-distill-qwen-1.5B/model -e cuda --chat_template "<|begin▁of▁sentence|><|User|>{input}<|Assistant|>" |
``` | ||
|
||
```bash | ||
#GPU Chat inference. If you pulled the model from huggingface, adjust the model directory (-m) accordingly |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#GPU Chat inference. If you pulled the model from huggingface, adjust the model directory (-m) accordingly | |
# GPU Chat inference. If you pulled the model from huggingface, adjust the model directory (-m) accordingly |
|
||
## 3. Play with your model on device! | ||
```bash | ||
#CPU Chat inference. If you pulled the model from huggingface, adjust the model directory (-m) accordingly |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#CPU Chat inference. If you pulled the model from huggingface, adjust the model directory (-m) accordingly | |
# CPU Chat inference. If you pulled the model from huggingface, adjust the model directory (-m) accordingly |
Tutorial for Deepseek run