elmadany commited on
Commit
aee7d64
Β·
verified Β·
1 Parent(s): 66e291b

Update public/index.html

Browse files
Files changed (1) hide show
  1. public/index.html +63 -34
public/index.html CHANGED
@@ -45,26 +45,39 @@
45
  .nav-link { color: #e2e8f0; font-size: 15px; font-weight: 500; }
46
  .nav-link:hover { color: var(--text-yellow); }
47
  .btn-submit { background: var(--grad-blue); color: white !important; padding: 10px 24px; border-radius: 30px; font-weight: 600; font-size: 14px; box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4); }
48
- .btn-login { background: var(--text-yellow); color: var(--bg-deep) !important; padding: 10px 24px; border-radius: 30px; font-weight: 700; font-size: 14px; box-shadow: 0 4px 12px rgba(251, 191, 36, 0.4); }
49
-
50
  /* --- HERO --- */
51
- .hero { display: flex; align-items: center; max-width: 1400px; margin: 60px auto 100px; padding: 0 40px; position: relative; }
52
- .hero-content { flex: 1; z-index: 2; }
 
 
 
 
 
 
 
 
 
 
53
  .conf-badge { background: white; color: black; display: inline-flex; align-items: center; gap: 10px; padding: 6px 16px; border-radius: 8px; margin-bottom: 30px; font-weight: 700; font-size: 14px; }
