mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-30 17:24:59 +00:00
Refactor: Remove edit-format column from leaderboards
This commit is contained in:
parent
ea1239efef
commit
d33a571f7d
2 changed files with 6 additions and 23 deletions
|
@ -15,15 +15,11 @@ document.addEventListener('DOMContentLoaded', function () {
|
|||
label: 'Percent completed correctly',
|
||||
data: [],
|
||||
backgroundColor: function(context) {
|
||||
const row = allData[context.dataIndex];
|
||||
if (row && row.edit_format === 'whole') {
|
||||
return redDiagonalPattern; // Use red pattern for highlighted whole format
|
||||
}
|
||||
const label = leaderboardData.labels[context.dataIndex] || '';
|
||||
return (label && HIGHLIGHT_MODEL && label.toLowerCase().includes(HIGHLIGHT_MODEL.toLowerCase())) ? 'rgba(255, 99, 132, 0.2)' : 'rgba(54, 162, 235, 0.2)';
|
||||
},
|
||||
borderColor: function(context) {
|
||||
const label = context.chart.data.labels[context.dataIndex] || '';
|
||||
const label = leaderboardData.labels[context.dataIndex] || '';
|
||||
return (label && HIGHLIGHT_MODEL && label.toLowerCase().includes(HIGHLIGHT_MODEL.toLowerCase())) ? 'rgba(255, 99, 132, 1)' : 'rgba(54, 162, 235, 1)';
|
||||
},
|
||||
borderWidth: 1
|
||||
|
@ -46,7 +42,6 @@ document.addEventListener('DOMContentLoaded', function () {
|
|||
model: '{{ row.model }}',
|
||||
pass_rate: {{ row[pass_rate_field] }},
|
||||
percent_cases_well_formed: {{ row.percent_cases_well_formed }},
|
||||
edit_format: '{{ row.edit_format | default: "diff" }}',
|
||||
total_cost: {{ row.total_cost | default: 0 }}
|
||||
});
|
||||
{% endfor %}
|
||||
|
@ -85,10 +80,7 @@ document.addEventListener('DOMContentLoaded', function () {
|
|||
const isHighlighted = label && HIGHLIGHT_MODEL && label.toLowerCase().includes(HIGHLIGHT_MODEL.toLowerCase());
|
||||
|
||||
if (isHighlighted) {
|
||||
if (row && row.edit_format === 'whole') return redDiagonalPattern;
|
||||
else return 'rgba(255, 99, 132, 0.2)';
|
||||
} else if (row && row.edit_format === 'whole') {
|
||||
return blueDiagonalPattern;
|
||||
return 'rgba(255, 99, 132, 0.2)';
|
||||
} else {
|
||||
return 'rgba(54, 162, 235, 0.2)';
|
||||
}
|
||||
|
@ -126,12 +118,6 @@ document.addEventListener('DOMContentLoaded', function () {
|
|||
strokeStyle: 'rgba(54, 162, 235, 1)',
|
||||
lineWidth: 1
|
||||
},
|
||||
{
|
||||
text: 'Whole format',
|
||||
fillStyle: blueDiagonalPattern,
|
||||
strokeStyle: 'rgba(54, 162, 235, 1)',
|
||||
lineWidth: 1
|
||||
},
|
||||
{
|
||||
text: 'Total Cost ($)',
|
||||
fillStyle: 'rgba(153, 102, 255, 1)',
|
||||
|
|
|
@ -27,7 +27,6 @@ Aider works best with high-scoring models, though it [can connect to almost any
|
|||
<th style="padding: 8px; text-align: center;">Percent correct</th>
|
||||
<th style="padding: 8px; text-align: center;">Cost (log scale)</th>
|
||||
<th style="padding: 8px; text-align: left;">Command</th>
|
||||
<th style="padding: 8px; text-align: center;">Edit format</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
@ -54,7 +53,6 @@ Aider works best with high-scoring models, though it [can connect to almost any
|
|||
<span>{% if row.total_cost == 0 or rounded_cost == 0.00 %}?{% else %}${{ rounded_cost }}{% endif %}</span>
|
||||
</td>
|
||||
<td style="padding: 8px;"><span><code>{{ row.command }}</code></span></td>
|
||||
<td style="padding: 8px; text-align: center;"><span>{{ row.edit_format }}</span></td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
|
@ -86,14 +84,13 @@ Aider works best with high-scoring models, though it [can connect to almost any
|
|||
word-wrap: break-word;
|
||||
overflow-wrap: break-word;
|
||||
}
|
||||
td:nth-child(4), td:nth-child(5) { /* Command and Edit Format columns */
|
||||
td:nth-child(4) { /* Command column */
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
/* Hide command and edit format columns on mobile */
|
||||
|
||||
/* Hide command column on mobile */
|
||||
@media screen and (max-width: 767px) {
|
||||
th:nth-child(4), td:nth-child(4), /* Command column */
|
||||
th:nth-child(5), td:nth-child(5) { /* Edit format column */
|
||||
th:nth-child(4), td:nth-child(4) { /* Command column */
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue