Files changed (1) hide show
  1. README.md +52 -40
README.md CHANGED
@@ -1,40 +1,52 @@
1
- ---
2
- license: apache-2.0
3
- license_link: https://huggingface.co/Qwen/Qwen2.5-0.5B-Instruct/blob/main/LICENSE
4
- language:
5
- - en
6
- pipeline_tag: text-generation
7
- base_model: Qwen/Qwen2.5-0.5B-Instruct
8
- tags:
9
- - chat
10
- - mlx
11
- library_name: transformers
12
- ---
13
-
14
- # mlx-community/qwen2.5-0.5b-instruct-q2
15
-
16
- The Model [mlx-community/qwen2.5-0.5b-instruct-q2](https://huggingface.co/mlx-community/qwen2.5-0.5b-instruct-q2) was
17
- converted to MLX format from [Qwen/Qwen2.5-0.5B-Instruct](https://huggingface.co/Qwen/Qwen2.5-0.5B-Instruct)
18
- using mlx-lm version **0.20.5**.
19
-
20
- ## Use with mlx
21
-
22
- ```bash
23
- pip install mlx-lm
24
- ```
25
-
26
- ```python
27
- from mlx_lm import load, generate
28
-
29
- model, tokenizer = load("mlx-community/qwen2.5-0.5b-instruct-q2")
30
-
31
- prompt="hello"
32
-
33
- if hasattr(tokenizer, "apply_chat_template") and tokenizer.chat_template is not None:
34
- messages = [{"role": "user", "content": prompt}]
35
- prompt = tokenizer.apply_chat_template(
36
- messages, tokenize=False, add_generation_prompt=True
37
- )
38
-
39
- response = generate(model, tokenizer, prompt=prompt, verbose=True)
40
- ```
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ license_link: https://huggingface.co/Qwen/Qwen2.5-0.5B-Instruct/blob/main/LICENSE
4
+ language:
5
+ - zho
6
+ - eng
7
+ - fra
8
+ - spa
9
+ - por
10
+ - deu
11
+ - ita
12
+ - rus
13
+ - jpn
14
+ - kor
15
+ - vie
16
+ - tha
17
+ - ara
18
+ pipeline_tag: text-generation
19
+ base_model: Qwen/Qwen2.5-0.5B-Instruct
20
+ tags:
21
+ - chat
22
+ - mlx
23
+ library_name: transformers
24
+ ---
25
+
26
+ # mlx-community/qwen2.5-0.5b-instruct-q2
27
+
28
+ The Model [mlx-community/qwen2.5-0.5b-instruct-q2](https://huggingface.co/mlx-community/qwen2.5-0.5b-instruct-q2) was
29
+ converted to MLX format from [Qwen/Qwen2.5-0.5B-Instruct](https://huggingface.co/Qwen/Qwen2.5-0.5B-Instruct)
30
+ using mlx-lm version **0.20.5**.
31
+
32
+ ## Use with mlx
33
+
34
+ ```bash
35
+ pip install mlx-lm
36
+ ```
37
+
38
+ ```python
39
+ from mlx_lm import load, generate
40
+
41
+ model, tokenizer = load("mlx-community/qwen2.5-0.5b-instruct-q2")
42
+
43
+ prompt="hello"
44
+
45
+ if hasattr(tokenizer, "apply_chat_template") and tokenizer.chat_template is not None:
46
+ messages = [{"role": "user", "content": prompt}]
47
+ prompt = tokenizer.apply_chat_template(
48
+ messages, tokenize=False, add_generation_prompt=True
49
+ )
50
+
51
+ response = generate(model, tokenizer, prompt=prompt, verbose=True)
52
+ ```