Repository navigation
Expand file tree
/
Copy pathindex.html
More file actions
1021 lines (967 loc) · 74.1 KB
/
Copy pathindex.html
File metadata and controls
1021 lines (967 loc) · 74.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!doctype html>
<html lang="es">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>OpenCode Go Models Benchmarks</title>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500&family=IBM+Plex+Sans:wght@400;500;600&display=swap">
<style>
:root {
color-scheme: light;
--page: #f9f9f7;
--surface: #fcfcfb;
--ink: #0b0b0b;
--ink-2: #52514e;
--muted: #898781;
--grid: #e1e0d9;
--axis: #c3c2b7;
--hair: rgba(11, 11, 11, 0.1);
--accent: #2a78d6;
--accent-wash: rgba(42, 120, 214, 0.1);
--rest: #898781;
--hl-speed: #1baf7a;
--hl-cost: #eb6834;
--good: #0ca30c;
--warning: #b07a00;
--critical: #d03b3b;
--sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
--mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;
}
@media (prefers-color-scheme: dark) {
:root:not([data-theme="light"]) {
color-scheme: dark;
--page: #0d0d0d;
--surface: #1a1a19;
--ink: #ffffff;
--ink-2: #c3c2b7;
--muted: #898781;
--grid: #2c2c2a;
--axis: #383835;
--hair: rgba(255, 255, 255, 0.1);
--accent: #3987e5;
--accent-wash: rgba(57, 135, 229, 0.16);
--rest: #898781;
--hl-speed: #199e70;
--hl-cost: #d95926;
--warning: #fab219;
}
}
:root[data-theme="dark"] {
color-scheme: dark;
--page: #0d0d0d;
--surface: #1a1a19;
--ink: #ffffff;
--ink-2: #c3c2b7;
--muted: #898781;
--grid: #2c2c2a;
--axis: #383835;
--hair: rgba(255, 255, 255, 0.1);
--accent: #3987e5;
--accent-wash: rgba(57, 135, 229, 0.16);
--rest: #898781;
--hl-speed: #199e70;
--hl-cost: #d95926;
--warning: #fab219;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--page); color: var(--ink); font: 14px/1.5 var(--sans); }
.wrap { max-width: 1180px; margin: 0 auto; padding: 32px 24px 56px; display: grid; gap: 20px; }
header { display: grid; gap: 6px; }
.eyebrow { font: 500 11px/1 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
h1 { margin: 0; font-size: 28px; line-height: 1.15; font-weight: 600; letter-spacing: -0.01em; text-wrap: balance; }
.facts { display: flex; flex-wrap: wrap; gap: 6px 20px; color: var(--ink-2); font-size: 13px; }
.facts b { color: var(--ink); font-weight: 600; }
.desc { margin: 2px 0 0; color: var(--ink-2); max-width: 78ch; }
.links { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 13px; }
.links a { color: var(--ink-2); text-decoration: none; border-bottom: 1px solid var(--grid); }
.links a:hover { color: var(--accent); border-color: var(--accent); }
footer a { color: inherit; }
.controls { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.control { display: flex; align-items: center; gap: 8px; }
.control-label { font: 500 11px/1 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.seg { display: inline-flex; border: 1px solid var(--hair); border-radius: 8px; background: var(--surface); padding: 2px; }
.seg button {
font: 500 13px/1 var(--sans); color: var(--ink-2); background: transparent; border: 0; border-radius: 6px;
padding: 7px 11px; cursor: pointer;
}
.seg button:hover { color: var(--ink); }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--surface); }
.check { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--ink-2); cursor: pointer; }
.check input { accent-color: var(--accent); margin: 0; }
button:focus-visible, input:focus-visible, .pt:focus-visible, th button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.card { background: var(--surface); border: 1px solid var(--hair); border-radius: 12px; }
.highlights { position: relative; display: grid; gap: 12px; }
.hl-heading { margin: 0; padding-bottom: 10px; border-bottom: 1px solid var(--grid); font-size: 16px; font-weight: 600; }
.hl-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; }
.hl-card { background: var(--surface); border: 1px solid var(--hair); border-radius: 12px; padding: 18px 18px 6px; display: grid; gap: 4px; align-content: start; }
.hl-top { display: flex; align-items: center; gap: 10px; }
.hl-sq { width: 14px; height: 14px; border-radius: 3px; background: var(--c); flex: none; }
.hl-card h3 { margin: 0; font-size: 22px; font-weight: 600; letter-spacing: -0.01em; }
.hl-pill { margin-left: auto; font-size: 11px; font-weight: 500; color: var(--accent); background: var(--accent-wash); padding: 3px 9px; border-radius: 999px; white-space: nowrap; }
.hl-sub { font-size: 12px; color: var(--ink-2); min-height: 2.5em; }
.hl-plot { min-height: 280px; }
.hl-plot .bar-hit:focus-visible { outline: none; }
.hl-plot .bar-hit:focus-visible + .bar, .hl-plot .bar.hot { filter: brightness(1.12); }
.hl-empty { color: var(--ink-2); font-size: 14px; padding: 12px 0; }
.chart-controls { padding: 0 4px 10px; }
.chart-card { position: relative; padding: 16px 16px 8px; }
.chart-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 16px; padding: 0 4px 6px; }
.chart-title { font-weight: 600; font-size: 15px; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12px; color: var(--ink-2); align-items: center; }
.key { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.key svg { flex: none; width: auto; }
svg { display: block; width: 100%; overflow: visible; }
.empty { padding: 48px 16px; text-align: center; color: var(--ink-2); }
.tip {
position: absolute; pointer-events: none; min-width: 210px; max-width: 280px; padding: 10px 12px;
background: var(--surface); border: 1px solid var(--hair); border-radius: 10px;
box-shadow: 0 6px 24px rgba(0, 0, 0, 0.14); font-size: 12px; display: grid; gap: 6px; z-index: 5;
}
.tip .t-name { font-weight: 600; font-size: 13px; }
.tip .t-var { font: 500 10px/1 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.tip .t-score { font-size: 22px; font-weight: 600; line-height: 1; }
.tip dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 3px 12px; }
.tip dt { color: var(--ink-2); }
.tip dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; font-weight: 500; }
.tip .t-front { display: inline-flex; align-items: center; gap: 6px; color: var(--ink-2); }
.tip .t-cats { color: var(--ink-2); font: 400 11px/1.4 var(--mono); }
.weights { padding: 16px 20px 18px; display: grid; gap: 14px; }
.w-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 10px 16px; }
.w-note { font-size: 12px; color: var(--ink-2); margin-top: 2px; }
.w-note b { color: var(--accent); font-weight: 600; }
.w-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px 20px; }
.w-item { display: grid; gap: 4px; }
.w-label { display: flex; justify-content: space-between; font-size: 13px; color: var(--ink-2); }
.w-label output { font: 500 13px var(--mono); color: var(--ink); font-variant-numeric: tabular-nums; }
.w-item input[type="range"] { width: 100%; accent-color: var(--accent); margin: 0; }
.table-card { min-width: 0; }
.table-scroll { overflow-x: auto; }
.sortbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; padding: 12px 12px 10px; border-bottom: 1px solid var(--grid); }
.sort-chips { display: contents; list-style: none; counter-reset: crit; }
.sort-chip { counter-increment: crit; display: inline-flex; align-items: center; border: 1px solid var(--hair); border-radius: 999px; background: var(--surface); }
.sort-chip::before {
content: counter(crit); display: grid; place-items: center; width: 18px; height: 18px; margin-left: 4px; border-radius: 50%;
background: var(--accent-wash); color: var(--accent); font: 600 10px/1 var(--mono); font-variant-numeric: tabular-nums;
}
.sort-chip button { font: 500 13px/1 var(--sans); color: var(--ink); background: none; border: 0; cursor: pointer; padding: 6px 8px 6px 6px; border-radius: 999px; }
.sort-chip button .arr { color: var(--accent); margin-left: 4px; }
.sort-chip button.x { color: var(--muted); padding: 6px 9px 6px 2px; }
.sort-chip button.x:hover, .sort-chip button:hover { color: var(--accent); }
.sortbar select {
font: 500 13px/1 var(--sans); color: var(--ink-2); background: var(--surface); border: 1px dashed var(--hair);
border-radius: 999px; padding: 6px 10px; cursor: pointer;
}
.sortbar select:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.sortbar .reset { font: 500 12px/1 var(--sans); color: var(--ink-2); background: none; border: 0; cursor: pointer; padding: 6px 4px; text-decoration: underline; text-decoration-color: var(--hair); text-underline-offset: 3px; }
.sortbar .reset:hover { color: var(--accent); }
.sort-hint { margin-left: auto; color: var(--muted); font-size: 12px; }
@media (max-width: 640px) { .sort-hint { display: none; } }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { padding: 9px 12px; text-align: right; white-space: nowrap; border-bottom: 1px solid var(--grid); }
th:nth-child(-n+2), td:nth-child(-n+2) { text-align: left; }
thead th { position: sticky; top: 0; background: var(--surface); font-weight: 500; color: var(--ink-2); }
th button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; user-select: none; }
th button[data-dir]::after { content: attr(data-dir); margin-left: 4px; color: var(--accent); }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: var(--accent-wash); }
td.num { font-variant-numeric: tabular-nums; }
.rank { color: var(--muted); font: 400 12px var(--mono); }
.m-name { font-weight: 500; }
.m-var { font: 500 10px/1 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); margin-left: 8px; }
.score { font-weight: 600; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--rest); vertical-align: middle; }
.dot.front { background: var(--accent); }
.pill { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; color: var(--ink-2); }
.pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--pill, var(--muted)); }
.pill.ok { --pill: var(--good); }
.pill.warn { --pill: var(--warning); }
.pill.bad { --pill: var(--critical); }
.pill.run { --pill: var(--accent); }
footer { color: var(--ink-2); font-size: 12px; display: grid; gap: 4px; max-width: 80ch; }
footer code { font: 12px var(--mono); }
@media (max-width: 640px) { h1 { font-size: 23px; } .wrap { padding: 20px 14px 40px; } }
@media (prefers-reduced-motion: no-preference) { .pt circle.mark { transition: r 120ms ease; } }
</style>
<div class="wrap">
<header>
<div class="eyebrow" id="eyebrow"></div>
<h1 id="title"></h1>
<div class="facts" id="facts"></div>
<p class="desc" id="desc" hidden></p>
<nav class="links" id="links" aria-label="Más información" hidden></nav>
</header>
<div class="controls" id="topctl" role="group" aria-label="Prueba" hidden>
<div class="control" id="testctl"><span class="control-label" id="lt">Prueba</span><div class="seg" id="tseg" role="group" aria-labelledby="lt"></div></div>
</div>
<section class="highlights" aria-labelledby="hl-title">
<h2 class="hl-heading" id="hl-title">Destacados</h2>
<div class="hl-grid" id="hlgrid"></div>
<div class="tip" id="htip" hidden></div>
</section>
<section class="card chart-card" aria-labelledby="chart-title">
<div class="chart-head">
<div class="chart-title" id="chart-title"></div>
<div class="legend" aria-hidden="true">
<span class="key"><svg width="26" height="10"><line x1="1" y1="5" x2="25" y2="5" stroke="var(--accent)" stroke-width="2" stroke-linecap="round"/><circle cx="13" cy="5" r="4" fill="var(--accent)"/></svg>Frontera de eficiencia</span>
<span class="key"><svg width="10" height="10"><circle cx="5" cy="5" r="4" fill="var(--rest)"/></svg>Resto de modelos</span>
</div>
</div>
<div class="controls chart-controls" role="group" aria-label="Opciones del gráfico">
<div class="control"><span class="control-label" id="lx">Eje X</span><div class="seg" id="xseg" role="group" aria-labelledby="lx"></div></div>
<div class="control"><span class="control-label" id="ly">Eje Y</span><div class="seg" id="yseg" role="group" aria-labelledby="ly"></div></div>
<label class="check"><input type="checkbox" id="logx"> Escala logarítmica</label>
</div>
<div id="chart"></div>
<div class="tip" id="tip" hidden></div>
</section>
<section class="card weights" aria-labelledby="w-title">
<div class="w-head">
<div>
<div class="chart-title" id="w-title">Pesos de la nota</div>
<div class="w-note" id="wnote"></div>
</div>
<div class="seg" id="wpresets" role="group" aria-label="Pesos predefinidos"></div>
</div>
<div class="w-grid" id="wgrid"></div>
</section>
<section class="card table-card" aria-label="Clasificación">
<div class="sortbar" id="sortbar" role="group" aria-label="Orden de la tabla"></div>
<div class="table-scroll">
<table>
<thead><tr id="thead"></tr></thead>
<tbody id="tbody"></tbody>
</table>
</div>
</section>
<footer id="notes"></footer>
</div>
<script>
const DATA = {"siteTitle":"OpenCode Go Models Benchmarks","repoUrl":"https://github.com/rldona/opencode-models-benchmarks","tests":[{"test":"rrule","short":"RRULE","title":"Clasificación RRULE","description":"Expansor de eventos recurrentes (subconjunto de RRULE: DAILY/WEEKLY/MONTHLY, INTERVAL, BYDAY con 2TU/-1FR, COUNT, UNTIL) en TypeScript + Vitest, respetando la hora local con zonas IANA y cambios de hora.","generatedAt":"2026-09-11T14:57:02.176Z","hiddenTotal":19,"judge":"claude:sonnet","weights":{"correctness":4,"autonomy":1,"ownTests":2,"codeQuality":2,"robustness":1},"models":[{"slug":"deepseek-v4-pro","name":"DeepSeek V4 Pro (New)","provider":"DeepSeek","stopped":null,"progress":null,"variant":"max","status":"scored","score":9.4,"hidden":{"passed":19,"total":19},"categories":null,"code":8,"tests":8,"cost":0.08126962799999998,"tokensOut":29824,"steps":14,"activeMs":406799,"interventions":0,"fractions":{"correctness":1,"autonomy":1,"ownTests":0.88,"codeQuality":0.8,"robustness":1},"penalty":0},{"slug":"deepseek-v4.1-flash","name":"DeepSeek V4.1 Flash","provider":"DeepSeek","stopped":null,"progress":null,"variant":"max","status":"scored","score":9.8,"hidden":{"passed":19,"total":19},"categories":null,"code":9,"tests":9,"cost":0.029964941999999998,"tokensOut":41286,"steps":16,"activeMs":209658,"interventions":0,"fractions":{"correctness":1,"autonomy":1,"ownTests":0.98,"codeQuality":0.9,"robustness":1},"penalty":0},{"slug":"glm-5.3","name":"GLM-5.3","provider":"Z.ai (Zhipu)","stopped":null,"progress":null,"variant":"max","status":"scored","score":9.8,"hidden":{"passed":19,"total":19},"categories":null,"code":9,"tests":9,"cost":0.5837162199999999,"tokensOut":79451,"steps":8,"activeMs":920208,"interventions":0,"fractions":{"correctness":1,"autonomy":1,"ownTests":0.98,"codeQuality":0.9,"robustness":1},"penalty":0},{"slug":"glm-5.3-flash","name":"GLM-5.3-Flash","provider":"Z.ai (Zhipu)","stopped":null,"progress":null,"variant":"max","status":"scored","score":9.6,"hidden":{"passed":19,"total":19},"categories":null,"code":8,"tests":9,"cost":0.07968183000000001,"tokensOut":58827,"steps":20,"activeMs":631841,"interventions":0,"fractions":{"correctness":1,"autonomy":1,"ownTests":0.98,"codeQuality":0.8,"robustness":1},"penalty":0},{"slug":"gpt-5.6-luna","name":"GPT-5.6 Luna","provider":"OpenAI","stopped":null,"progress":null,"variant":"max","status":"scored","score":9.6,"hidden":{"passed":19,"total":19},"categories":null,"code":9,"tests":9,"cost":0.06766347,"tokensOut":33646,"steps":18,"activeMs":371573,"interventions":0,"fractions":{"correctness":1,"autonomy":1,"ownTests":0.9,"codeQuality":0.9,"robustness":1},"penalty":0},{"slug":"grok-4.6","name":"Grok 4.6","provider":"xAI","stopped":null,"progress":null,"variant":"xhigh","status":"scored","score":9.2,"hidden":{"passed":19,"total":19},"categories":null,"code":8,"tests":7,"cost":0.437168,"tokensOut":30283,"steps":11,"activeMs":475690,"interventions":0,"fractions":{"correctness":1,"autonomy":1,"ownTests":0.78,"codeQuality":0.8,"robustness":1},"penalty":0},{"slug":"hy4-preview","name":"Hy4 preview","provider":"Tencent","stopped":null,"progress":null,"variant":"high","status":"scored","score":9.8,"hidden":{"passed":19,"total":19},"categories":null,"code":9,"tests":9,"cost":0.24321272400000005,"tokensOut":40806,"steps":40,"activeMs":749036,"interventions":0,"fractions":{"correctness":1,"autonomy":1,"ownTests":0.98,"codeQuality":0.9,"robustness":1},"penalty":0},{"slug":"kimi-k2.7-code","name":"Kimi K2.7 Code","provider":"Moonshot AI","stopped":null,"progress":null,"variant":"default","status":"scored","score":8.9,"hidden":{"passed":18,"total":19},"categories":null,"code":7,"tests":8,"cost":0.19330973999999998,"tokensOut":20457,"steps":22,"activeMs":521068,"interventions":0,"fractions":{"correctness":0.95,"autonomy":1,"ownTests":0.85,"codeQuality":0.7,"robustness":1},"penalty":0},{"slug":"kimi-k3","name":"Kimi K3","provider":"Moonshot AI","stopped":null,"progress":null,"variant":"max","status":"scored","score":8.9,"hidden":{"passed":16,"total":19},"categories":null,"code":8,"tests":9,"cost":0.47823840000000006,"tokensOut":19867,"steps":18,"activeMs":659566,"interventions":0,"fractions":{"correctness":0.84,"autonomy":1,"ownTests":0.95,"codeQuality":0.8,"robustness":1},"penalty":0},{"slug":"longcat-2.0","name":"LongCat-2.0","provider":"Meituan","stopped":null,"progress":null,"variant":"high","status":"scored","score":7.9,"hidden":{"passed":17,"total":19},"categories":null,"code":4,"tests":6,"cost":0.114126264,"tokensOut":62714,"steps":30,"activeMs":1252791,"interventions":0,"fractions":{"correctness":0.9,"autonomy":1,"ownTests":0.75,"codeQuality":0.4,"robustness":1},"penalty":0},{"slug":"mimo-v2.5","name":"MiMo V2.5","provider":"Xiaomi","stopped":null,"progress":null,"variant":"default","status":"scored","score":8.7,"hidden":{"passed":16,"total":19},"categories":null,"code":7,"tests":8,"cost":0.0167708968,"tokensOut":29755,"steps":26,"activeMs":310630,"interventions":0,"fractions":{"correctness":0.84,"autonomy":1,"ownTests":0.95,"codeQuality":0.7,"robustness":1},"penalty":0},{"slug":"mimo-v2.5-pro","name":"MiMo V2.5 Pro","provider":"Xiaomi","stopped":null,"progress":null,"variant":"default","status":"scored","score":8.2,"hidden":{"passed":13,"total":19},"categories":null,"code":8,"tests":8,"cost":0.048458072,"tokensOut":24949,"steps":44,"activeMs":453409,"interventions":0,"fractions":{"correctness":0.69,"autonomy":1,"ownTests":0.95,"codeQuality":0.8,"robustness":1},"penalty":0},{"slug":"minimax-m2.7","name":"MiniMax-M2.7","provider":"MiniMax","stopped":null,"progress":null,"variant":"default","status":"scored","score":5.5,"hidden":{"passed":9,"total":19},"categories":null,"code":6,"tests":6,"cost":0.20297640000000008,"tokensOut":68701,"steps":60,"activeMs":1851802,"interventions":2,"fractions":{"correctness":0.47,"autonomy":0,"ownTests":0.83,"codeQuality":0.6,"robustness":0.75},"penalty":0},{"slug":"minimax-m3","name":"MiniMax-M3","provider":"MiniMax","stopped":null,"progress":null,"variant":"thinking","status":"scored","score":9.1,"hidden":{"passed":17,"total":19},"categories":null,"code":8,"tests":8,"cost":0.15000402,"tokensOut":48225,"steps":40,"activeMs":409404,"interventions":0,"fractions":{"correctness":0.9,"autonomy":1,"ownTests":0.95,"codeQuality":0.8,"robustness":1},"penalty":0},{"slug":"muse-spark-1.3-contributor","name":"Muse Spark 1.3 Contributor","provider":"Meta","stopped":null,"progress":null,"variant":"xhigh","status":"scored","score":8.1,"hidden":{"passed":14,"total":19},"categories":null,"code":7,"tests":8,"cost":0.010993684,"tokensOut":24854,"steps":26,"activeMs":221415,"interventions":0,"fractions":{"correctness":0.74,"autonomy":1,"ownTests":0.9,"codeQuality":0.7,"robustness":1},"penalty":0},{"slug":"qwen3.6-plus","name":"Qwen3.6 Plus","provider":"Alibaba (Qwen)","stopped":null,"progress":null,"variant":"default","status":"scored","score":7.3,"hidden":{"passed":13,"total":19},"categories":null,"code":5,"tests":7,"cost":0.18085400000000001,"tokensOut":11785,"steps":20,"activeMs":255026,"interventions":0,"fractions":{"correctness":0.69,"autonomy":1,"ownTests":0.93,"codeQuality":0.5,"robustness":0.75},"penalty":0},{"slug":"qwen3.7-max","name":"Qwen3.7 Max","provider":"Alibaba (Qwen)","stopped":null,"progress":null,"variant":"default","status":"scored","score":8.6,"hidden":{"passed":17,"total":19},"categories":null,"code":7,"tests":6,"cost":0.46052200000000004,"tokensOut":22884,"steps":16,"activeMs":285286,"interventions":0,"fractions":{"correctness":0.9,"autonomy":1,"ownTests":0.83,"codeQuality":0.7,"robustness":1},"penalty":0},{"slug":"qwen3.7-plus","name":"Qwen3.7 Plus","provider":"Alibaba (Qwen)","stopped":null,"progress":null,"variant":"default","status":"scored","score":8.5,"hidden":{"passed":17,"total":19},"categories":null,"code":6,"tests":7,"cost":0.14177295999999998,"tokensOut":27821,"steps":36,"activeMs":449686,"interventions":0,"fractions":{"correctness":0.9,"autonomy":1,"ownTests":0.85,"codeQuality":0.6,"robustness":1},"penalty":0},{"slug":"qwen3.8-flash","name":"Qwen3.8 Flash","provider":"Alibaba (Qwen)","stopped":null,"progress":null,"variant":"xhigh","status":"scored","score":9.5,"hidden":{"passed":18,"total":19},"categories":null,"code":9,"tests":9,"cost":0.141699528,"tokensOut":83936,"steps":76,"activeMs":1561506,"interventions":0,"fractions":{"correctness":0.95,"autonomy":1,"ownTests":0.98,"codeQuality":0.9,"robustness":1},"penalty":0},{"slug":"qwen3.8-max","name":"Qwen3.8 Max","provider":"Alibaba (Qwen)","stopped":"detenido a mano por tardar demasiado (24 min, $0,84): código completo y tsc limpio, sin tests ni README","progress":70,"variant":"xhigh","status":"stopped","score":6.3,"hidden":{"passed":19,"total":19},"categories":null,"code":9,"tests":0,"cost":0.842494,"tokensOut":59192,"steps":33,"activeMs":1709884,"interventions":0,"fractions":{"correctness":1,"autonomy":0,"ownTests":0,"codeQuality":0.9,"robustness":0.5},"penalty":0}],"links":[["Tabla completa","https://github.com/rldona/opencode-models-benchmarks/blob/main/benchmarks/rrule/RESULTS.md"],["Detalle y comentarios del juez","https://github.com/rldona/opencode-models-benchmarks/blob/main/benchmarks/rrule/DETAILS.md"],["Enunciado","https://github.com/rldona/opencode-models-benchmarks/blob/main/benchmarks/rrule/PROMPT.md"],["Cómo se calcula la nota","https://github.com/rldona/opencode-models-benchmarks/blob/main/benchmarks/rrule/RUBRIC.md"]]},{"test":"regex","short":"Regex","title":"Clasificación Regex","description":"Motor de expresiones regulares compatible con JavaScript sin usar RegExp: semántica exacta de ECMAScript (capturas, perezosos, Unicode, i, lastIndex), tiempo lineal ante patrones patológicos, streaming que devuelve cada coincidencia en cuanto es definitiva y tipos de TypeScript deducidos del patrón.","generatedAt":"2026-09-11T20:44:36.206Z","hiddenTotal":561,"judge":"claude:sonnet","weights":{"correctness":6,"autonomy":1,"ownTests":1,"codeQuality":1.5,"robustness":0.5},"models":[{"slug":"deepseek-v4-pro","name":"DeepSeek V4 Pro (New)","provider":"DeepSeek","stopped":null,"progress":null,"variant":"max","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"deepseek-v4.1-flash","name":"DeepSeek V4.1 Flash","provider":"DeepSeek","stopped":null,"progress":null,"variant":"max","status":"scored","score":8.7,"hidden":{"passed":554,"total":561},"categories":"capturas 37/37 · cuantificadores 19/19 · alternancia 8/8 · clases 23/25 · anclas 19/19 · flags 14/14 · mayusculas 38/38 · unicode 23/23 · retro 22/22 · lookahead 15/15 · sintaxis 22/22 · azar 148/150 · azar-retro 35/35 · streaming 45/45 · a-tiempo 32/32 · rendimiento 14/14 · tipos 40/43","code":9,"tests":8,"cost":0.5040555120000004,"tokensOut":393069,"steps":248,"activeMs":4039952,"interventions":0,"fractions":{"correctness":0.99,"autonomy":1,"ownTests":0.95,"codeQuality":0.9,"robustness":1},"penalty":-1},{"slug":"glm-5.3","name":"GLM-5.3","provider":"Z.ai (Zhipu)","stopped":null,"progress":null,"variant":"max","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"glm-5.3-flash","name":"GLM-5.3-Flash","provider":"Z.ai (Zhipu)","stopped":null,"progress":null,"variant":"max","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"gpt-5.6-luna","name":"GPT-5.6 Luna","provider":"OpenAI","stopped":null,"progress":null,"variant":"max","status":"scored","score":8.7,"hidden":{"passed":540,"total":561},"categories":"capturas 37/37 · cuantificadores 19/19 · alternancia 8/8 · clases 25/25 · anclas 19/19 · flags 14/14 · mayusculas 38/38 · unicode 23/23 · retro 21/22 · lookahead 15/15 · sintaxis 22/22 · azar 139/150 · azar-retro 31/35 · streaming 43/45 · a-tiempo 31/32 · rendimiento 12/14 · tipos 43/43","code":4,"tests":8,"cost":0.5854735299999998,"tokensOut":133137,"steps":178,"activeMs":1837116,"interventions":0,"fractions":{"correctness":0.95,"autonomy":1,"ownTests":0.95,"codeQuality":0.4,"robustness":1},"penalty":0},{"slug":"grok-4.6","name":"Grok 4.6","provider":"xAI","stopped":null,"progress":null,"variant":"xhigh","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"hy4-preview","name":"Hy4 preview","provider":"Tencent","stopped":null,"progress":null,"variant":"high","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"kimi-k2.7-code","name":"Kimi K2.7 Code","provider":"Moonshot AI","stopped":null,"progress":null,"variant":"default","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"kimi-k3","name":"Kimi K3","provider":"Moonshot AI","stopped":null,"progress":null,"variant":"max","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"longcat-2.0","name":"LongCat-2.0","provider":"Meituan","stopped":null,"progress":null,"variant":"high","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"mimo-v2.5","name":"MiMo V2.5","provider":"Xiaomi","stopped":null,"progress":null,"variant":"default","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"mimo-v2.5-pro","name":"MiMo V2.5 Pro","provider":"Xiaomi","stopped":null,"progress":null,"variant":"default","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"minimax-m2.7","name":"MiniMax-M2.7","provider":"MiniMax","stopped":null,"progress":null,"variant":"default","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"minimax-m3","name":"MiniMax-M3","provider":"MiniMax","stopped":null,"progress":null,"variant":"thinking","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"muse-spark-1.3-contributor","name":"Muse Spark 1.3 Contributor","provider":"Meta","stopped":null,"progress":null,"variant":"xhigh","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"qwen3.6-plus","name":"Qwen3.6 Plus","provider":"Alibaba (Qwen)","stopped":null,"progress":null,"variant":"default","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"qwen3.7-max","name":"Qwen3.7 Max","provider":"Alibaba (Qwen)","stopped":null,"progress":null,"variant":"default","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"qwen3.7-plus","name":"Qwen3.7 Plus","provider":"Alibaba (Qwen)","stopped":null,"progress":null,"variant":"default","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"qwen3.8-flash","name":"Qwen3.8 Flash","provider":"Alibaba (Qwen)","stopped":null,"progress":null,"variant":"xhigh","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"qwen3.8-max","name":"Qwen3.8 Max","provider":"Alibaba (Qwen)","stopped":null,"progress":null,"variant":"xhigh","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0}],"links":[["Tabla completa","https://github.com/rldona/opencode-models-benchmarks/blob/main/benchmarks/regex/RESULTS.md"],["Detalle y comentarios del juez","https://github.com/rldona/opencode-models-benchmarks/blob/main/benchmarks/regex/DETAILS.md"],["Enunciado","https://github.com/rldona/opencode-models-benchmarks/blob/main/benchmarks/regex/PROMPT.md"],["Cómo se calcula la nota","https://github.com/rldona/opencode-models-benchmarks/blob/main/benchmarks/regex/RUBRIC.md"]]},{"test":"sql","short":"SQL","title":"Clasificación SQL","description":"Motor SQL en memoria con semántica de SQLite: SELECT con JOIN/LEFT JOIN, GROUP BY/HAVING, ORDER BY, LIMIT/OFFSET, NULL con lógica de tres valores, enteros frente a reales y rendimiento con 100.000 filas.","generatedAt":"2026-09-11T16:24:02.631Z","hiddenTotal":173,"judge":"claude:sonnet","weights":{"correctness":5,"autonomy":1,"ownTests":1.5,"codeQuality":2,"robustness":0.5},"models":[{"slug":"deepseek-v4-pro","name":"DeepSeek V4 Pro (New)","provider":"DeepSeek","stopped":null,"progress":null,"variant":"max","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"deepseek-v4.1-flash","name":"DeepSeek V4.1 Flash","provider":"DeepSeek","stopped":null,"progress":null,"variant":"max","status":"scored","score":9.8,"hidden":{"passed":173,"total":173},"categories":"expr 37/37 · null 27/27 · where 21/21 · join 25/25 · group 25/25 · order 22/22 · error 11/11 · perf 5/5","code":9,"tests":9,"cost":0.080853372,"tokensOut":109000,"steps":35,"activeMs":526596,"interventions":0,"fractions":{"correctness":1,"autonomy":1,"ownTests":0.97,"codeQuality":0.9,"robustness":1},"penalty":0},{"slug":"glm-5.3-flash","name":"GLM-5.3-Flash","provider":"Z.ai (Zhipu)","stopped":null,"progress":null,"variant":"max","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"gpt-5.6-luna","name":"GPT-5.6 Luna","provider":"OpenAI","stopped":null,"progress":null,"variant":"max","status":"scored","score":9.6,"hidden":{"passed":172,"total":173},"categories":"expr 36/37 · null 27/27 · where 21/21 · join 25/25 · group 25/25 · order 22/22 · error 11/11 · perf 5/5","code":9,"tests":9,"cost":0.19167852,"tokensOut":80667,"steps":46,"activeMs":943590,"interventions":0,"fractions":{"correctness":0.99,"autonomy":1,"ownTests":0.97,"codeQuality":0.9,"robustness":0.7},"penalty":0},{"slug":"grok-4.6","name":"Grok 4.6","provider":"xAI","stopped":null,"progress":null,"variant":"xhigh","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"hy4-preview","name":"Hy4 preview","provider":"Tencent","stopped":"detenido a mano por tardar demasiado (≈35 min): código y 81 tests en verde, le faltaba corregir 1 error de tsc","progress":95,"variant":"high","status":"stopped","score":8.5,"hidden":{"passed":172,"total":173},"categories":"expr 36/37 · null 27/27 · where 21/21 · join 25/25 · group 25/25 · order 22/22 · error 11/11 · perf 5/5","code":9,"tests":9,"cost":0.6937334970000004,"tokensOut":94827,"steps":88,"activeMs":2209474,"interventions":0,"fractions":{"correctness":0.99,"autonomy":0,"ownTests":0.97,"codeQuality":0.9,"robustness":0.5},"penalty":0},{"slug":"kimi-k2.7-code","name":"Kimi K2.7 Code","provider":"Moonshot AI","stopped":null,"progress":null,"variant":"default","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"kimi-k3","name":"Kimi K3","provider":"Moonshot AI","stopped":null,"progress":null,"variant":"max","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"longcat-2.0","name":"LongCat-2.0","provider":"Meituan","stopped":null,"progress":null,"variant":"high","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"mimo-v2.5","name":"MiMo V2.5","provider":"Xiaomi","stopped":null,"progress":null,"variant":"default","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"mimo-v2.5-pro","name":"MiMo V2.5 Pro","provider":"Xiaomi","stopped":null,"progress":null,"variant":"default","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"minimax-m2.7","name":"MiniMax-M2.7","provider":"MiniMax","stopped":null,"progress":null,"variant":"default","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"minimax-m3","name":"MiniMax-M3","provider":"MiniMax","stopped":null,"progress":null,"variant":"thinking","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"muse-spark-1.3-contributor","name":"Muse Spark 1.3 Contributor","provider":"Meta","stopped":null,"progress":null,"variant":"xhigh","status":"scored","score":9.5,"hidden":{"passed":173,"total":173},"categories":"expr 37/37 · null 27/27 · where 21/21 · join 25/25 · group 25/25 · order 22/22 · error 11/11 · perf 5/5","code":8,"tests":8,"cost":0.048629743999999996,"tokensOut":92300,"steps":53,"activeMs":641163,"interventions":0,"fractions":{"correctness":1,"autonomy":1,"ownTests":0.95,"codeQuality":0.8,"robustness":1},"penalty":0},{"slug":"qwen3.6-plus","name":"Qwen3.6 Plus","provider":"Alibaba (Qwen)","stopped":null,"progress":null,"variant":"default","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"qwen3.7-max","name":"Qwen3.7 Max","provider":"Alibaba (Qwen)","stopped":null,"progress":null,"variant":"default","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"qwen3.7-plus","name":"Qwen3.7 Plus","provider":"Alibaba (Qwen)","stopped":null,"progress":null,"variant":"default","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"qwen3.8-flash","name":"Qwen3.8 Flash","provider":"Alibaba (Qwen)","stopped":null,"progress":null,"variant":"xhigh","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0},{"slug":"qwen3.8-max","name":"Qwen3.8 Max","provider":"Alibaba (Qwen)","stopped":null,"progress":null,"variant":"xhigh","status":"pending","score":null,"hidden":null,"categories":null,"code":null,"tests":null,"cost":null,"tokensOut":null,"steps":null,"activeMs":null,"interventions":null,"fractions":null,"penalty":0}],"links":[["Tabla completa","https://github.com/rldona/opencode-models-benchmarks/blob/main/benchmarks/sql/RESULTS.md"],["Detalle y comentarios del juez","https://github.com/rldona/opencode-models-benchmarks/blob/main/benchmarks/sql/DETAILS.md"],["Enunciado","https://github.com/rldona/opencode-models-benchmarks/blob/main/benchmarks/sql/PROMPT.md"],["Cómo se calcula la nota","https://github.com/rldona/opencode-models-benchmarks/blob/main/benchmarks/sql/RUBRIC.md"]]}]};
// Una o varias pruebas: { tests: [...] , repoUrl? }. El hash (#sql) elige la prueba.
const TESTS = DATA.tests ?? [DATA];
let cur = TESTS.find((t) => '#' + t.test === location.hash) ?? TESTS[0];
const NS = 'http://www.w3.org/2000/svg';
const nf = (d) => new Intl.NumberFormat('es-ES', { maximumFractionDigits: d, minimumFractionDigits: d });
const fmt = {
cost: (v) => (v == null ? '—' : v === 0 ? '$0' : '$' + (v < 0.1 ? nf(4) : nf(2)).format(v)),
tokens: (v) => (v == null ? '—' : v >= 1e6 ? nf(2).format(v / 1e6) + ' M' : v >= 1e3 ? nf(1).format(v / 1e3) + ' k' : String(v)),
steps: (v) => (v == null ? '—' : String(v)),
time: (ms) => {
if (ms == null) return '—';
const s = Math.round(ms / 1000), m = Math.floor(s / 60);
return m ? `${m} min ${String(s % 60).padStart(2, '0')} s` : `${s} s`;
},
score: (v) => (v == null ? '—' : nf(1).format(v)),
pct: (v) => (v == null ? '—' : nf(0).format(v) + ' %'),
};
const X = {
cost: { label: 'Coste', title: 'coste por tarea', get: (m) => m.cost, f: fmt.cost, unit: 'USD, precio de lista según opencode' },
tokens: { label: 'Tokens generados', title: 'tokens generados', get: (m) => m.tokensOut, f: fmt.tokens, unit: 'salida + razonamiento' },
steps: { label: 'Pasos', title: 'pasos del agente', get: (m) => m.steps, f: fmt.steps, unit: 'llamadas al modelo' },
time: { label: 'Tiempo', title: 'tiempo activo', get: (m) => m.activeMs, f: fmt.time, unit: 'minutos' },
};
const Y = {
score: { label: 'Nota', title: 'Nota (0–10)', get: (m) => scoreOf(m), f: fmt.score, max: 10 },
hidden: { label: 'Suite oculta', title: 'Suite oculta (% de casos)', get: (m) => (m.hidden ? (100 * m.hidden.passed) / m.hidden.total : null), f: fmt.pct, max: 100 },
};
const store = {
get(k, d) { try { return localStorage.getItem('rep:' + k) ?? d; } catch { return d; } },
set(k, v) { try { localStorage.setItem('rep:' + k, v); } catch {} },
};
// sort: criterios de la tabla en orden de prioridad [{ k, dir }] (se carga al dibujarla por primera vez).
const state = { x: store.get('x', 'cost'), y: store.get('y', 'score'), log: store.get('log', '0') === '1', sort: null };
if (!X[state.x]) state.x = 'cost';
if (!Y[state.y]) state.y = 'score';
// ---------- pesos de la nota ----------
// La nota oficial usa los pesos de bench.json. El lector puede cambiarlos: cada modelo trae la proporción que
// consiguió en cada bloque (0-1) y la nota se recalcula reescalada a 0-10 (más la penalización, si la hay).
const BLOCKS = [
['correctness', 'Corrección (suite oculta)'],
['autonomy', 'Autonomía'],
['ownTests', 'Tests propios'],
['codeQuality', 'Calidad de código'],
['robustness', 'Robustez'],
];
const PRESETS = [
['Oficial', null],
['Solo suite oculta', { correctness: 1 }],
['Código y tests', { ownTests: 1, codeQuality: 1 }],
['Sin juez', { correctness: 1, autonomy: 1, robustness: 1 }],
];
const weights = {};
function wOf(test) {
if (!weights[test.test]) {
let saved = null;
try { saved = JSON.parse(localStorage.getItem('rep:w:' + test.test) || 'null'); } catch {}
weights[test.test] = { ...test.weights, ...(saved ?? {}) };
}
return weights[test.test];
}
function saveW() { try { localStorage.setItem('rep:w:' + cur.test, JSON.stringify(wOf(cur))); } catch {} }
const isCustom = () => BLOCKS.some(([k]) => Number(wOf(cur)[k] ?? 0) !== Number(cur.weights[k] ?? 0));
function scoreOf(m) {
if (m.score == null) return null;
if (!isCustom() || !m.fractions) return m.score;
const w = wOf(cur);
const sum = BLOCKS.reduce((a, [k]) => a + Number(w[k] || 0), 0);
if (!sum) return null;
const raw = (BLOCKS.reduce((a, [k]) => a + Number(w[k] || 0) * (m.fractions[k] ?? 0), 0) / sum) * 10 + (m.penalty || 0);
return Math.round(Math.max(0, Math.min(10, raw)) * 10) / 10;
}
// Pesos de un preset repartidos para sumar 10, en pasos de 0,5 como los deslizadores (Oficial = bench.json).
function presetTarget(p) {
if (!p) return cur.weights;
const total = Object.values(p).reduce((a, b) => a + b, 0);
return Object.fromEntries(BLOCKS.map(([k]) => [k, Math.round(((p[k] ?? 0) * 10) / total * 2) / 2]));
}
function weightsPanel() {
const grid = document.getElementById('wgrid');
grid.replaceChildren();
const w = wOf(cur);
for (const [k, label] of BLOCKS) {
const item = el('div', { class: 'w-item' });
const id = 'w-' + k;
const lab = el('label', { class: 'w-label', for: id });
const out = el('output', { for: id }, String(w[k] ?? 0));
lab.append(label, out);
const input = el('input', { type: 'range', id, min: '0', max: '10', step: '0.5', value: String(w[k] ?? 0) });
input.addEventListener('input', () => {
w[k] = Number(input.value);
out.textContent = input.value;
saveW();
afterWeights();
});
item.append(lab, input);
grid.append(item);
}
const pre = document.getElementById('wpresets');
pre.replaceChildren();
for (const [name, p] of PRESETS) {
const target = presetTarget(p);
const active = BLOCKS.every(([k]) => Number(w[k] ?? 0) === Number(target[k] ?? 0));
const b = el('button', { type: 'button', 'aria-pressed': String(active) }, name);
b.addEventListener('click', () => {
for (const [k] of BLOCKS) w[k] = Number(target[k] ?? 0);
saveW();
weightsPanel();
afterWeights();
});
pre.append(b);
}
noteW();
}
function noteW() {
const n = document.getElementById('wnote');
n.replaceChildren();
const sum = BLOCKS.reduce((a, [k]) => a + Number(wOf(cur)[k] || 0), 0);
if (isCustom()) {
n.append(el('b', {}, 'Pesos personalizados'), ` · suman ${fmt.score(sum)}; la nota se reescala a 0–10. La tabla y el gráfico usan esta nota.`);
} else {
n.append('Pesos oficiales de la prueba. Muévelos para ver cómo cambia la clasificación.');
}
}
function afterWeights() {
noteW();
header();
render();
// Resalta el preset que coincida (sin reconstruir los deslizadores mientras se arrastran).
const w = wOf(cur);
const btns = document.getElementById('wpresets').children;
PRESETS.forEach(([, p], i) => {
const target = presetTarget(p);
btns[i]?.setAttribute('aria-pressed', String(BLOCKS.every(([k]) => Number(w[k] ?? 0) === Number(target[k] ?? 0))));
});
}
const el = (tag, attrs = {}, text) => {
const n = document.createElement(tag);
for (const [k, v] of Object.entries(attrs)) n.setAttribute(k, v);
if (text != null) n.textContent = text;
return n;
};
const sv = (tag, attrs = {}) => {
const n = document.createElementNS(NS, tag);
for (const [k, v] of Object.entries(attrs)) n.setAttribute(k, v);
return n;
};
// ---------- cabecera ----------
function header() {
document.getElementById('facts').replaceChildren();
const desc = document.getElementById('desc');
desc.textContent = cur.description ?? '';
desc.hidden = !cur.description;
const links = document.getElementById('links');
links.replaceChildren(...(cur.links ?? []).map(([label, href]) => el('a', { href }, label)));
links.hidden = !(cur.links ?? []).length;
document.getElementById('eyebrow').textContent = `${DATA.eyebrow ?? 'Benchmark de modelos de programación'} · prueba ${cur.short ?? cur.test}`;
document.getElementById('title').textContent = DATA.siteTitle ?? cur.title;
const scored = cur.models.filter((m) => scoreOf(m) != null);
const best = [...scored].sort((a, b) => scoreOf(b) - scoreOf(a))[0];
const facts = document.getElementById('facts');
const add = (label, value) => {
const s = el('span');
s.append(label + ' ');
s.append(el('b', {}, value));
facts.append(s);
};
add('Modelos con nota', `${scored.length} de ${cur.models.length}`);
if (best) add('Mejor nota', `${best.name} · ${fmt.score(scoreOf(best))}`);
add('Suite oculta', `${cur.hiddenTotal} casos`);
add('Juez', cur.judge);
if (cur.generatedAt) add('Actualizado', new Date(cur.generatedAt).toLocaleString('es-ES', { dateStyle: 'medium', timeStyle: 'short' }));
}
// ---------- controles ----------
function controls() {
const seg = (id, opts, key) => {
const box = document.getElementById(id);
box.replaceChildren();
for (const [k, o] of Object.entries(opts)) {
const b = el('button', { type: 'button', 'aria-pressed': String(state[key] === k) }, o.label);
b.addEventListener('click', () => {
state[key] = k;
store.set(key, k);
controls();
render();
});
box.append(b);
}
};
document.getElementById('topctl').hidden = TESTS.length < 2;
const tseg = document.getElementById('tseg');
tseg.replaceChildren();
for (const t of TESTS) {
const b = el('button', { type: 'button', 'aria-pressed': String(t === cur) }, t.short ?? t.test.toUpperCase());
b.addEventListener('click', () => selectTest(t));
tseg.append(b);
}
seg('xseg', X, 'x');
seg('yseg', Y, 'y');
const log = document.getElementById('logx');
log.checked = state.log;
log.onchange = () => {
state.log = log.checked;
store.set('log', log.checked ? '1' : '0');
render();
};
}
// ---------- escalas ----------
function niceStep(span, target) {
const raw = span / target, mag = 10 ** Math.floor(Math.log10(raw)), r = raw / mag;
return (r >= 5 ? 10 : r >= 2 ? 5 : r >= 1 ? 2 : 1) * mag;
}
function linTicks(lo, hi, n) {
const st = niceStep(hi - lo, n), out = [];
for (let v = Math.ceil(lo / st) * st; v <= hi + st * 1e-9; v += st) out.push(+v.toPrecision(12));
return out;
}
function logTicks(lo, hi) {
const out = [];
for (let e = Math.floor(Math.log10(lo)); e <= Math.ceil(Math.log10(hi)); e++)
for (const m of [1, 2, 5]) { const v = m * 10 ** e; if (v >= lo * 0.999 && v <= hi * 1.001) out.push(v); }
return out;
}
// Frontera de Pareto: nadie tiene a la vez más (o igual) Y y menos (o igual) X.
function frontier(points) {
const s = [...points].sort((a, b) => a.x - b.x || b.y - a.y);
const out = new Set();
let best = -Infinity;
for (const p of s) if (p.y > best) { out.add(p.m.slug); best = p.y; }
return out;
}
let points = [], front = new Set();
// ---------- destacados (top 10 por métrica, estilo "highlights") ----------
const HL = [
{ title: 'Nota', color: 'var(--accent)', sub: () => (isCustom() ? 'Nota 0–10 con tus pesos · más es mejor' : 'Nota 0–10 · más es mejor'),
get: (m) => scoreOf(m), f: (v) => nf(1).format(v), asc: false },
{ title: 'Velocidad', color: 'var(--hl-speed)', sub: () => 'Tokens generados por segundo de trabajo del agente · más es mejor',
get: (m) => (m.tokensOut && m.activeMs ? m.tokensOut / (m.activeMs / 1000) : null), f: (v) => nf(0).format(v), asc: false },
{ title: 'Coste por tarea', color: 'var(--hl-cost)', sub: () => 'USD por tarea, precio de lista según opencode · menos es mejor',
get: (m) => m.cost, f: (v) => (v < 0.1 ? nf(3) : nf(2)).format(v), tipF: (v) => fmt.cost(v), asc: true },
];
function drawHighlights() {
const grid = document.getElementById('hlgrid');
grid.replaceChildren();
hideHTip();
const models = cur.models.filter((m) => scoreOf(m) != null);
if (!models.length) {
grid.append(el('div', { class: 'hl-empty' }, 'Todavía no hay modelos con nota en esta prueba.'));
return;
}
HL.forEach((h, i) => {
const card = el('article', { class: 'hl-card', style: `--c:${h.color}` });
const top = el('div', { class: 'hl-top' });
top.append(el('span', { class: 'hl-sq', 'aria-hidden': 'true' }), el('h3', {}, h.title));
if (i === 0 && cur.generatedAt) top.append(el('span', { class: 'hl-pill' }, 'Actualizado ' + new Date(cur.generatedAt).toLocaleDateString('es-ES', { day: 'numeric', month: 'short' })));
const plot = el('div', { class: 'hl-plot' });
card.append(top, el('div', { class: 'hl-sub' }, h.sub()), plot);
grid.append(card);
h.plot = plot;
h.vals = models
.map((m) => ({ m, v: h.get(m) }))
.filter((x) => x.v != null && Number.isFinite(x.v))
.sort((a, b) => (h.asc ? a.v - b.v : b.v - a.v) || byRank(a.m, b.m))
.slice(0, 10);
});
for (const h of HL) drawBars(h.plot, h.vals, h);
}
function drawBars(box, vals, h) {
// Etiquetas giradas 45°: el margen inferior y el izquierdo se calculan con su ancho real para que no se salgan.
const labFont = '400 11px "IBM Plex Sans", system-ui, sans-serif';
const lw = vals.map((x) => textW(x.m.name, labFont) * Math.SQRT1_2);
const W = Math.max(260, box.clientWidth), n = Math.max(vals.length, 1);
const M = { top: 22, right: 4, bottom: Math.max(60, Math.ceil(Math.max(0, ...lw)) + 24), left: 4 };
const slot0 = (W - M.left - M.right) / n;
M.left = Math.max(4, Math.ceil(Math.max(...lw.map((w, i) => w - slot0 * (i + 0.5) + 2), 0)));
const pw = W - M.left - M.right;
const max = Math.max(...vals.map((x) => x.v)) || 1;
const slot = pw / n, bw = Math.min(24, slot * 0.64), r = Math.min(4, bw / 2);
// Si alguna cifra no cabe sobre su barra, todas las del panel van en vertical.
const valFont = '500 10.5px "IBM Plex Mono", ui-monospace, monospace';
const valW = Math.max(...vals.map((x) => textW(h.f(x.v), valFont)));
const rot = valW > slot - 3;
const ph = 164;
M.top = rot ? Math.ceil(valW) + 12 : 22;
const H = M.top + ph + M.bottom;
const svg = sv('svg', { viewBox: `0 0 ${W} ${H}`, role: 'img', 'aria-label': `${h.title}: ${vals.map((x) => `${x.m.name} ${h.f(x.v)}`).join(', ')}` });
for (const f of [1 / 3, 2 / 3, 1]) {
const y = M.top + ph * (1 - f);
svg.append(sv('line', { x1: M.left, x2: M.left + pw, y1: y, y2: y, stroke: 'var(--grid)', 'stroke-width': 1 }));
}
const base = M.top + ph;
svg.append(sv('line', { x1: M.left, x2: M.left + pw, y1: base, y2: base, stroke: 'var(--axis)', 'stroke-width': 1 }));
vals.forEach((x, i) => {
const cx = M.left + slot * (i + 0.5), bh = Math.max(2, (x.v / max) * ph), y = base - bh, x0 = cx - bw / 2, x1 = cx + bw / 2;
const g = sv('g', { class: 'bar-g' });
const hit = sv('rect', { class: 'bar-hit', x: cx - slot / 2, y: M.top - 18, width: slot, height: ph + M.bottom + 18, fill: 'transparent', tabindex: 0,
role: 'img', 'aria-label': `${x.m.name}: ${h.f(x.v)}` });
const bar = sv('path', { class: 'bar', fill: h.color,
d: `M${x0},${base} V${y + r} Q${x0},${y} ${x0 + r},${y} H${x1 - r} Q${x1},${y} ${x1},${y + r} V${base} Z` });
const val = rot
? sv('text', { x: cx + 3.5, y: y - 5, 'text-anchor': 'start', fill: 'var(--ink)', 'font-size': 10.5, 'font-family': 'var(--mono)', 'font-weight': 500, transform: `rotate(-90 ${cx + 3.5} ${y - 5})` })
: sv('text', { x: cx, y: y - 6, 'text-anchor': 'middle', fill: 'var(--ink)', 'font-size': 10.5, 'font-family': 'var(--mono)', 'font-weight': 500 });
val.textContent = h.f(x.v);
const lab = sv('text', { x: cx + 3, y: base + 14, 'text-anchor': 'end', fill: 'var(--ink-2)', 'font-size': 11, transform: `rotate(-45 ${cx + 3} ${base + 14})` });
lab.textContent = x.m.name + (x.m.stopped ? ' *' : '');
const show = () => { bar.classList.add('hot'); showHTip(x, h, hit); };
const hide = () => { bar.classList.remove('hot'); hideHTip(); };
hit.addEventListener('pointerenter', show);
hit.addEventListener('pointerleave', hide);
hit.addEventListener('focus', show);
hit.addEventListener('blur', hide);
g.append(hit, bar, val, lab);
svg.append(g);
});
box.append(svg);
}
function showHTip(x, h, node) {
const tip = document.getElementById('htip');
tip.replaceChildren();
const m = x.m;
const head = el('div');
head.append(el('div', { class: 't-name' }, m.name), el('div', { class: 't-var' }, `${(m.variant || 'default').toUpperCase()}${m.provider ? ' · ' + m.provider : ''}`));
tip.append(head, el('div', { class: 't-score' }, (h.tipF ?? h.f)(x.v)));
const dl = el('dl');
const row = (k, v) => dl.append(el('dt', {}, k), el('dd', {}, v));
row('Nota', fmt.score(scoreOf(m)));
row('Suite oculta', m.hidden ? `${m.hidden.passed}/${m.hidden.total}` : '—');
row('Coste', fmt.cost(m.cost));
row('Tokens / s', m.tokensOut && m.activeMs ? nf(0).format(m.tokensOut / (m.activeMs / 1000)) : '—');
row('Tiempo activo', fmt.time(m.activeMs));
tip.append(dl);
tip.hidden = false;
const sec = tip.parentElement.getBoundingClientRect(), b = node.getBoundingClientRect();
let left = b.left - sec.left + b.width / 2 + 12;
if (left + tip.offsetWidth > sec.width - 8) left = b.left - sec.left + b.width / 2 - tip.offsetWidth - 12;
tip.style.left = `${Math.max(8, left)}px`;
tip.style.top = `${Math.max(40, b.top - sec.top + 20)}px`;
}
function hideHTip() {
const t = document.getElementById('htip');
if (t) t.hidden = true;
}
function render() {
drawHighlights();
const xm = X[state.x], ym = Y[state.y];
document.getElementById('chart-title').textContent = `${cur.short ?? cur.test} · ${ym.title}${isCustom() && state.y === 'score' ? ' con tus pesos' : ''} frente a ${xm.title}`;
points = cur.models
.map((m) => ({ m, x: xm.get(m), y: ym.get(m) }))
.filter((p) => p.x != null && p.y != null && (!state.log || p.x > 0));
front = frontier(points);
drawChart(xm, ym);
drawTable();
}
// ---------- gráfico ----------
const measureCtx = document.createElement('canvas').getContext('2d');
function textW(t, font) { measureCtx.font = font; return measureCtx.measureText(t).width; }
function drawChart(xm, ym) {
const box = document.getElementById('chart');
box.replaceChildren();
hideTip();
if (!points.length) {
box.append(el('div', { class: 'empty' }, 'Todavía no hay modelos con nota en esta prueba.'));
return;
}
const W = Math.max(320, box.clientWidth), H = W < 640 ? 440 : 560;
// Margen derecho amplio: con el eje invertido, los modelos más baratos quedan en el borde derecho y sus
// etiquetas necesitan sitio fuera del área de datos.
const M = { top: 34, right: W < 640 ? 96 : 150, bottom: 58, left: 58 };
const pw = W - M.left - M.right, ph = H - M.top - M.bottom;
const xs = points.map((p) => p.x), ys = points.map((p) => p.y);
let x0, x1, sx, xt;
if (state.log) {
x0 = Math.min(...xs) / 1.6; x1 = Math.max(...xs) * 1.6;
const l0 = Math.log10(x0), l1 = Math.log10(x1);
sx = (v) => M.left + (1 - (Math.log10(v) - l0) / (l1 - l0)) * pw; // invertido: más caro a la izquierda
xt = logTicks(x0, x1);
} else {
x0 = 0; x1 = Math.max(...xs) * 1.1;
const st = niceStep(x1, 5); x1 = Math.ceil(x1 / st) * st;
sx = (v) => M.left + (1 - (v - x0) / (x1 - x0)) * pw;
xt = linTicks(x0, x1, 5);
}
const yMax = ym.max, ySt = niceStep(yMax - Math.min(...ys), 6);
const y0 = Math.max(0, Math.floor((Math.min(...ys) - ySt) / ySt) * ySt), y1 = yMax;
const sy = (v) => M.top + (1 - (v - y0) / (y1 - y0)) * ph;
const yt = linTicks(y0, y1, 6);
const svg = sv('svg', { viewBox: `0 0 ${W} ${H}`, role: 'img', 'aria-label': `${ym.title} frente a ${xm.title}. La tabla inferior contiene los mismos datos.` });
const g = sv('g');
for (const v of yt) {
g.append(sv('line', { x1: M.left, x2: M.left + pw, y1: sy(v), y2: sy(v), stroke: 'var(--grid)', 'stroke-width': 1 }));
const t = sv('text', { x: M.left - 10, y: sy(v) + 4, 'text-anchor': 'end', fill: 'var(--muted)', 'font-size': 11, 'font-family': 'var(--mono)' });
t.textContent = state.y === 'hidden' ? `${v} %` : String(v);
g.append(t);
}
for (const v of xt) {
g.append(sv('line', { x1: sx(v), x2: sx(v), y1: M.top, y2: M.top + ph, stroke: 'var(--grid)', 'stroke-width': 1 }));
const t = sv('text', { x: sx(v), y: M.top + ph + 20, 'text-anchor': 'middle', fill: 'var(--muted)', 'font-size': 11, 'font-family': 'var(--mono)' });
t.textContent = xm.f(v);
g.append(t);
}
g.append(sv('line', { x1: M.left, x2: M.left + pw, y1: M.top + ph, y2: M.top + ph, stroke: 'var(--axis)', 'stroke-width': 1 }));
const xl = sv('text', { x: M.left + pw / 2, y: H - 12, 'text-anchor': 'middle', fill: 'var(--ink-2)', 'font-size': 12 });
xl.textContent = `${xm.label} (${xm.unit}) · menos es mejor →`;
g.append(xl);
const eff = sv('text', { x: M.left + pw, y: M.top - 14, 'text-anchor': 'end', fill: 'var(--muted)', 'font-size': 12, 'font-style': 'italic' });
eff.textContent = 'más eficiente ↗';
g.append(eff);
// Línea de la frontera.
const fp = points.filter((p) => front.has(p.m.slug)).sort((a, b) => a.x - b.x);
if (fp.length > 1) {
g.append(sv('polyline', {
points: fp.map((p) => `${sx(p.x)},${sy(p.y)}`).join(' '),
fill: 'none', stroke: 'var(--accent)', 'stroke-width': 2, 'stroke-linejoin': 'round', 'stroke-linecap': 'round',
}));
}
// Puntos: primero el resto, encima la frontera.
const ordered = [...points].sort((a, b) => front.has(a.m.slug) - front.has(b.m.slug));
for (const p of ordered) {
p.px = sx(p.x); p.py = sy(p.y);
const isF = front.has(p.m.slug);
const pt = sv('g', { class: 'pt', tabindex: 0, role: 'img', 'aria-label': `${p.m.name}: ${ym.label} ${ym.f(p.y)}, ${xm.label.toLowerCase()} ${xm.f(p.x)}${isF ? ', en la frontera de eficiencia' : ''}` });
pt.append(sv('circle', { cx: p.px, cy: p.py, r: 12, fill: 'transparent' }));
const c = sv('circle', { class: 'mark', cx: p.px, cy: p.py, r: 5, fill: isF ? 'var(--accent)' : 'var(--rest)', stroke: 'var(--surface)', 'stroke-width': 2 });
pt.append(c);
pt.addEventListener('focus', () => showTip(p, xm, ym));
pt.addEventListener('blur', hideTip);
p.node = c;
g.append(pt);
}
// Etiquetas con evitación de choques; si no caben, quedan en tooltip y tabla.
const nameFont = '500 12px "IBM Plex Sans", system-ui, sans-serif';
const varFont = '500 10px "IBM Plex Mono", ui-monospace, monospace';
const taken = points.map((p) => ({ x0: p.px - 7, x1: p.px + 7, y0: p.py - 7, y1: p.py + 7 }));
const free = (b) =>
b.x0 >= M.left && b.x1 <= W - 4 && b.y0 >= M.top - 4 && b.y1 <= M.top + ph &&
!taken.some((o) => b.x0 < o.x1 && b.x1 > o.x0 && b.y0 < o.y1 && b.y1 > o.y0);
const byPriority = [...points].sort((a, b) => front.has(b.m.slug) - front.has(a.m.slug) || b.y - a.y);
for (const p of byPriority) {
const variant = (p.m.variant || 'default').toUpperCase();
const w = Math.max(textW(p.m.name + (p.m.stopped ? ' *' : ''), nameFont), textW(variant, varFont) * 1.06) + 2;
const h = 26;
const tries = [
{ ax: 'start', x: p.px + 9, y: p.py - 11 },
{ ax: 'end', x: p.px - 9, y: p.py - 11 },
{ ax: 'middle', x: p.px, y: p.py - 36 },
{ ax: 'middle', x: p.px, y: p.py + 10 },
{ ax: 'start', x: p.px + 9, y: p.py - 26 },
{ ax: 'end', x: p.px - 9, y: p.py - 26 },
{ ax: 'start', x: p.px + 9, y: p.py + 2 },
{ ax: 'end', x: p.px - 9, y: p.py + 2 },
// Más lejos, con línea guía, para los puntos apiñados.
...[[30, -38], [30, 14], [-30, -38], [-30, 14], [44, -62], [44, 38], [-44, -62], [-44, 38]].map(([dx, dy]) => (
{ ax: dx > 0 ? 'start' : 'end', x: p.px + dx, y: p.py + dy, lead: true }
)),
];
for (const t of tries) {
const bx0 = t.ax === 'start' ? t.x : t.ax === 'end' ? t.x - w : t.x - w / 2;
const b = { x0: bx0 - 2, x1: bx0 + w + 2, y0: t.y - 1, y1: t.y + h + 1 };
if (!free(b)) continue;
taken.push(b);
if (t.lead) {
// La guía va del borde del punto a la línea del nombre, sin tocar el texto.
const ty = t.y + 7, tx = t.ax === 'start' ? t.x - 3 : t.x + 3;
const ang = Math.atan2(ty - p.py, tx - p.px);
g.append(sv('line', {
x1: p.px + Math.cos(ang) * 8, y1: p.py + Math.sin(ang) * 8, x2: tx, y2: ty,
stroke: 'var(--axis)', 'stroke-width': 1,
}));
}
const n = sv('text', { x: t.x, y: t.y + 11, 'text-anchor': t.ax, fill: 'var(--ink)', 'font-size': 12, 'font-weight': 500, 'font-family': 'var(--sans)' });
n.textContent = p.m.name + (p.m.stopped ? ' *' : '');
const v = sv('text', { x: t.x, y: t.y + 23, 'text-anchor': t.ax, fill: 'var(--muted)', 'font-size': 10, 'font-weight': 500, 'font-family': 'var(--mono)', 'letter-spacing': '0.06em' });
v.textContent = variant;
g.append(n, v);
break;
}
}
// Capa de hover: el punto más cercano (radio 48 px), no hace falta acertar en el círculo.
const hit = sv('rect', { x: M.left, y: M.top, width: pw, height: ph, fill: 'transparent' });
hit.addEventListener('pointermove', (e) => {
const r = svg.getBoundingClientRect(), k = W / r.width;
const mx = (e.clientX - r.left) * k, my = (e.clientY - r.top) * k;
let best = null, bd = 48;
for (const p of points) { const d = Math.hypot(p.px - mx, p.py - my); if (d < bd) { bd = d; best = p; } }
best ? showTip(best, xm, ym) : hideTip();
});
hit.addEventListener('pointerleave', hideTip);
svg.append(g, hit); // la capa de hover encima; los puntos siguen accesibles con el teclado
box.append(svg);
box._svg = svg; box._W = W;
}
let hot = null;
function showTip(p, xm, ym) {
if (hot && hot !== p) hot.node.setAttribute('r', 5);
hot = p;
p.node.setAttribute('r', 7);
const tip = document.getElementById('tip');
tip.replaceChildren();
const m = p.m;
const head = el('div');
head.append(el('div', { class: 't-name' }, m.name), el('div', { class: 't-var' }, (m.variant || 'default').toUpperCase()));
tip.append(head);
tip.append(el('div', { class: 't-score' }, ym.f(p.y)));
const dl = el('dl');
const row = (k, v) => dl.append(el('dt', {}, k), el('dd', {}, v));
if (state.y !== 'score') row('Nota', fmt.score(m.score));
row('Suite oculta', m.hidden ? `${m.hidden.passed}/${m.hidden.total}` : '—');
row('Código · tests (juez)', m.code != null ? `${m.code} · ${m.tests}` : '—');
row('Coste', fmt.cost(m.cost));
row('Tokens generados', fmt.tokens(m.tokensOut));
row('Pasos', fmt.steps(m.steps));
row('Tiempo activo', fmt.time(m.activeMs));
row('Intervenciones', m.interventions ?? '—');
tip.append(dl);
if (m.categories) tip.append(el('div', { class: 't-cats' }, m.categories));
if (m.stopped) tip.append(el('div', { class: 't-cats' }, `* No terminó${m.progress != null ? ` (≈${m.progress} % hecho)` : ''}: ${m.stopped}`));
if (front.has(m.slug)) {
const f = el('div', { class: 't-front' });
f.append(el('span', { class: 'dot front' }), 'En la frontera de eficiencia');
tip.append(f);
}
tip.hidden = false;
const card = tip.parentElement, box = document.getElementById('chart');
const k = box.getBoundingClientRect().width / box._W;
const cx = box.offsetLeft + p.px * k, cy = box.offsetTop + p.py * k;
const tw = tip.offsetWidth, th = tip.offsetHeight;
let left = cx + 16, top = cy - th / 2;
if (left + tw > card.clientWidth - 8) left = cx - tw - 16;
top = Math.max(8, Math.min(top, card.clientHeight - th - 8));
tip.style.left = `${Math.max(8, left)}px`;
tip.style.top = `${top}px`;
}
function hideTip() {
if (hot) hot.node.setAttribute('r', 5);
hot = null;
document.getElementById('tip').hidden = true;
}
// ---------- tabla ----------
const STATUS = {
scored: ['ok', 'Evaluado'],
zero: ['bad', 'Sin proyecto'],
forbidden: ['bad', 'Motor prohibido'],
unjudged: ['warn', 'Pendiente de juez'],
stopped: ['warn', 'No terminó (*)'],
running: ['run', 'Ejecutando'],
quota: ['warn', 'Cortado por cuota'],
access: ['warn', 'Sin acceso al modelo'],
pending: ['', 'Pendiente'],
};
const COLS = [
{ k: 'rank', label: '#', sort: false },
{ k: 'name', label: 'Modelo', get: (m) => m.name.toLowerCase() },
{ k: 'score', label: 'Nota', get: (m) => scoreOf(m) },
{ k: 'hidden', label: 'Suite oculta', get: (m) => (m.hidden ? m.hidden.passed / m.hidden.total : null) },
{ k: 'code', label: 'Código', get: (m) => m.code },
{ k: 'tests', label: 'Tests', get: (m) => m.tests },
{ k: 'cost', label: 'Coste', get: (m) => m.cost },
{ k: 'tokens', label: 'Tokens', get: (m) => m.tokensOut },
{ k: 'steps', label: 'Pasos', get: (m) => m.steps },
{ k: 'time', label: 'Tiempo', get: (m) => m.activeMs },
{ k: 'status', label: 'Estado', get: (m) => m.status },
];
// Orden de la clasificación: nota (con los pesos elegidos); en empate, nota oficial, menor coste y nombre.
function byRank(a, b) {
return (scoreOf(b) ?? -1) - (scoreOf(a) ?? -1) || (b.score ?? -1) - (a.score ?? -1) ||
(a.cost ?? Infinity) - (b.cost ?? Infinity) || a.name.localeCompare(b.name);
}
// Orden por varios criterios: clic en una cabecera = solo esa columna (otro clic invierte); Mayús+clic = la añade
// como desempate (o invierte la suya). La barra de encima muestra los criterios numerados y permite lo mismo sin
// teclado. Coste, tokens, pasos, tiempo y nombre empiezan de menor a mayor; el resto, de mayor a menor.
const ASC_FIRST = new Set(['name', 'cost', 'tokens', 'steps', 'time']);
const SORTABLE = COLS.filter((c) => c.sort !== false);
const DEFAULT_SORT = [{ k: 'score', dir: -1 }];
const defaultDir = (k) => (ASC_FIRST.has(k) ? 1 : -1);
const colOf = (k) => COLS.find((c) => c.k === k);
function loadSort() {
try {
const s = JSON.parse(store.get('sort', 'null'));
if (Array.isArray(s) && s.length && s.every((x) => SORTABLE.some((c) => c.k === x.k) && (x.dir === 1 || x.dir === -1))) return s;
} catch {}
return DEFAULT_SORT.map((x) => ({ ...x }));
}
function applySort(next) {
state.sort = next;
store.set('sort', JSON.stringify(next));
drawTable();
}
function sortBy(k, additive) {
const s = state.sort, i = s.findIndex((x) => x.k === k);
if (additive) applySort(i < 0 ? [...s, { k, dir: defaultDir(k) }] : s.map((x, j) => (j === i ? { k, dir: -x.dir } : x)));
else applySort([{ k, dir: s.length === 1 && i === 0 ? -s[0].dir : defaultDir(k) }]);
}
// Sin valor (sin nota, sin coste…) siempre al final, sea cual sea el sentido; tras los criterios, el de la clasificación.
function compareRows(a, b) {
for (const { k, dir } of state.sort) {
const get = colOf(k).get, va = get(a), vb = get(b);
if (va == null && vb == null) continue;
if (va == null) return 1;
if (vb == null) return -1;
if (va !== vb) return (va < vb ? -1 : 1) * dir;
}
return byRank(a, b);
}
function drawSortBar() {
const bar = document.getElementById('sortbar');
bar.replaceChildren(el('span', { class: 'control-label' }, 'Ordenar por'));
const list = el('ol', { class: 'sort-chips' });
state.sort.forEach((s, i) => {
const c = colOf(s.k);
const li = el('li', { class: 'sort-chip' });
const flip = el('button', { type: 'button', title: 'Invertir el sentido',
'aria-label': `Criterio ${i + 1}: ${c.label}, ${s.dir < 0 ? 'de mayor a menor' : 'de menor a mayor'}. Invertir` }, c.label);
flip.append(el('span', { class: 'arr', 'aria-hidden': 'true' }, s.dir < 0 ? '↓' : '↑'));
flip.addEventListener('click', () => sortBy(s.k, true));
li.append(flip);
if (state.sort.length > 1) {
const x = el('button', { type: 'button', class: 'x', title: 'Quitar criterio', 'aria-label': `Quitar ${c.label}` }, '×');
x.addEventListener('click', () => applySort(state.sort.filter((_, j) => j !== i)));
li.append(x);
}
list.append(li);
});
bar.append(list);
const rest = SORTABLE.filter((c) => !state.sort.some((s) => s.k === c.k));
if (rest.length) {
const sel = el('select', { 'aria-label': 'Añadir un criterio de desempate' });
sel.append(el('option', { value: '' }, '+ Desempatar por…'), ...rest.map((c) => el('option', { value: c.k }, c.label)));
sel.addEventListener('change', () => sel.value && sortBy(sel.value, true));
bar.append(sel);
}
if (JSON.stringify(state.sort) !== JSON.stringify(DEFAULT_SORT)) {
const r = el('button', { type: 'button', class: 'reset' }, 'Restablecer');
r.addEventListener('click', () => applySort(DEFAULT_SORT.map((x) => ({ ...x }))));
bar.append(r);
}
bar.append(el('span', { class: 'sort-hint' }, 'Mayús + clic en una columna añade un criterio'));
}
function drawTable() {
state.sort ??= loadSort();
drawSortBar();
const head = document.getElementById('thead');
head.replaceChildren();
for (const c of COLS) {
const th = el('th', { scope: 'col' });
if (c.sort === false) th.textContent = c.label;
else {
const b = el('button', { type: 'button', title: 'Clic: ordenar por esta columna · Mayús + clic: añadirla como desempate' }, c.label);
const i = state.sort.findIndex((s) => s.k === c.k);
if (i >= 0) b.setAttribute('data-dir', (state.sort[i].dir < 0 ? '↓' : '↑') + (state.sort.length > 1 ? i + 1 : ''));
b.addEventListener('click', (e) => sortBy(c.k, e.shiftKey));
th.append(b);
th.setAttribute('aria-sort', i === 0 ? (state.sort[0].dir < 0 ? 'descending' : 'ascending') : 'none');
}
head.append(th);
}
const rows = [...cur.models].sort(compareRows);
const body = document.getElementById('tbody');
body.replaceChildren();
const rankOf = new Map([...cur.models].filter((m) => scoreOf(m) != null).sort(byRank).map((m, i) => [m.slug, i + 1]));
for (const m of rows) {
const tr = el('tr');
tr.append(el('td', { class: 'rank' }, rankOf.get(m.slug) ?? ''));
const n = el('td');
const inChart = points.some((p) => p.m.slug === m.slug);
n.append(el('span', { class: 'dot' + (front.has(m.slug) ? ' front' : ''), style: inChart ? '' : 'visibility:hidden', 'aria-hidden': 'true' }), ' ');
n.append(el('span', { class: 'm-name' }, m.name), el('span', { class: 'm-var' }, (m.variant || 'default').toUpperCase()));
tr.append(n);
tr.append(el('td', { class: 'num score' }, fmt.score(scoreOf(m)) + (m.stopped && scoreOf(m) != null ? '*' : '')));
tr.append(el('td', { class: 'num' }, m.hidden ? `${m.hidden.passed}/${m.hidden.total}` : '—'));
tr.append(el('td', { class: 'num' }, m.code ?? '—'));
tr.append(el('td', { class: 'num' }, m.tests ?? '—'));
tr.append(el('td', { class: 'num' }, fmt.cost(m.cost)));
tr.append(el('td', { class: 'num' }, fmt.tokens(m.tokensOut)));
tr.append(el('td', { class: 'num' }, fmt.steps(m.steps)));
tr.append(el('td', { class: 'num' }, fmt.time(m.activeMs)));
const [cls, txt0] = STATUS[m.status] ?? ['', m.status];
const txt = m.status === 'stopped' && m.progress != null ? `No terminó (≈${m.progress} %) *` : txt0;
const st = el('td');
st.append(el('span', { class: 'pill ' + cls }, txt));
tr.append(st);
body.append(tr);
}
}
// ---------- notas ----------
function notes() {
const f = document.getElementById('notes');
f.replaceChildren();
const W = cur.weights;
const lines = [
`Nota 0–10 = corrección ${W.correctness} (suite oculta de ${cur.hiddenTotal} casos) + autonomía ${W.autonomy} + tests propios ${W.ownTests} + código ${W.codeQuality} + robustez ${W.robustness}, según RUBRIC.md de la prueba.`,
'Frontera de eficiencia: modelos que ningún otro supera a la vez en el eje Y y en el eje X elegidos. Cambia al cambiar de eje.',
'Coste: precio de lista que registra opencode por sesión (con la suscripción Go es orientativo). Tokens generados: salida + razonamiento. Pasos: llamadas al modelo. Tiempo: tiempo activo del agente.',
'Cada modelo usa su variante de razonamiento más alta disponible (etiqueta bajo el nombre).',
...(DATA.notes ?? []),
];
const stopped = cur.models.filter((m) => m.stopped);
if (stopped.length) lines.push(`* No terminó: ${stopped.map((m) => `${m.name}${m.progress != null ? ` (≈${m.progress} % hecho)` : ''} — ${m.stopped}`).join('; ')}. Se valora el código tal como estaba al detenerlo; autonomía 0.`);
for (const l of lines) f.append(el('div', {}, l));
if (DATA.repoUrl) {
const r = el('div');
r.append('La suite oculta no se publica. Código, soluciones de los modelos y datos: ', el('a', { href: DATA.repoUrl }, 'repositorio en GitHub'), '.');
f.append(r);
}
}
function selectTest(t) {
if (t === cur) return;
cur = t;