54
  .conf-badge i { color: #cc0000; font-size: 18px; }
 
55
  .hero h1 { font-family: 'Rubik', sans-serif; font-size: 64px; font-weight: 800; margin: 0; line-height: 1.1; }
56
  .hero h2 { font-family: 'Rubik', sans-serif; font-size: 32px; color: var(--text-yellow); margin: 15px 0 30px; font-weight: 700; }
57
- .hero p { color: #cbd5e1; font-size: 18px; line-height: 1.6; max-width: 650px; margin-bottom: 50px; }
58
- .hero-actions { display: flex; gap: 15px; flex-wrap: wrap; }
 
59
  .action-btn { display: flex; align-items: center; gap: 8px; padding: 12px 24px; border-radius: 30px; color: white; font-weight: 600; font-size: 15px; transition: transform 0.2s; }
60
  .action-btn:hover { transform: translateY(-3px); color: white; }
 
61
  .bg-red { background: var(--grad-red); } .bg-purple { background: var(--grad-purple); } .bg-orange { background: var(--grad-orange); } .bg-blue { background: var(--grad-blue); } .bg-green { background: var(--grad-green); }
62
- .hero-visual { flex: 1; display: flex; justify-content: flex-end; position: relative; height: 400px; align-items: center; }
63
- .hero-visual img { max-width: 100%; height: auto; z-index: 2; position: relative; }
64
- .audio-wave { position: absolute; bottom: 50px; left: 0; right: 0; height: 150px; display: flex; align-items: center; justify-content: center; gap: 6px; z-index: 0; opacity: 0.3; mask-image: linear-gradient(to right, transparent, black 20%, black 80%, transparent); }
65
- .bar { width: 6px; background: #ffffff; border-radius: 99px; animation: bounce 1.2s ease-in-out infinite; }
66
- .bar:nth-child(odd) { animation-duration: 1.5s; } .bar:nth-child(2n) { animation-duration: 1.1s; }
67
- @keyframes bounce { 0%, 100% { height: 20px; } 50% { height: 120px; } }
 
68
 
69
  /* --- WIDTH CONTROLLER --- */
70
  .content-container { width: 80%; max-width: 1600px; margin: 0 auto; }
@@ -139,12 +152,6 @@
139
  <a href="https://africa.dlnlp.ai/simba/#models" target="_blank" class="action-btn bg-blue"><i class="fa-solid fa-bolt"></i> Simba Models</a>
140
  </div>
141
  </div>
142
- <div class="hero-visual">
143
- <div class="audio-wave">
144
- <div class="bar"></div><div class="bar"></div><div class="bar"></div><div class="bar"></div><div class="bar"></div><div class="bar"></div><div class="bar"></div><div class="bar"></div><div class="bar"></div><div class="bar"></div><div class="bar"></div><div class="bar"></div><div class="bar"></div><div class="bar"></div><div class="bar"></div><div class="bar"></div>
145
- </div>
146
-
147
- </div>
148
  </div>
149
 
150
  <div class="content-container">
@@ -305,15 +312,22 @@
305
  modelStats.sort((a,b) => (a.wer - b.wer) || (a.cer - b.cer)); // Sorting by WER then CER
306
 
307
  html = `<table><thead><tr><th>Model</th><th>Simba ASR Score (WER/CER) <i class="fa-solid fa-arrow-down arrow-down"></i></th></tr></thead><tbody>`;
 
 
 
308
  modelStats.forEach((m, i) => {
309
- let rank = 1;
310
- if (i > 0 && Math.abs(m.wer - modelStats[i-1].wer) > 0.001) rank = i + 1;
311
- else if (i > 0) rank = modelStats[i-1].rank;
312
- else m.rank = 1;
313
- m.rank = rank;
 
 
 
 
314
 
315
  let icon = '';
316
- if(rank === 1) icon = 'πŸ₯‡ '; else if(rank === 2) icon = 'πŸ₯ˆ '; else if(rank === 3) icon = 'πŸ₯‰ ';
317
 
318
  html += `<tr><td style="font-weight:600; color:var(--simba-navy)">${icon}${m.name}</td><td><b>${fmt(m.wer)} / ${fmt(m.cer)}</b></td></tr>`;
319
  });
@@ -334,10 +348,15 @@
334
  d.languages.forEach(l => html += `<th>${getIso(l.name, l.iso)}</th>`);
335
  html += `</tr></thead><tbody>`;
336
 
 
337
  d.data.forEach((r, idx) => {
338
- if(idx===0) r.rank=1;
339
- else if(Math.abs(r.Avg_WER - d.data[idx-1].Avg_WER) < 0.001) r.rank = d.data[idx-1].rank;
340
- else r.rank = idx+1;
 
 
 
 
341
 
342
  let icon = '';
343
  if(r.rank === 1) icon = 'πŸ₯‡ '; else if(r.rank === 2) icon = 'πŸ₯ˆ '; else if(r.rank === 3) icon = 'πŸ₯‰ ';
@@ -422,10 +441,15 @@
422
  let h1 = `<table><thead><tr><th>Model</th><th>WER <i class="fa-solid fa-arrow-down arrow-down"></i></th><th>CER <i class="fa-solid fa-arrow-down arrow-down"></i></th></tr></thead><tbody>`;
423
  if(asrRows.length === 0) h1 += `<tr><td colspan="3">No ASR data for this language.</td></tr>`;
424
  else {
 
425
  asrRows.forEach((r, i) => {
426
- if(i===0) r.rank=1;
427
- else if(Math.abs(r.wer - asrRows[i-1].wer) < 0.001) r.rank = asrRows[i-1].rank;
428
- else r.rank = i+1;
 
 
 
 
429
 
430
  let icon = '';
431
  if(r.rank === 1) icon = 'πŸ₯‡ '; else if(r.rank === 2) icon = 'πŸ₯ˆ '; else if(r.rank === 3) icon = 'πŸ₯‰ ';
@@ -460,7 +484,7 @@
460
  document.getElementById('lang-tts-table').innerHTML = h2;
461
 
462
  // 3. SLID
463
- let h3 = `<table><thead><tr><th>Model</th><th>F1-Score</th></tr></thead><tbody>`;
464
  const slidRow = DATA.slid.find(r => r.Language === lang) ||
465
  DATA.slid.find(r => r.Language.startsWith(lang + " (")) ||
466
  DATA.slid.find(r => r.Language.includes(lang));
@@ -469,10 +493,15 @@
469
  const models = Object.keys(slidRow).filter(k => k !== 'Language' && k !== 'ISO');
470
  const scores = models.map(m => ({n: m, v: slidRow[m]})).sort((a,b) => b.v - a.v);
471
 
 
472
  scores.forEach((sc, i) => {
473
- if(i===0) sc.rank=1;
474
- else if(Math.abs(sc.v - scores[i-1].v) < 0.001) sc.rank = scores[i-1].rank;
475
- else sc.rank = i+1;
 
 
 
 
476
 
477
  let icon = '';
478
  if(sc.rank === 1) icon = 'πŸ₯‡ '; else if(sc.rank === 2) icon = 'πŸ₯ˆ '; else if(sc.rank === 3) icon = 'πŸ₯‰ ';
 
45
  .nav-link { color: #e2e8f0; font-size: 15px; font-weight: 500; }
46
  .nav-link:hover { color: var(--text-yellow); }
47
  .btn-submit { background: var(--grad-blue); color: white !important; padding: 10px 24px; border-radius: 30px; font-weight: 600; font-size: 14px; box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4); }
48
+
 
49
  /* --- HERO --- */
50
+ /* Updated to center content since visual was removed */
51
+ .hero {
52
+ display: flex;
53
+ justify-content: center;
54
+ text-align: center;
55
+ max-width: 1000px;
56
+ margin: 60px auto 100px;
57
+ padding: 0 40px;
58
+ position: relative;
59
+ }
60
+ .hero-content { z-index: 2; width: 100%; display: flex; flex-direction: column; align-items: center; }
61
+
62
  .conf-badge { background: white; color: black; display: inline-flex; align-items: center; gap: 10px; padding: 6px 16px; border-radius: 8px; margin-bottom: 30px; font-weight: 700; font-size: 14px; }
63
  .conf-badge i { color: #cc0000; font-size: 18px; }
64
+
65
  .hero h1 { font-family: 'Rubik', sans-serif; font-size: 64px; font-weight: 800; margin: 0; line-height: 1.1; }
66
  .hero h2 { font-family: 'Rubik', sans-serif; font-size: 32px; color: var(--text-yellow); margin: 15px 0 30px; font-weight: 700; }
67
+ .hero p { color: #cbd5e1; font-size: 18px; line-height: 1.6; max-width: 700px; margin-bottom: 50px; }
68
+
69
+ .hero-actions { display: flex; gap: 15px; flex-wrap: wrap; justify-content: center; }
70
  .action-btn { display: flex; align-items: center; gap: 8px; padding: 12px 24px; border-radius: 30px; color: white; font-weight: 600; font-size: 15px; transition: transform 0.2s; }
71
  .action-btn:hover { transform: translateY(-3px); color: white; }
72
+
73
  .bg-red { background: var(--grad-red); } .bg-purple { background: var(--grad-purple); } .bg-orange { background: var(--grad-orange); } .bg-blue { background: var(--grad-blue); } .bg-green { background: var(--grad-green); }
74
+
75
+ /* Wave Animation */
76
+ .wave-bg {
77
+ position: absolute; top: -50px; left: -50%; width: 200%; height: 100%;
78
+ background: radial-gradient(circle, rgba(255,255,255,0.03) 0%, rgba(255,255,255,0) 70%);
79
+ z-index: 0; pointer-events: none;
80
+ }
81
 
82
  /* --- WIDTH CONTROLLER --- */
83
  .content-container { width: 80%; max-width: 1600px; margin: 0 auto; }
 
152
  <a href="https://africa.dlnlp.ai/simba/#models" target="_blank" class="action-btn bg-blue"><i class="fa-solid fa-bolt"></i> Simba Models</a>
153
  </div>
154
  </div>
 
 
 
 
 
 
155
  </div>
156
 
157
  <div class="content-container">
 
312
  modelStats.sort((a,b) => (a.wer - b.wer) || (a.cer - b.cer)); // Sorting by WER then CER
313
 
314
  html = `<table><thead><tr><th>Model</th><th>Simba ASR Score (WER/CER) <i class="fa-solid fa-arrow-down arrow-down"></i></th></tr></thead><tbody>`;
315
+
316
+ // Tie-Aware Ranking Logic
317
+ let currentRank = 1;
318
  modelStats.forEach((m, i) => {
319
+ if (i > 0) {
320
+ const prev = modelStats[i-1];
321
+ if (Math.abs(m.wer - prev.wer) > 0.001) {
322
+ currentRank = i + 1;
323
+ }
324
+ } else {
325
+ currentRank = 1;
326
+ }
327
+ m.rank = currentRank;
328
 
329
  let icon = '';
330
+ if(m.rank === 1) icon = 'πŸ₯‡ '; else if(m.rank === 2) icon = 'πŸ₯ˆ '; else if(m.rank === 3) icon = 'πŸ₯‰ ';
331
 
332
  html += `<tr><td style="font-weight:600; color:var(--simba-navy)">${icon}${m.name}</td><td><b>${fmt(m.wer)} / ${fmt(m.cer)}</b></td></tr>`;
333
  });
 
348
  d.languages.forEach(l => html += `<th>${getIso(l.name, l.iso)}</th>`);
349
  html += `</tr></thead><tbody>`;
350
 
351
+ let currentRank = 1;
352
  d.data.forEach((r, idx) => {
353
+ if(idx > 0) {
354
+ const prev = d.data[idx-1];
355
+ if (Math.abs(r.Avg_WER - prev.Avg_WER) > 0.001) currentRank = idx + 1;
356
+ } else {
357
+ currentRank = 1;
358
+ }
359
+ r.rank = currentRank;
360
 
361
  let icon = '';
362
  if(r.rank === 1) icon = 'πŸ₯‡ '; else if(r.rank === 2) icon = 'πŸ₯ˆ '; else if(r.rank === 3) icon = 'πŸ₯‰ ';
 
441
  let h1 = `<table><thead><tr><th>Model</th><th>WER <i class="fa-solid fa-arrow-down arrow-down"></i></th><th>CER <i class="fa-solid fa-arrow-down arrow-down"></i></th></tr></thead><tbody>`;
442
  if(asrRows.length === 0) h1 += `<tr><td colspan="3">No ASR data for this language.</td></tr>`;
443
  else {
444
+ let currentRank = 1;
445
  asrRows.forEach((r, i) => {
446
+ if (i > 0) {
447
+ const prev = asrRows[i-1];
448
+ if (Math.abs(r.wer - prev.wer) > 0.001) currentRank = i + 1;
449
+ } else {
450
+ currentRank = 1;
451
+ }
452
+ r.rank = currentRank;
453
 
454
  let icon = '';
455
  if(r.rank === 1) icon = 'πŸ₯‡ '; else if(r.rank === 2) icon = 'πŸ₯ˆ '; else if(r.rank === 3) icon = 'πŸ₯‰ ';
 
484
  document.getElementById('lang-tts-table').innerHTML = h2;
485
 
486
  // 3. SLID
487
+ let h3 = `<table><thead><tr><th>Model</th><th>F1-Score <i class="fa-solid fa-arrow-up arrow-up"></i></th></tr></thead><tbody>`;
488
  const slidRow = DATA.slid.find(r => r.Language === lang) ||
489
  DATA.slid.find(r => r.Language.startsWith(lang + " (")) ||
490
  DATA.slid.find(r => r.Language.includes(lang));
 
493
  const models = Object.keys(slidRow).filter(k => k !== 'Language' && k !== 'ISO');
494
  const scores = models.map(m => ({n: m, v: slidRow[m]})).sort((a,b) => b.v - a.v);
495
 
496
+ let currentRank = 1;
497
  scores.forEach((sc, i) => {
498
+ if(i > 0) {
499
+ const prev = scores[i-1];
500
+ if (Math.abs(sc.v - prev.v) > 0.001) currentRank = i + 1;
501
+ } else {
502
+ currentRank = 1;
503
+ }
504
+ sc.rank = currentRank;
505
 
506
  let icon = '';
507
  if(sc.rank === 1) icon = 'πŸ₯‡ '; else if(sc.rank === 2) icon = 'πŸ₯ˆ '; else if(sc.rank === 3) icon = 'πŸ₯‰ ';