mrm8488 commited on
Commit
fa2e30d
1 Parent(s): 6966568

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +17 -0
README.md CHANGED
@@ -5,6 +5,7 @@ tags:
5
  - coding
6
  - phi-2
7
  - phi2
 
8
  model-index:
9
  - name: phi-2-coder
10
  results: []
@@ -128,6 +129,22 @@ instruction = "Design a class for representing a person in Python."
128
  print(generate(instruction))
129
  ```
130
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
131
 
132
  ### Citation
133
  ```
 
5
  - coding
6
  - phi-2
7
  - phi2
8
+ - mlx
9
  model-index:
10
  - name: phi-2-coder
11
  results: []
 
129
  print(generate(instruction))
130
  ```
131
 
132
+ ### How to use with [MLX](https://github.com/ml-explore/mlx).
133
+
134
+ ```bash
135
+ # Install mlx, mlx-examples, huggingface-cli
136
+ pip install mlx
137
+ pip install huggingface_hub hf_transfer
138
+ git clone https://github.com/ml-explore/mlx-examples.git
139
+
140
+ # Download model
141
+ export HF_HUB_ENABLE_HF_TRANSFER=1
142
+ huggingface-cli download --local-dir phi-2-coder mrm8488/phi-2-coder
143
+
144
+ # Run example
145
+ python mlx-examples/llms/phi2.py --model-path phi-2-coder --prompt "Design a class for representing a person in Python"
146
+ ```
147
+
148
 
149
  ### Citation
150
  ```