reach-vb HF staff commited on
Commit
8ee9f99
1 Parent(s): 7265b81

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +47 -0
README.md ADDED
@@ -0,0 +1,47 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ base_model: TinyLlama/TinyLlama-1.1B-Chat-v1.0
3
+ datasets:
4
+ - cerebras/SlimPajama-627B
5
+ - bigcode/starcoderdata
6
+ - HuggingFaceH4/ultrachat_200k
7
+ - HuggingFaceH4/ultrafeedback_binarized
8
+ language:
9
+ - en
10
+ license: apache-2.0
11
+ tags:
12
+ - mlx
13
+ widget:
14
+ - example_title: Fibonacci (Python)
15
+ messages:
16
+ - role: system
17
+ content: You are a chatbot who can help code!
18
+ - role: user
19
+ content: Write me a function to calculate the first 10 digits of the fibonacci
20
+ sequence in Python and print it out to the CLI.
21
+ ---
22
+
23
+ # reach-vb/TinyLlama-1.1B-Chat-v1.0-Q4-mlx
24
+
25
+ The Model [reach-vb/TinyLlama-1.1B-Chat-v1.0-Q4-mlx](https://huggingface.co/reach-vb/TinyLlama-1.1B-Chat-v1.0-Q4-mlx) was converted to MLX format from [TinyLlama/TinyLlama-1.1B-Chat-v1.0](https://huggingface.co/TinyLlama/TinyLlama-1.1B-Chat-v1.0) using mlx-lm version **0.19.1**.
26
+
27
+ ## Use with mlx
28
+
29
+ ```bash
30
+ pip install mlx-lm
31
+ ```
32
+
33
+ ```python
34
+ from mlx_lm import load, generate
35
+
36
+ model, tokenizer = load("reach-vb/TinyLlama-1.1B-Chat-v1.0-Q4-mlx")
37
+
38
+ prompt="hello"
39
+
40
+ if hasattr(tokenizer, "apply_chat_template") and tokenizer.chat_template is not None:
41
+ messages = [{"role": "user", "content": prompt}]
42
+ prompt = tokenizer.apply_chat_template(
43
+ messages, tokenize=False, add_generation_prompt=True
44
+ )
45
+
46
+ response = generate(model, tokenizer, prompt=prompt, verbose=True)
47
+ ```