Suparious commited on
Commit
f5b7999
1 Parent(s): 80cf376

add model card

Browse files
Files changed (1) hide show
  1. README.md +131 -0
README.md CHANGED
@@ -1,3 +1,134 @@
1
  ---
 
 
2
  license: apache-2.0
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ language:
3
+ - en
4
  license: apache-2.0
5
+ datasets:
6
+ - ehartford/dolphin
7
+ - jondurbin/airoboros-2.2.1
8
+ - ehartford/dolphin-coder
9
+ - teknium/openhermes
10
+ - m-a-p/Code-Feedback
11
+ tags:
12
+ - quantized
13
+ - 4-bit
14
+ - AWQ
15
+ - transformers
16
+ - pytorch
17
+ - mistral
18
+ - text-generation
19
+ - conversational
20
+ - license:apache-2.0
21
+ - autotrain_compatible
22
+ - endpoints_compatible
23
+ - text-gen
24
+ library_name: transformers
25
+ model_creator: hydra-project
26
+ model_name: ChatHercules-2.5-Mistral-7B
27
+ model_type: mistral
28
+ pipeline_tag: text-generation
29
+ inference: false
30
+ prompt_template: '<|im_start|>system
31
+
32
+ {system_message}<|im_end|>
33
+
34
+ <|im_start|>user
35
+
36
+ {prompt}<|im_end|>
37
+
38
+ <|im_start|>assistant
39
+
40
+ '
41
+ quantized_by: Suparious
42
  ---
43
+ # cognitivecomputations/dolphin-2.8-experiment26-7b AWQ
44
+
45
+ - Model creator: [cognitivecomputations](https://huggingface.co/cognitivecomputations)
46
+ - Original model: [dolphin-2.8-experiment26-7b](https://huggingface.co/cognitivecomputations/dolphin-2.8-experiment26-7b)
47
+
48
+ <img src="https://cdn-uploads.huggingface.co/production/uploads/63111b2d88942700629f5771/ldkN1J0WIDQwU4vutGYiD.png" width="600" />
49
+
50
+ ## Model Summary
51
+
52
+ Sponsored by [MassedCompute](https://massedcompute.com/)
53
+
54
+ Discord https://discord.gg/cognitivecomputations
55
+
56
+ This model is based on [Experiment-26 by Yam Peleg](https://huggingface.co/yam-peleg/Experiment26-7B).
57
+
58
+ The base model has 16k context
59
+
60
+ This Dolphin is *really good* at coding, @ehartford trained this with a lot of coding data.
61
+
62
+ It took 3 days to train 3 epochs on 7x A6000s using qlora on Axolotl
63
+
64
+ ## How to use
65
+
66
+ ### Install the necessary packages
67
+
68
+ ```bash
69
+ pip install --upgrade autoawq autoawq-kernels
70
+ ```
71
+
72
+ ### Example Python code
73
+
74
+ ```python
75
+ from awq import AutoAWQForCausalLM
76
+ from transformers import AutoTokenizer, TextStreamer
77
+
78
+ model_path = "solidrust/dolphin-2.8-experiment26-7b-AWQ"
79
+ system_message = "You are Hercules, incarnated as a powerful AI."
80
+
81
+ # Load model
82
+ model = AutoAWQForCausalLM.from_quantized(model_path,
83
+ fuse_layers=True)
84
+ tokenizer = AutoTokenizer.from_pretrained(model_path,
85
+ trust_remote_code=True)
86
+ streamer = TextStreamer(tokenizer,
87
+ skip_prompt=True,
88
+ skip_special_tokens=True)
89
+
90
+ # Convert prompt to tokens
91
+ prompt_template = """\
92
+ <|im_start|>system
93
+ {system_message}<|im_end|>
94
+ <|im_start|>user
95
+ {prompt}<|im_end|>
96
+ <|im_start|>assistant"""
97
+
98
+ prompt = "You're standing on the surface of the Earth. "\
99
+ "You walk one mile south, one mile west and one mile north. "\
100
+ "You end up exactly where you started. Where are you?"
101
+
102
+ tokens = tokenizer(prompt_template.format(system_message=system_message,prompt=prompt),
103
+ return_tensors='pt').input_ids.cuda()
104
+
105
+ # Generate output
106
+ generation_output = model.generate(tokens,
107
+ streamer=streamer,
108
+ max_new_tokens=512)
109
+
110
+ ```
111
+
112
+ ### About AWQ
113
+
114
+ 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.
115
+
116
+ AWQ models are currently supported on Linux and Windows, with NVidia GPUs only. macOS users: please use GGUF models instead.
117
+
118
+ It is supported by:
119
+
120
+ - [Text Generation Webui](https://github.com/oobabooga/text-generation-webui) - using Loader: AutoAWQ
121
+ - [vLLM](https://github.com/vllm-project/vllm) - version 0.2.2 or later for support for all model types.
122
+ - [Hugging Face Text Generation Inference (TGI)](https://github.com/huggingface/text-generation-inference)
123
+ - [Transformers](https://huggingface.co/docs/transformers) version 4.35.0 and later, from any code or client that supports Transformers
124
+ - [AutoAWQ](https://github.com/casper-hansen/AutoAWQ) - for use from Python code
125
+
126
+ ## Prompt template: ChatML
127
+
128
+ ```plaintext
129
+ <|im_start|>system
130
+ {system_message}<|im_end|>
131
+ <|im_start|>user
132
+ {prompt}<|im_end|>
133
+ <|im_start|>assistant
134
+ ```