Smokeweaver commited on
Commit
b4076b9
1 Parent(s): b7808fd

Add model card

Browse files
Files changed (1) hide show
  1. README.md +123 -0
README.md CHANGED
@@ -1,3 +1,126 @@
1
  ---
 
 
2
  license: apache-2.0
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ language:
3
+ - en
4
  license: apache-2.0
5
+ tags:
6
+ - text-generation-inference
7
+ - transformers
8
+ - unsloth
9
+ - mistral
10
+ - trl
11
+ - sft
12
+ - quantized
13
+ - 4-bit
14
+ - AWQ
15
+ - text-generation
16
+ - autotrain_compatible
17
+ - endpoints_compatible
18
+ - chatml
19
+ base_model: mlabonne/AlphaMonarch-7B
20
+ library_name: transformers
21
+ model_creator: mlabonne
22
+ model_name: AlphaMonarch-7B
23
+ model_type: mistral
24
+ pipeline_tag: text-generation
25
+ inference: false
26
+ prompt_template: '<|im_start|>system
27
+
28
+ {system_message}<|im_end|>
29
+
30
+ <|im_start|>user
31
+
32
+ {prompt}<|im_end|>
33
+
34
+ <|im_start|>assistant
35
+
36
+ '
37
+ quantized_by: Suparious
38
  ---
39
+ # mlabonne/Darewin-7B AWQ
40
+
41
+ - Model creator: [mlabonne](https://huggingface.co/mlabonne)
42
+ - Original model: [AlphaMonarch-7B](https://huggingface.co/mlabonne/AlphaMonarch-7B)
43
+
44
+ ![image/png](https://cdn-uploads.huggingface.co/production/uploads/6455cc8d679315e4ef16fbec/bMRgkD7-UJ4b82hB_YUN6.png)
45
+
46
+ ## Model Summary
47
+
48
+ Thanks to [migtessera](https://huggingface.co/migtissera) for his dataset [Hitchhikers](https://huggingface.co/datasets/migtissera/Hitchhiker)
49
+
50
+ - **Developed by:** macadeliccc
51
+ - **License:** apache-2.0
52
+ - **Finetuned from model :** mlabonne/AlphaMonarch-7B
53
+
54
+ This mistral model was trained 2x faster with [Unsloth](https://github.com/unslothai/unsloth) and Huggingface's TRL library.
55
+
56
+ ## How to use
57
+
58
+ ### Install the necessary packages
59
+
60
+ ```bash
61
+ pip install --upgrade autoawq autoawq-kernels
62
+ ```
63
+
64
+ ### Example Python code
65
+
66
+ ```python
67
+ from awq import AutoAWQForCausalLM
68
+ from transformers import AutoTokenizer, TextStreamer
69
+
70
+ model_path = "solidrust/AlphaHitchhiker-7B-AWQ"
71
+ system_message = "You are Alpha, incarnated as a powerful AI."
72
+
73
+ # Load model
74
+ model = AutoAWQForCausalLM.from_quantized(model_path,
75
+ fuse_layers=True)
76
+ tokenizer = AutoTokenizer.from_pretrained(model_path,
77
+ trust_remote_code=True)
78
+ streamer = TextStreamer(tokenizer,
79
+ skip_prompt=True,
80
+ skip_special_tokens=True)
81
+
82
+ # Convert prompt to tokens
83
+ prompt_template = """\
84
+ <|im_start|>system
85
+ {system_message}<|im_end|>
86
+ <|im_start|>user
87
+ {prompt}<|im_end|>
88
+ <|im_start|>assistant"""
89
+
90
+ prompt = "You're standing on the surface of the Earth. "\
91
+ "You walk one mile south, one mile west and one mile north. "\
92
+ "You end up exactly where you started. Where are you?"
93
+
94
+ tokens = tokenizer(prompt_template.format(system_message=system_message,prompt=prompt),
95
+ return_tensors='pt').input_ids.cuda()
96
+
97
+ # Generate output
98
+ generation_output = model.generate(tokens,
99
+ streamer=streamer,
100
+ max_new_tokens=512)
101
+
102
+ ```
103
+
104
+ ### About AWQ
105
+
106
+ AWQ is an efficient, accurate and blazing-fast low-bit weight quantization method, currently supporting 4-bit quantization. Compared to GPTQ, it offers faster Transformers-based inference with equivalent or better quality compared to the most commonly used GPTQ settings.
107
+
108
+ AWQ models are currently supported on Linux and Windows, with NVidia GPUs only. macOS users: please use GGUF models instead.
109
+
110
+ It is supported by:
111
+
112
+ - [Text Generation Webui](https://github.com/oobabooga/text-generation-webui) - using Loader: AutoAWQ
113
+ - [vLLM](https://github.com/vllm-project/vllm) - version 0.2.2 or later for support for all model types.
114
+ - [Hugging Face Text Generation Inference (TGI)](https://github.com/huggingface/text-generation-inference)
115
+ - [Transformers](https://huggingface.co/docs/transformers) version 4.35.0 and later, from any code or client that supports Transformers
116
+ - [AutoAWQ](https://github.com/casper-hansen/AutoAWQ) - for use from Python code
117
+
118
+ ## Prompt template: ChatML
119
+
120
+ ```plaintext
121
+ <|im_start|>system
122
+ {system_message}<|im_end|>
123
+ <|im_start|>user
124
+ {prompt}<|im_end|>
125
+ <|im_start|>assistant
126
+ ```