michaelfeil commited on
Commit
84a751e
1 Parent(s): 446235f

Upload togethercomputer/GPT-JT-6B-v0 ctranslate fp16 weights

Browse files
Files changed (5) hide show
  1. README.md +73 -0
  2. added_tokens.json +145 -0
  3. merges.txt +0 -0
  4. special_tokens_map.json +23 -0
  5. vocab.json +0 -0
README.md ADDED
@@ -0,0 +1,73 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ language:
3
+ - en
4
+ datasets:
5
+ - natural_instructions
6
+ - the_pile
7
+ - cot
8
+ - Muennighoff/P3
9
+ tags:
10
+ - ctranslate2
11
+ - int8
12
+ - float16
13
+ - gpt
14
+ pipeline_tag: text-generation
15
+ inference:
16
+ parameters:
17
+ temperature: 0.1
18
+ widget:
19
+ - text: "Is this review positive or negative? Review: Best cast iron skillet you will ever buy. Answer:"
20
+ example_title: "Sentiment analysis"
21
+ - text: "Where is Zurich? Ans:"
22
+ example_title: "Question Answering"
23
+ ---
24
+ # # Fast-Inference with Ctranslate2
25
+ Speedup inference by 2x-8x using int8 inference in C++
26
+
27
+ quantized version of [togethercomputer/GPT-JT-6B-v0](https://huggingface.co/togethercomputer/GPT-JT-6B-v0)
28
+ ```bash
29
+ pip install hf-hub-ctranslate2>=2.0.6 ctranslate2>=3.13.0
30
+ ```
31
+ Converted on 2023-05-19 using
32
+ ```
33
+ ct2-transformers-converter --model togethercomputer/GPT-JT-6B-v0 --output_dir /home/michael/tmp-ct2fast-GPT-JT-6B-v0 --force --copy_files merges.txt tokenizer.json README.md tokenizer_config.json vocab.json special_tokens_map.json added_tokens.json .gitattributes --quantization float16
34
+ ```
35
+
36
+ Checkpoint compatible to [ctranslate2](https://github.com/OpenNMT/CTranslate2) and [hf-hub-ctranslate2](https://github.com/michaelfeil/hf-hub-ctranslate2)
37
+ - `compute_type=int8_float16` for `device="cuda"`
38
+ - `compute_type=int8` for `device="cpu"`
39
+
40
+ ```python
41
+ from hf_hub_ctranslate2 import TranslatorCT2fromHfHub, GeneratorCT2fromHfHub
42
+ from transformers import AutoTokenizer
43
+
44
+ model_name = "michaelfeil/ct2fast-GPT-JT-6B-v0"
45
+ # use either TranslatorCT2fromHfHub or GeneratorCT2fromHfHub here, depending on model.
46
+ model = GeneratorCT2fromHfHub(
47
+ # load in int8 on CUDA
48
+ model_name_or_path=model_name,
49
+ device="cuda",
50
+ compute_type="int8_float16",
51
+ tokenizer=AutoTokenizer.from_pretrained("togethercomputer/GPT-JT-6B-v0")
52
+ )
53
+ outputs = model.generate(
54
+ text=["How do you call a fast Flan-ingo?", "User: How are you doing?"],
55
+ )
56
+ print(outputs)
57
+ ```
58
+
59
+ # Licence and other remarks:
60
+ This is just a quantized version. Licence conditions are intended to be idential to original huggingface repo.
61
+
62
+ # Original description
63
+
64
+
65
+ # Quick Start
66
+
67
+ ```python
68
+ from transformers import pipeline
69
+
70
+ pipe = pipeline(model='togethercomputer/GPT-JT-6B-v0')
71
+
72
+ pipe("Where is Zurich? Ans:")
73
+ ```
added_tokens.json ADDED
@@ -0,0 +1,145 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "<|extratoken_100|>": 50356,
3
+ "<|extratoken_101|>": 50357,
4
+ "<|extratoken_102|>": 50358,
5
+ "<|extratoken_103|>": 50359,
6
+ "<|extratoken_104|>": 50360,
7
+ "<|extratoken_105|>": 50361,
8
+ "<|extratoken_106|>": 50362,
9
+ "<|extratoken_107|>": 50363,
10
+ "<|extratoken_108|>": 50364,
11
+ "<|extratoken_109|>": 50365,
12
+ "<|extratoken_10|>": 50266,
13
+ "<|extratoken_110|>": 50366,
14
+ "<|extratoken_111|>": 50367,
15
+ "<|extratoken_112|>": 50368,
16
+ "<|extratoken_113|>": 50369,
17
+ "<|extratoken_114|>": 50370,
18
+ "<|extratoken_115|>": 50371,
19
+ "<|extratoken_116|>": 50372,
20
+ "<|extratoken_117|>": 50373,
21
+ "<|extratoken_118|>": 50374,
22
+ "<|extratoken_119|>": 50375,
23
+ "<|extratoken_11|>": 50267,
24
+ "<|extratoken_120|>": 50376,
25
+ "<|extratoken_121|>": 50377,
26
+ "<|extratoken_122|>": 50378,
27
+ "<|extratoken_123|>": 50379,
28
+ "<|extratoken_124|>": 50380,
29
+ "<|extratoken_125|>": 50381,
30
+ "<|extratoken_126|>": 50382,
31
+ "<|extratoken_127|>": 50383,
32
+ "<|extratoken_128|>": 50384,
33
+ "<|extratoken_129|>": 50385,
34
+ "<|extratoken_12|>": 50268,
35
+ "<|extratoken_130|>": 50386,
36
+ "<|extratoken_131|>": 50387,
37
+ "<|extratoken_132|>": 50388,
38
+ "<|extratoken_133|>": 50389,
39
+ "<|extratoken_134|>": 50390,
40
+ "<|extratoken_135|>": 50391,
41
+ "<|extratoken_136|>": 50392,
42
+ "<|extratoken_137|>": 50393,
43
+ "<|extratoken_138|>": 50394,
44
+ "<|extratoken_139|>": 50395,
45
+ "<|extratoken_13|>": 50269,
46
+ "<|extratoken_140|>": 50396,
47
+ "<|extratoken_141|>": 50397,
48
+ "<|extratoken_142|>": 50398,
49
+ "<|extratoken_143|>": 50399,
50
+ "<|extratoken_14|>": 50270,
51
+ "<|extratoken_15|>": 50271,
52
+ "<|extratoken_16|>": 50272,
53
+ "<|extratoken_17|>": 50273,
54
+ "<|extratoken_18|>": 50274,
55
+ "<|extratoken_19|>": 50275,
56
+ "<|extratoken_1|>": 50257,
57
+ "<|extratoken_20|>": 50276,
58
+ "<|extratoken_21|>": 50277,
59
+ "<|extratoken_22|>": 50278,
60
+ "<|extratoken_23|>": 50279,
61
+ "<|extratoken_24|>": 50280,
62
+ "<|extratoken_25|>": 50281,
63
+ "<|extratoken_26|>": 50282,
64
+ "<|extratoken_27|>": 50283,
65
+ "<|extratoken_28|>": 50284,
66
+ "<|extratoken_29|>": 50285,
67
+ "<|extratoken_2|>": 50258,
68
+ "<|extratoken_30|>": 50286,
69
+ "<|extratoken_31|>": 50287,
70
+ "<|extratoken_32|>": 50288,
71
+ "<|extratoken_33|>": 50289,
72
+ "<|extratoken_34|>": 50290,
73
+ "<|extratoken_35|>": 50291,
74
+ "<|extratoken_36|>": 50292,
75
+ "<|extratoken_37|>": 50293,
76
+ "<|extratoken_38|>": 50294,
77
+ "<|extratoken_39|>": 50295,
78
+ "<|extratoken_3|>": 50259,
79
+ "<|extratoken_40|>": 50296,
80
+ "<|extratoken_41|>": 50297,
81
+ "<|extratoken_42|>": 50298,
82
+ "<|extratoken_43|>": 50299,
83
+ "<|extratoken_44|>": 50300,
84
+ "<|extratoken_45|>": 50301,
85
+ "<|extratoken_46|>": 50302,
86
+ "<|extratoken_47|>": 50303,
87
+ "<|extratoken_48|>": 50304,
88
+ "<|extratoken_49|>": 50305,
89
+ "<|extratoken_4|>": 50260,
90
+ "<|extratoken_50|>": 50306,
91
+ "<|extratoken_51|>": 50307,
92
+ "<|extratoken_52|>": 50308,
93
+ "<|extratoken_53|>": 50309,
94
+ "<|extratoken_54|>": 50310,
95
+ "<|extratoken_55|>": 50311,
96
+ "<|extratoken_56|>": 50312,
97
+ "<|extratoken_57|>": 50313,
98
+ "<|extratoken_58|>": 50314,
99
+ "<|extratoken_59|>": 50315,
100
+ "<|extratoken_5|>": 50261,
101
+ "<|extratoken_60|>": 50316,
102
+ "<|extratoken_61|>": 50317,
103
+ "<|extratoken_62|>": 50318,
104
+ "<|extratoken_63|>": 50319,
105
+ "<|extratoken_64|>": 50320,
106
+ "<|extratoken_65|>": 50321,
107
+ "<|extratoken_66|>": 50322,
108
+ "<|extratoken_67|>": 50323,
109
+ "<|extratoken_68|>": 50324,
110
+ "<|extratoken_69|>": 50325,
111
+ "<|extratoken_6|>": 50262,
112
+ "<|extratoken_70|>": 50326,
113
+ "<|extratoken_71|>": 50327,
114
+ "<|extratoken_72|>": 50328,
115
+ "<|extratoken_73|>": 50329,
116
+ "<|extratoken_74|>": 50330,
117
+ "<|extratoken_75|>": 50331,
118
+ "<|extratoken_76|>": 50332,
119
+ "<|extratoken_77|>": 50333,
120
+ "<|extratoken_78|>": 50334,
121
+ "<|extratoken_79|>": 50335,
122
+ "<|extratoken_7|>": 50263,
123
+ "<|extratoken_80|>": 50336,
124
+ "<|extratoken_81|>": 50337,
125
+ "<|extratoken_82|>": 50338,
126
+ "<|extratoken_83|>": 50339,
127
+ "<|extratoken_84|>": 50340,
128
+ "<|extratoken_85|>": 50341,
129
+ "<|extratoken_86|>": 50342,
130
+ "<|extratoken_87|>": 50343,
131
+ "<|extratoken_88|>": 50344,
132
+ "<|extratoken_89|>": 50345,
133
+ "<|extratoken_8|>": 50264,
134
+ "<|extratoken_90|>": 50346,
135
+ "<|extratoken_91|>": 50347,
136
+ "<|extratoken_92|>": 50348,
137
+ "<|extratoken_93|>": 50349,
138
+ "<|extratoken_94|>": 50350,
139
+ "<|extratoken_95|>": 50351,
140
+ "<|extratoken_96|>": 50352,
141
+ "<|extratoken_97|>": 50353,
142
+ "<|extratoken_98|>": 50354,
143
+ "<|extratoken_99|>": 50355,
144
+ "<|extratoken_9|>": 50265
145
+ }
merges.txt ADDED
The diff for this file is too large to render. See raw diff
 
special_tokens_map.json ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "bos_token": {
3
+ "content": "<|endoftext|>",
4
+ "lstrip": false,
5
+ "normalized": true,
6
+ "rstrip": false,
7
+ "single_word": false
8
+ },
9
+ "eos_token": {
10
+ "content": "<|endoftext|>",
11
+ "lstrip": false,
12
+ "normalized": true,
13
+ "rstrip": false,
14
+ "single_word": false
15
+ },
16
+ "unk_token": {
17
+ "content": "<|endoftext|>",
18
+ "lstrip": false,
19
+ "normalized": true,
20
+ "rstrip": false,
21
+ "single_word": false
22
+ }
23
+ }
vocab.json ADDED
The diff for this file is too large to render. See raw diff