Upload 3 files
Browse files
button.js
ADDED
@@ -0,0 +1,62 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
var btn_evalTable = document.getElementById("btn_evalTable");
|
2 |
+
var btn_about = document.getElementById("btn_about");
|
3 |
+
var btn_plot = document.getElementById("btn_plot");
|
4 |
+
var btn_submit = document.getElementById("btn_submit");
|
5 |
+
var sec_evalTable = document.getElementById("sec_evalTable");
|
6 |
+
var sec_about = document.getElementById("sec_about");
|
7 |
+
var sec_plot = document.getElementById("sec_plot")
|
8 |
+
var sec_submit = document.getElementById("sec_submit");
|
9 |
+
|
10 |
+
|
11 |
+
btn_evalTable.addEventListener("click", function() {
|
12 |
+
sec_evalTable.style.display = "block";
|
13 |
+
sec_plot.style.display = "none";
|
14 |
+
sec_about.style.display = "none";
|
15 |
+
sec_submit.style.display = "none";
|
16 |
+
|
17 |
+
btn_evalTable.style.color = "#000000";
|
18 |
+
btn_plot.style.color = "#7c7b7b";
|
19 |
+
btn_about.style.color = "#7c7b7b";
|
20 |
+
btn_submit.style.color = "#7c7b7b";
|
21 |
+
|
22 |
+
});
|
23 |
+
btn_about.addEventListener("click", function() {
|
24 |
+
sec_evalTable.style.display = "none";
|
25 |
+
sec_plot.style.display = "none";
|
26 |
+
sec_about.style.display = "block";
|
27 |
+
sec_submit.style.display = "none";
|
28 |
+
|
29 |
+
btn_evalTable.style.color = "#7c7b7b";
|
30 |
+
btn_plot.style.color = "#7c7b7b";
|
31 |
+
btn_about.style.color = "#000000";
|
32 |
+
btn_submit.style.color = "#7c7b7b";
|
33 |
+
|
34 |
+
});
|
35 |
+
|
36 |
+
btn_plot.addEventListener("click", function() {
|
37 |
+
sec_evalTable.style.display = "none";
|
38 |
+
sec_plot.style.display = "block";
|
39 |
+
sec_about.style.display = "none";
|
40 |
+
sec_submit.style.display = "none";
|
41 |
+
|
42 |
+
btn_evalTable.style.color = "#7c7b7b";
|
43 |
+
btn_plot.style.color = "#000000";
|
44 |
+
btn_about.style.color = "#7c7b7b";
|
45 |
+
btn_submit.style.color = "#7c7b7b";
|
46 |
+
|
47 |
+
});
|
48 |
+
|
49 |
+
btn_submit.addEventListener("click", function() {
|
50 |
+
sec_evalTable.style.display = "none";
|
51 |
+
sec_plot.style.display = "none";
|
52 |
+
sec_about.style.display = "none";
|
53 |
+
sec_submit.style.display = "block";
|
54 |
+
|
55 |
+
btn_evalTable.style.color = "#7c7b7b";
|
56 |
+
btn_plot.style.color = "#7c7b7b";
|
57 |
+
btn_about.style.color = "#7c7b7b";
|
58 |
+
btn_submit.style.color = "#000000";
|
59 |
+
|
60 |
+
});
|
61 |
+
|
62 |
+
|
chart.js
ADDED
@@ -0,0 +1,408 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
var Chart = echarts.init(document.getElementById('sec_plot__chart1'));
|
2 |
+
var Chart2 = echarts.init(document.getElementById('sec_plot__chart2'));
|
3 |
+
var dataset = [
|
4 |
+
{
|
5 |
+
name: 'GPT-3.5-turbo-1103',
|
6 |
+
MGI: 0.2326,
|
7 |
+
temp0_HumanEval: 0.7439,
|
8 |
+
temp0_HumanEval_ET: 0.5915,
|
9 |
+
temp0_8_HumanEval: 0.7248,
|
10 |
+
temp0_8_HumanEval_ET: 0.5778,
|
11 |
+
},
|
12 |
+
{
|
13 |
+
name: 'GPT-3.5-turbo-0613',
|
14 |
+
MGI: 0.1314,
|
15 |
+
temp0_HumanEval: 0.6585,
|
16 |
+
temp0_HumanEval_ET: 0.5122,
|
17 |
+
temp0_8_HumanEval: 0.612,
|
18 |
+
temp0_8_HumanEval_ET: 0.4776,
|
19 |
+
},
|
20 |
+
{
|
21 |
+
name: 'CodeGeeX4-All-9B',
|
22 |
+
MGI: 0.5182,
|
23 |
+
temp0_HumanEval: 0.7805,
|
24 |
+
temp0_HumanEval_ET: 0.622,
|
25 |
+
temp0_8_HumanEval: 0.7606,
|
26 |
+
temp0_8_HumanEval_ET: 0.6078,
|
27 |
+
},
|
28 |
+
{
|
29 |
+
name: 'Deepseek-Coder-6.7b-base',
|
30 |
+
MGI: 0.0602,
|
31 |
+
temp0_HumanEval: 0.4817,
|
32 |
+
temp0_HumanEval_ET: 0.3963,
|
33 |
+
temp0_8_HumanEval: 0.3388,
|
34 |
+
temp0_8_HumanEval_ET: 0.2798,
|
35 |
+
},
|
36 |
+
{
|
37 |
+
name: 'Deepseek-Coder-6.7b-instruct',
|
38 |
+
MGI: 0.0893,
|
39 |
+
temp0_HumanEval: 0.7134,
|
40 |
+
temp0_HumanEval_ET: 0.628,
|
41 |
+
temp0_8_HumanEval: 0.6494,
|
42 |
+
temp0_8_HumanEval_ET: 0.5673,
|
43 |
+
},
|
44 |
+
{
|
45 |
+
name: 'CodeLlama-7b',
|
46 |
+
MGI: 0.0417,
|
47 |
+
temp0_HumanEval: 0.311,
|
48 |
+
temp0_HumanEval_ET: 0.2378,
|
49 |
+
temp0_8_HumanEval: 0.2211,
|
50 |
+
temp0_8_HumanEval_ET: 0.1832,
|
51 |
+
},
|
52 |
+
{
|
53 |
+
name: 'CodeLlama-7b-python',
|
54 |
+
MGI: 0.0525,
|
55 |
+
temp0_HumanEval: 0.3841,
|
56 |
+
temp0_HumanEval_ET: 0.3354,
|
57 |
+
temp0_8_HumanEval: 0.3062,
|
58 |
+
temp0_8_HumanEval_ET: 0.2568,
|
59 |
+
},
|
60 |
+
{
|
61 |
+
name: 'CodeLlama-7b-instruct',
|
62 |
+
MGI: 0.0908,
|
63 |
+
temp0_HumanEval: 0.3537,
|
64 |
+
temp0_HumanEval_ET: 0.2988,
|
65 |
+
temp0_8_HumanEval: 0.2876,
|
66 |
+
temp0_8_HumanEval_ET: 0.2455,
|
67 |
+
},
|
68 |
+
{
|
69 |
+
name: 'CodeGemma-2b',
|
70 |
+
MGI: 0.0112,
|
71 |
+
temp0_HumanEval: 0.3537,
|
72 |
+
temp0_HumanEval_ET: 0.2805,
|
73 |
+
temp0_8_HumanEval: 0.2161,
|
74 |
+
temp0_8_HumanEval_ET: 0.1771,
|
75 |
+
},
|
76 |
+
{
|
77 |
+
name: 'CodeGemma-7b',
|
78 |
+
MGI: 0.0548,
|
79 |
+
temp0_HumanEval: 0.4329,
|
80 |
+
temp0_HumanEval_ET: 0.3537,
|
81 |
+
temp0_8_HumanEval: 0.3316,
|
82 |
+
temp0_8_HumanEval_ET: 0.2779,
|
83 |
+
},
|
84 |
+
{
|
85 |
+
name: 'AixCoder3-7b-base',
|
86 |
+
MGI: 0.0578,
|
87 |
+
temp0_HumanEval: 0.5427,
|
88 |
+
temp0_HumanEval_ET: 0.4451,
|
89 |
+
temp0_8_HumanEval: 0.4545,
|
90 |
+
temp0_8_HumanEval_ET: 0.3826,
|
91 |
+
},
|
92 |
+
{
|
93 |
+
name: 'CodeQwen1.5-7b',
|
94 |
+
MGI: 0.0361,
|
95 |
+
temp0_HumanEval: 0.439,
|
96 |
+
temp0_HumanEval_ET: 0.3841,
|
97 |
+
temp0_8_HumanEval: 0.3884,
|
98 |
+
temp0_8_HumanEval_ET: 0.3279,
|
99 |
+
},
|
100 |
+
{
|
101 |
+
name: 'Starcoder2-7b',
|
102 |
+
MGI: 0.0579,
|
103 |
+
temp0_HumanEval: 0.3659,
|
104 |
+
temp0_HumanEval_ET: 0.3232,
|
105 |
+
temp0_8_HumanEval: 0.2905,
|
106 |
+
temp0_8_HumanEval_ET: 0.2438,
|
107 |
+
},
|
108 |
+
{
|
109 |
+
name: 'Starcoder2-15b',
|
110 |
+
MGI: 0.0552,
|
111 |
+
temp0_HumanEval: 0.4695,
|
112 |
+
temp0_HumanEval_ET: 0.4024,
|
113 |
+
temp0_8_HumanEval: 0.3406,
|
114 |
+
temp0_8_HumanEval_ET: 0.2795,
|
115 |
+
},
|
116 |
+
{
|
117 |
+
name: 'CodeLlama-13b',
|
118 |
+
MGI: 0.0412,
|
119 |
+
temp0_HumanEval: 0.3415,
|
120 |
+
temp0_HumanEval_ET: 0.2927,
|
121 |
+
temp0_8_HumanEval: 0.2405,
|
122 |
+
temp0_8_HumanEval_ET: 0.2015,
|
123 |
+
},
|
124 |
+
{
|
125 |
+
name: 'CodeLlama-34b',
|
126 |
+
MGI: 0.0651,
|
127 |
+
temp0_HumanEval: 0.4817,
|
128 |
+
temp0_HumanEval_ET: 0.4146,
|
129 |
+
temp0_8_HumanEval: 0.3478,
|
130 |
+
temp0_8_HumanEval_ET: 0.2906,
|
131 |
+
},
|
132 |
+
{
|
133 |
+
name: 'CodeLlama-70b',
|
134 |
+
MGI: 0.0523,
|
135 |
+
temp0_HumanEval: 0.5244,
|
136 |
+
temp0_HumanEval_ET: 0.4512,
|
137 |
+
temp0_8_HumanEval: 0.4317,
|
138 |
+
temp0_8_HumanEval_ET: 0.3615,
|
139 |
+
},
|
140 |
+
]
|
141 |
+
let ymins = new Array(0.27, 0.16, 0.21, 0.14)
|
142 |
+
let titleText = [
|
143 |
+
'Memorization-Generalization Index VS HumanEval(temp = 0)',
|
144 |
+
'Memorization-Generalization Index VS HumanEval(temp = 0.8)',
|
145 |
+
'Memorization-Generalization Index VS HumanEval-ET(temp = 0)',
|
146 |
+
'Memorization-Generalization Index VS HumanEval-ET(temp = 0.8)'
|
147 |
+
]
|
148 |
+
let options = new Array(4)
|
149 |
+
for(let i = 0; i < 4; i++){
|
150 |
+
options[i] = {
|
151 |
+
series: [
|
152 |
+
{ name: 'GPT-3.5-turbo-1103' },
|
153 |
+
{ name: 'GPT-3.5-turbo-0613' },
|
154 |
+
{ name: 'CodeGeeX4-All-9B' },
|
155 |
+
{ name: 'Deepseek-Coder-6.7b-base' },
|
156 |
+
{ name: 'Deepseek-Coder-6.7b-instruct' },
|
157 |
+
{ name: 'CodeLlama-7b' },
|
158 |
+
{ name: 'CodeLlama-7b-python' },
|
159 |
+
{ name: 'CodeLlama-7b-instruct' },
|
160 |
+
{ name: 'CodeGemma-2b' },
|
161 |
+
{ name: 'CodeGemma-7b' },
|
162 |
+
{ name: 'AixCoder3-7b-base' },
|
163 |
+
{ name: 'CodeQwen1.5-7b' },
|
164 |
+
{ name: 'Starcoder2-7b' },
|
165 |
+
{ name: 'Starcoder2-15b' },
|
166 |
+
{ name: 'CodeLlama-13b' },
|
167 |
+
{ name: 'CodeLlama-34b' },
|
168 |
+
{ name: 'CodeLlama-70b' }
|
169 |
+
],
|
170 |
+
grid: {
|
171 |
+
show: true,
|
172 |
+
top: '15%',
|
173 |
+
left: '12%',
|
174 |
+
right: '45%',
|
175 |
+
borderColor: 'transparent',
|
176 |
+
backgroundColor: '#eff1f7'
|
177 |
+
},
|
178 |
+
legend: {
|
179 |
+
right: 95,
|
180 |
+
bottom: '11%',
|
181 |
+
orient: 'vertical',
|
182 |
+
icon: 'diamond',
|
183 |
+
itemWidth: 14,
|
184 |
+
itemHeight: 14,
|
185 |
+
textStyle: {
|
186 |
+
fontSize: 14.5,
|
187 |
+
color: '#5876fa'
|
188 |
+
},
|
189 |
+
},
|
190 |
+
title: {
|
191 |
+
show: true,
|
192 |
+
text: '',
|
193 |
+
left: 'center',
|
194 |
+
textStyle: {
|
195 |
+
fontFamily: "Arial",
|
196 |
+
fontSize: 20,
|
197 |
+
fontWeight: 'normal'
|
198 |
+
},
|
199 |
+
top: 25
|
200 |
+
},
|
201 |
+
tooltip: {
|
202 |
+
trigger: 'item',
|
203 |
+
},
|
204 |
+
xAxis: {
|
205 |
+
name: 'Memorization-Generalization Index',
|
206 |
+
nameLocation: 'middle',
|
207 |
+
nameGap: 32,
|
208 |
+
nameTextStyle: {
|
209 |
+
fontSize: 15,
|
210 |
+
fontFamily: 'Arial',
|
211 |
+
},
|
212 |
+
min: -0.08,
|
213 |
+
axisLabel: {
|
214 |
+
showMinLabel: false
|
215 |
+
},
|
216 |
+
splitLine: {
|
217 |
+
show: true,
|
218 |
+
lineStyle: {
|
219 |
+
color: 'white'
|
220 |
+
}
|
221 |
+
},
|
222 |
+
axisTick:{
|
223 |
+
show:false
|
224 |
+
},
|
225 |
+
axisLine: {
|
226 |
+
show: false,
|
227 |
+
},
|
228 |
+
},
|
229 |
+
yAxis: {
|
230 |
+
name: '',
|
231 |
+
nameLocation: 'middle',
|
232 |
+
nameGap: 40,
|
233 |
+
nameTextStyle: {
|
234 |
+
fontSize: 16,
|
235 |
+
fontFamily: 'Arial',
|
236 |
+
},
|
237 |
+
type: 'value',
|
238 |
+
axisLabel: {
|
239 |
+
showMinLabel: false
|
240 |
+
},
|
241 |
+
splitLine: {
|
242 |
+
show: true,
|
243 |
+
lineStyle: {
|
244 |
+
color: 'white'
|
245 |
+
}
|
246 |
+
},
|
247 |
+
axisTick:{
|
248 |
+
show:false
|
249 |
+
},
|
250 |
+
axisLine: {
|
251 |
+
show: false,
|
252 |
+
},
|
253 |
+
},
|
254 |
+
};
|
255 |
+
options[i].title.text = titleText[i]
|
256 |
+
options[i].tooltip.formatter = (
|
257 |
+
i < 2 ? function(params) {
|
258 |
+
return params.marker +
|
259 |
+
`<span style="color: ${params.color}; text-decoration: underline">` + params.seriesName + '</span>' +
|
260 |
+
'<br/><br/>MGI: ' + params.data[0] +
|
261 |
+
'<br/>HumanEval: ' + params.data[1] +
|
262 |
+
'<br/>HumanEval-ET: ' + params.data[2];
|
263 |
+
}
|
264 |
+
: function(params) {
|
265 |
+
return params.marker +
|
266 |
+
`<span style="color: ${params.color}; text-decoration: underline">` + params.seriesName + '</span>' +
|
267 |
+
'<br/><br/>MGI: ' + params.data[0] +
|
268 |
+
'<br/>HumanEval-ET: ' + params.data[1] +
|
269 |
+
'<br/>HumanEval: ' + params.data[2];
|
270 |
+
}
|
271 |
+
)
|
272 |
+
options[i].yAxis.name = (
|
273 |
+
i < 2 ? 'HumanEval'
|
274 |
+
: 'HumanEval-ET'
|
275 |
+
)
|
276 |
+
options[i].yAxis.min = ymins[i]
|
277 |
+
}
|
278 |
+
|
279 |
+
for(let i = 0; i < dataset.length; i++){
|
280 |
+
options[0].series[i].data = [[dataset[i].MGI, dataset[i].temp0_HumanEval,dataset[i].temp0_HumanEval_ET]]
|
281 |
+
options[1].series[i].data = [[dataset[i].MGI, dataset[i].temp0_8_HumanEval, dataset[i].temp0_8_HumanEval_ET]]
|
282 |
+
options[2].series[i].data = [[dataset[i].MGI, dataset[i].temp0_HumanEval_ET,dataset[i].temp0_HumanEval]]
|
283 |
+
options[3].series[i].data = [[dataset[i].MGI, dataset[i].temp0_8_HumanEval_ET, dataset[i].temp0_8_HumanEval]]
|
284 |
+
}
|
285 |
+
|
286 |
+
for(let i = 0; i < 4; i++){
|
287 |
+
for(let j = 0; j < dataset.length; ++j){
|
288 |
+
options[i].series[j].type = 'scatter'
|
289 |
+
options[i].series[j].symbol = 'diamond'
|
290 |
+
}
|
291 |
+
}
|
292 |
+
|
293 |
+
function setSymbolSize() {
|
294 |
+
for (var i = 0; i < dataset.length; i++) {
|
295 |
+
if(dataset[i].MGI < 0.1 && dataset[i].temp0_HumanEval > 0.5){
|
296 |
+
options[0].series[i].symbolSize = 50
|
297 |
+
options[1].series[i].symbolSize = 50
|
298 |
+
}
|
299 |
+
else if(dataset[i].temp0_HumanEval > 0.43 && dataset[i].temp0_HumanEval < 0.75){
|
300 |
+
options[0].series[i].symbolSize = 30
|
301 |
+
options[1].series[i].symbolSize = 30
|
302 |
+
}
|
303 |
+
else if(dataset[i].MGI < 0.015 || dataset[i].temp0_HumanEval > 0.38){
|
304 |
+
options[0].series[i].symbolSize = 20
|
305 |
+
options[1].series[i].symbolSize = 20
|
306 |
+
}
|
307 |
+
else {
|
308 |
+
options[0].series[i].symbolSize = 13
|
309 |
+
options[1].series[i].symbolSize = 13
|
310 |
+
}
|
311 |
+
}
|
312 |
+
for (var i = 0; i < dataset.length; i++) {
|
313 |
+
if(dataset[i].MGI < 0.1 && dataset[i].temp0_HumanEval_ET > 0.5){
|
314 |
+
options[2].series[i].symbolSize = 50
|
315 |
+
options[3].series[i].symbolSize = 50
|
316 |
+
}
|
317 |
+
else if(dataset[i].temp0_HumanEval_ET > 0.43 && dataset[i].temp0_HumanEval_ET < 0.75){
|
318 |
+
options[2].series[i].symbolSize = 30
|
319 |
+
options[3].series[i].symbolSize = 30
|
320 |
+
}
|
321 |
+
else if(dataset[i].MGI < 0.015 || dataset[i].temp0_HumanEval_ET > 0.38){
|
322 |
+
options[2].series[i].symbolSize = 20
|
323 |
+
options[3].series[i].symbolSize = 20
|
324 |
+
}
|
325 |
+
else {
|
326 |
+
options[2].series[i].symbolSize = 13
|
327 |
+
options[3].series[i].symbolSize = 13
|
328 |
+
}
|
329 |
+
}
|
330 |
+
}
|
331 |
+
setSymbolSize()
|
332 |
+
|
333 |
+
Chart.setOption(options[0])
|
334 |
+
Chart2.setOption(options[1])
|
335 |
+
|
336 |
+
|
337 |
+
// button and span
|
338 |
+
var btn_temp0_HumanEval = document.getElementById('btn_temp0_HumanEval')
|
339 |
+
var btn_temp0_HumanEval_ET = document.getElementById('btn_temp0_HumanEval_ET')
|
340 |
+
var btn_temp0_8_HumanEval = document.getElementById('btn_temp0_8_HumanEval')
|
341 |
+
var btn_temp0_8_HumanEval_ET = document.getElementById('btn_temp0_8_HumanEval_ET')
|
342 |
+
|
343 |
+
|
344 |
+
|
345 |
+
var span_temp0_HumanEval = document.getElementById('span_temp0_HumanEval')
|
346 |
+
var span_temp0_HumanEval_ET = document.getElementById('span_temp0_HumanEval_ET')
|
347 |
+
var span_temp0_8_HumanEval = document.getElementById('span_temp0_8_HumanEval')
|
348 |
+
var span_temp0_8_HumanEval_ET = document.getElementById('span_temp0_8_HumanEval_ET')
|
349 |
+
|
350 |
+
btn_temp0_HumanEval.addEventListener("click", function() {
|
351 |
+
Chart.setOption(options[0])
|
352 |
+
btn_temp0_HumanEval.style.backgroundColor = '#386df4'
|
353 |
+
span_temp0_HumanEval.style.color = '#386df4'
|
354 |
+
btn_temp0_HumanEval_ET.style.backgroundColor = '#d3d3d3'
|
355 |
+
span_temp0_HumanEval_ET.style.color = '#d3d3d3'
|
356 |
+
})
|
357 |
+
span_temp0_HumanEval.addEventListener("click", function() {
|
358 |
+
Chart.setOption(options[0]);
|
359 |
+
btn_temp0_HumanEval.style.backgroundColor = '#386df4'
|
360 |
+
span_temp0_HumanEval.style.color = '#386df4'
|
361 |
+
btn_temp0_HumanEval_ET.style.backgroundColor = '#d3d3d3'
|
362 |
+
span_temp0_HumanEval_ET.style.color = '#d3d3d3'
|
363 |
+
})
|
364 |
+
|
365 |
+
btn_temp0_HumanEval_ET.addEventListener("click", function() {
|
366 |
+
Chart.setOption(options[2])
|
367 |
+
btn_temp0_HumanEval.style.backgroundColor = '#d3d3d3'
|
368 |
+
span_temp0_HumanEval.style.color = '#d3d3d3'
|
369 |
+
btn_temp0_HumanEval_ET.style.backgroundColor = '#386df4'
|
370 |
+
span_temp0_HumanEval_ET.style.color = '#386df4'
|
371 |
+
})
|
372 |
+
span_temp0_HumanEval_ET.addEventListener("click", function() {
|
373 |
+
Chart.setOption(options[2])
|
374 |
+
btn_temp0_HumanEval.style.backgroundColor = '#d3d3d3'
|
375 |
+
span_temp0_HumanEval.style.color = '#d3d3d3'
|
376 |
+
btn_temp0_HumanEval_ET.style.backgroundColor = '#386df4'
|
377 |
+
span_temp0_HumanEval_ET.style.color = '#386df4'
|
378 |
+
})
|
379 |
+
|
380 |
+
btn_temp0_8_HumanEval.addEventListener("click", function() {
|
381 |
+
Chart2.setOption(options[1])
|
382 |
+
btn_temp0_8_HumanEval.style.backgroundColor = '#386df4'
|
383 |
+
span_temp0_8_HumanEval.style.color = '#386df4'
|
384 |
+
btn_temp0_8_HumanEval_ET.style.backgroundColor = '#d3d3d3'
|
385 |
+
span_temp0_8_HumanEval_ET.style.color = '#d3d3d3'
|
386 |
+
})
|
387 |
+
span_temp0_8_HumanEval.addEventListener("click", function() {
|
388 |
+
Chart2.setOption(options[1]);
|
389 |
+
btn_temp0_8_HumanEval.style.backgroundColor = '#386df4'
|
390 |
+
span_temp0_8_HumanEval.style.color = '#386df4'
|
391 |
+
btn_temp0_8_HumanEval_ET.style.backgroundColor = '#d3d3d3'
|
392 |
+
span_temp0_8_HumanEval_ET.style.color = '#d3d3d3'
|
393 |
+
})
|
394 |
+
|
395 |
+
btn_temp0_8_HumanEval_ET.addEventListener("click", function() {
|
396 |
+
Chart2.setOption(options[3])
|
397 |
+
btn_temp0_8_HumanEval.style.backgroundColor = '#d3d3d3'
|
398 |
+
span_temp0_8_HumanEval.style.color = '#d3d3d3'
|
399 |
+
btn_temp0_8_HumanEval_ET.style.backgroundColor = '#386df4'
|
400 |
+
span_temp0_8_HumanEval_ET.style.color = '#386df4'
|
401 |
+
})
|
402 |
+
span_temp0_8_HumanEval_ET.addEventListener("click", function() {
|
403 |
+
Chart2.setOption(options[3])
|
404 |
+
btn_temp0_8_HumanEval.style.backgroundColor = '#d3d3d3'
|
405 |
+
span_temp0_8_HumanEval.style.color = '#d3d3d3'
|
406 |
+
btn_temp0_8_HumanEval_ET.style.backgroundColor = '#386df4'
|
407 |
+
span_temp0_8_HumanEval_ET.style.color = '#386df4'
|
408 |
+
})
|
table.js
ADDED
@@ -0,0 +1,274 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
const models = [
|
2 |
+
{
|
3 |
+
name: 'GPT-3.5-turbo-1103',
|
4 |
+
MGI: 0.2326,
|
5 |
+
temp0_HumanEval: 0.7439,
|
6 |
+
temp0_HumanEval_ET: 0.5915,
|
7 |
+
temp0_8_HumanEval: 0.7248,
|
8 |
+
temp0_8_HumanEval_ET: 0.5778,
|
9 |
+
link: 'https://platform.openai.com/docs/models/gpt-3-5-turbo',
|
10 |
+
},
|
11 |
+
{
|
12 |
+
name: 'GPT-3.5-turbo-0613',
|
13 |
+
MGI: 0.1314,
|
14 |
+
temp0_HumanEval: 0.6585,
|
15 |
+
temp0_HumanEval_ET: 0.5122,
|
16 |
+
temp0_8_HumanEval: 0.612,
|
17 |
+
temp0_8_HumanEval_ET: 0.4776,
|
18 |
+
link: 'https://platform.openai.com/docs/models/gpt-3-5-turbo',
|
19 |
+
},
|
20 |
+
{
|
21 |
+
name: 'CodeGeeX4-All-9B',
|
22 |
+
MGI: 0.5182,
|
23 |
+
temp0_HumanEval: 0.7805,
|
24 |
+
temp0_HumanEval_ET: 0.622,
|
25 |
+
temp0_8_HumanEval: 0.7606,
|
26 |
+
temp0_8_HumanEval_ET: 0.6078,
|
27 |
+
link: 'https://huggingface.co/THUDM/codegeex4-all-9b',
|
28 |
+
},
|
29 |
+
{
|
30 |
+
name: 'Deepseek-Coder-6.7b',
|
31 |
+
MGI: 0.0602,
|
32 |
+
temp0_HumanEval: 0.4817,
|
33 |
+
temp0_HumanEval_ET: 0.3963,
|
34 |
+
temp0_8_HumanEval: 0.3388,
|
35 |
+
temp0_8_HumanEval_ET: 0.2798,
|
36 |
+
link: 'https://huggingface.co/deepseek-ai/deepseek-coder-6.7b-base',
|
37 |
+
},
|
38 |
+
{
|
39 |
+
name: 'Deepseek-Coder-6.7b-instruct',
|
40 |
+
MGI: 0.0893,
|
41 |
+
temp0_HumanEval: 0.7134,
|
42 |
+
temp0_HumanEval_ET: 0.628,
|
43 |
+
temp0_8_HumanEval: 0.6494,
|
44 |
+
temp0_8_HumanEval_ET: 0.5673,
|
45 |
+
link: 'https://huggingface.co/deepseek-ai/deepseek-coder-6.7b-instruct'
|
46 |
+
},
|
47 |
+
{
|
48 |
+
name: 'CodeLlama-7b',
|
49 |
+
MGI: 0.0417,
|
50 |
+
temp0_HumanEval: 0.311,
|
51 |
+
temp0_HumanEval_ET: 0.2378,
|
52 |
+
temp0_8_HumanEval: 0.2211,
|
53 |
+
temp0_8_HumanEval_ET: 0.1832,
|
54 |
+
link: 'https://huggingface.co/codellama/CodeLlama-7b-hf'
|
55 |
+
},
|
56 |
+
{
|
57 |
+
name: 'CodeLlama-7b-python',
|
58 |
+
MGI: 0.0525,
|
59 |
+
temp0_HumanEval: 0.3841,
|
60 |
+
temp0_HumanEval_ET: 0.3354,
|
61 |
+
temp0_8_HumanEval: 0.3062,
|
62 |
+
temp0_8_HumanEval_ET: 0.2568,
|
63 |
+
link: 'https://huggingface.co/codellama/CodeLlama-7b-Python-hf'
|
64 |
+
},
|
65 |
+
{
|
66 |
+
name: 'CodeLlama-7b-instruct',
|
67 |
+
MGI: 0.0908,
|
68 |
+
temp0_HumanEval: 0.3537,
|
69 |
+
temp0_HumanEval_ET: 0.2988,
|
70 |
+
temp0_8_HumanEval: 0.2876,
|
71 |
+
temp0_8_HumanEval_ET: 0.2455,
|
72 |
+
link: 'https://huggingface.co/codellama/CodeLlama-7b-Instruct-hf'
|
73 |
+
},
|
74 |
+
{
|
75 |
+
name: 'CodeGemma-2b',
|
76 |
+
MGI: 0.0112,
|
77 |
+
temp0_HumanEval: 0.3537,
|
78 |
+
temp0_HumanEval_ET: 0.2805,
|
79 |
+
temp0_8_HumanEval: 0.2161,
|
80 |
+
temp0_8_HumanEval_ET: 0.1771,
|
81 |
+
link: 'https://huggingface.co/google/codegemma-2b',
|
82 |
+
},
|
83 |
+
{
|
84 |
+
name: 'CodeGemma-7b',
|
85 |
+
MGI: 0.0548,
|
86 |
+
temp0_HumanEval: 0.4329,
|
87 |
+
temp0_HumanEval_ET: 0.3537,
|
88 |
+
temp0_8_HumanEval: 0.3316,
|
89 |
+
temp0_8_HumanEval_ET: 0.2779,
|
90 |
+
link: 'https://huggingface.co/google/codegemma-7b',
|
91 |
+
},
|
92 |
+
{
|
93 |
+
name: 'AixCoder3-7b-base',
|
94 |
+
MGI: 0.0578,
|
95 |
+
temp0_HumanEval: 0.5427,
|
96 |
+
temp0_HumanEval_ET: 0.4451,
|
97 |
+
temp0_8_HumanEval: 0.4545,
|
98 |
+
temp0_8_HumanEval_ET: 0.3826,
|
99 |
+
link: 'https://github.com/aixcoder-plugin/aiXcoder-7B?ref=top.aibase.com',
|
100 |
+
},
|
101 |
+
{
|
102 |
+
name: 'CodeQwen1.5-7b',
|
103 |
+
MGI: 0.0361,
|
104 |
+
temp0_HumanEval: 0.439,
|
105 |
+
temp0_HumanEval_ET: 0.3841,
|
106 |
+
temp0_8_HumanEval: 0.3884,
|
107 |
+
temp0_8_HumanEval_ET: 0.3279,
|
108 |
+
link: 'https://huggingface.co/Qwen/CodeQwen1.5-7B',
|
109 |
+
},
|
110 |
+
{
|
111 |
+
name: 'Starcoder2-7b',
|
112 |
+
MGI: 0.0579,
|
113 |
+
temp0_HumanEval: 0.3659,
|
114 |
+
temp0_HumanEval_ET: 0.3232,
|
115 |
+
temp0_8_HumanEval: 0.2905,
|
116 |
+
temp0_8_HumanEval_ET: 0.2438,
|
117 |
+
link: 'https://huggingface.co/bigcode/starcoder2-7b',
|
118 |
+
},
|
119 |
+
{
|
120 |
+
name: 'Starcoder2-15b',
|
121 |
+
MGI: 0.0552,
|
122 |
+
temp0_HumanEval: 0.4695,
|
123 |
+
temp0_HumanEval_ET: 0.4024,
|
124 |
+
temp0_8_HumanEval: 0.3406,
|
125 |
+
temp0_8_HumanEval_ET: 0.2795,
|
126 |
+
link: 'https://huggingface.co/bigcode/starcoder2-15b',
|
127 |
+
},
|
128 |
+
{
|
129 |
+
name: 'CodeLlama-13b',
|
130 |
+
MGI: 0.0412,
|
131 |
+
temp0_HumanEval: 0.3415,
|
132 |
+
temp0_HumanEval_ET: 0.2927,
|
133 |
+
temp0_8_HumanEval: 0.2405,
|
134 |
+
temp0_8_HumanEval_ET: 0.2015,
|
135 |
+
link: 'https://huggingface.co/codellama/CodeLlama-13b-hf',
|
136 |
+
},
|
137 |
+
{
|
138 |
+
name: 'CodeLlama-34b',
|
139 |
+
MGI: 0.0651,
|
140 |
+
temp0_HumanEval: 0.4817,
|
141 |
+
temp0_HumanEval_ET: 0.4146,
|
142 |
+
temp0_8_HumanEval: 0.3478,
|
143 |
+
temp0_8_HumanEval_ET: 0.2906,
|
144 |
+
link: 'https://huggingface.co/codellama/CodeLlama-34b-hf',
|
145 |
+
},
|
146 |
+
{
|
147 |
+
name: 'CodeLlama-70b',
|
148 |
+
MGI: 0.0523,
|
149 |
+
temp0_HumanEval: 0.5244,
|
150 |
+
temp0_HumanEval_ET: 0.4512,
|
151 |
+
temp0_8_HumanEval: 0.4317,
|
152 |
+
temp0_8_HumanEval_ET: 0.3615,
|
153 |
+
link: 'https://huggingface.co/codellama/CodeLlama-70b-hf',
|
154 |
+
}
|
155 |
+
]
|
156 |
+
function renderRows(model) {
|
157 |
+
return `
|
158 |
+
<tr>
|
159 |
+
<td><a href=${model.link} target="_blank">${model.name}</a></td>
|
160 |
+
<td class="td_value">${model.MGI}</td>
|
161 |
+
<td class="td_value">${model.temp0_HumanEval}</td>
|
162 |
+
<td class="td_value">${model.temp0_HumanEval_ET}</td>
|
163 |
+
<td class="td_value">${model.temp0_8_HumanEval}</td>
|
164 |
+
<td class="td_value">${model.temp0_8_HumanEval_ET}</td>
|
165 |
+
</tr>
|
166 |
+
`
|
167 |
+
}
|
168 |
+
function renderTables() {
|
169 |
+
let html = ''
|
170 |
+
let rows = models.length + 1
|
171 |
+
html += `
|
172 |
+
<tr>
|
173 |
+
<td class="td_HumanEval" rowspan="${rows}">HumanEval</td>
|
174 |
+
</tr>
|
175 |
+
`
|
176 |
+
models.forEach(model => {
|
177 |
+
html += renderRows(model);
|
178 |
+
});
|
179 |
+
document.querySelector('tbody').innerHTML = html;
|
180 |
+
}
|
181 |
+
|
182 |
+
function adjustBackgroundColor() {
|
183 |
+
var evalTable = document.getElementById('evalTable');
|
184 |
+
var rows = evalTable.getElementsByTagName('tr');
|
185 |
+
for(var i = 0; i < rows.length; i++){
|
186 |
+
rows[i].style.backgroundColor = (i < 3 ? '#ffffff' : (i % 2 === 0 ? '#fbfbfb' : '#ffffff'));
|
187 |
+
}
|
188 |
+
}
|
189 |
+
|
190 |
+
renderTables()
|
191 |
+
adjustBackgroundColor()
|
192 |
+
|
193 |
+
document.querySelector('table').addEventListener('click', (e) => {
|
194 |
+
if (e.target.matches('button')) {
|
195 |
+
let direction = e.target.dataset.direction
|
196 |
+
let type = e.target.dataset.type
|
197 |
+
models.sort(orderBy(direction, type))
|
198 |
+
renderTables()
|
199 |
+
adjustBackgroundColor()
|
200 |
+
e.target.dataset.direction = (direction === 'asc' ? 'desc' : 'asc')
|
201 |
+
e.target.style.transform = (direction === 'asc' ? 'rotate(0deg)' : 'rotate(180deg)')
|
202 |
+
}
|
203 |
+
})
|
204 |
+
|
205 |
+
function orderBy(direction, type) {
|
206 |
+
return function (a, b) {
|
207 |
+
let comparision = 0
|
208 |
+
let value = (direction === 'desc' ? 1 : -1)
|
209 |
+
switch (type) {
|
210 |
+
case 'name':
|
211 |
+
if (a.name.toLowerCase() > b.name.toLowerCase()) {
|
212 |
+
comparision = value
|
213 |
+
} else {
|
214 |
+
comparision = value * -1
|
215 |
+
}
|
216 |
+
break;
|
217 |
+
case 'MGI':
|
218 |
+
if (a.MGI > b.MGI) {
|
219 |
+
comparision = value
|
220 |
+
} else {
|
221 |
+
comparision = value * -1
|
222 |
+
}
|
223 |
+
break;
|
224 |
+
case 'temp0_HumanEval':
|
225 |
+
if (a.temp0_HumanEval > b.temp0_HumanEval) {
|
226 |
+
comparision = value
|
227 |
+
} else {
|
228 |
+
comparision = value * -1
|
229 |
+
}
|
230 |
+
break;
|
231 |
+
case 'temp0_HumanEval_ET':
|
232 |
+
if (a.temp0_HumanEval_ET > b.temp0_HumanEval_ET) {
|
233 |
+
comparision = value
|
234 |
+
} else {
|
235 |
+
comparision = value * -1
|
236 |
+
}
|
237 |
+
break;
|
238 |
+
case 'temp0_8_HumanEval':
|
239 |
+
if (a.temp0_8_HumanEval > b.temp0_8_HumanEval) {
|
240 |
+
comparision = value
|
241 |
+
} else {
|
242 |
+
comparision = value * -1
|
243 |
+
}
|
244 |
+
break;
|
245 |
+
case 'temp0_8_HumanEval_ET':
|
246 |
+
if (a.temp0_8_HumanEval_ET > b.temp0_8_HumanEval_ET) {
|
247 |
+
comparision = value
|
248 |
+
} else {
|
249 |
+
comparision = value * -1
|
250 |
+
}
|
251 |
+
break;
|
252 |
+
}
|
253 |
+
return comparision
|
254 |
+
}
|
255 |
+
}
|
256 |
+
|
257 |
+
var btns = document.getElementsByClassName("button_sort");
|
258 |
+
|
259 |
+
function adjustBtnForm(event) {
|
260 |
+
var btn = event.target;
|
261 |
+
if (btn.classList.contains("button_sort")) {
|
262 |
+
btn.style.borderTop = '8px solid orange';
|
263 |
+
for (var i = 0; i < btns.length; i++) {
|
264 |
+
if (btns[i] !== btn) {
|
265 |
+
btns[i].style.borderTop = '8px solid #9a9a9a';
|
266 |
+
btns[i].style.transform = 'rotate(180deg)';
|
267 |
+
}
|
268 |
+
}
|
269 |
+
}
|
270 |
+
}
|
271 |
+
|
272 |
+
for (var i = 0; i < btns.length; i++) {
|
273 |
+
btns[i].addEventListener("click", adjustBtnForm);
|
274 |
+
}
|