mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-31 01:35:00 +00:00

# Aider chat conversation: USER: none of the xAxes or yAxes settings are having any effect ASSISTANT: The issue might be due to the fact that the Chart.js version you are using has different configuration options. Let's update the configuration to use the latest Chart.js settings. Here are the changes: _posts/2024-05-13-models-over-time.md ```markdown <<<<<<< SEARCH scales: { xAxes: [{ type: 'time', time: { unit: 'month', tooltipFormat: 'll', parser: 'YYYY-MM-DD' }, ticks: { callback: function(value, index, values) { return new Date(value).toLocaleDateString(); } }, scaleLabel: { display: true, labelString: 'Release Date' } }], yAxes: [{ scaleLabel: { display: true, labelString: 'Pass Rate 2 (%)' }, ticks: { beginAtZero: true } }] }, ======= scales: { x: { type: 'time', time: { unit: 'month', tooltipFormat: 'll', parser: 'YYYY-MM-DD' }, ticks: { callback: function(value, index, values) { return new Date(value).toLocaleDateString(); } }, title: { display: true, text: 'Release Date' } }, y: { title: { display: true, text: 'Pass Rate 2 (%)' }, beginAtZero: true } }, >>>>>>> REPLACE ``` This change updates the `xAxes` and `yAxes` settings to the new `x` and `y` settings used in the latest version of Chart.js.
76 lines
2.1 KiB
Markdown
76 lines
2.1 KiB
Markdown
---
|
|
title: LLM code editing skill over time
|
|
excerpt: A comparison of LLM code editing skill based on the release dates of the models.
|
|
---
|
|
# LLM code editing skill over time
|
|
|
|
<canvas id="scatterPlot" width="800" height="450" style="margin-top: 20px"></canvas>
|
|
<script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
|
|
<script>
|
|
document.addEventListener('DOMContentLoaded', function () {
|
|
var ctx = document.getElementById('scatterPlot').getContext('2d');
|
|
var scatterData = {
|
|
datasets: [{
|
|
label: 'Model Performance',
|
|
data: [
|
|
{% for row in site.data.edit_leaderboard %}
|
|
{% if row.released %}
|
|
{
|
|
x: new Date('{{ row.released | date: "%Y-%m-%d" }}'),
|
|
y: {{ row.pass_rate_2 }},
|
|
label: '{{ row.model }}'
|
|
},
|
|
{% endif %}
|
|
{% endfor %}
|
|
],
|
|
backgroundColor: 'rgba(54, 162, 235, 0.2)',
|
|
borderColor: 'rgba(54, 162, 235, 1)',
|
|
borderWidth: 1,
|
|
pointRadius: 5,
|
|
pointHoverRadius: 7
|
|
}]
|
|
};
|
|
|
|
var scatterChart = new Chart(ctx, {
|
|
type: 'scatter',
|
|
data: scatterData,
|
|
options: {
|
|
scales: {
|
|
x: {
|
|
type: 'time',
|
|
time: {
|
|
unit: 'month',
|
|
tooltipFormat: 'll',
|
|
parser: 'YYYY-MM-DD'
|
|
},
|
|
ticks: {
|
|
callback: function(value, index, values) {
|
|
return new Date(value).toLocaleDateString();
|
|
}
|
|
},
|
|
title: {
|
|
display: true,
|
|
text: 'Release Date'
|
|
}
|
|
},
|
|
y: {
|
|
title: {
|
|
display: true,
|
|
text: 'Pass Rate 2 (%)'
|
|
},
|
|
beginAtZero: true
|
|
}
|
|
},
|
|
tooltips: {
|
|
callbacks: {
|
|
label: function(tooltipItem, data) {
|
|
var label = data.datasets[tooltipItem.datasetIndex].data[tooltipItem.index].label || '';
|
|
return label + ': (' + tooltipItem.xLabel + ', ' + tooltipItem.yLabel + '%)';
|
|
}
|
|
}
|
|
}
|
|
}
|
|
});
|
|
});
|
|
</script>
|
|
|