animation2code benchmark
For best compatibility, please view this dashboard in a Chrome browser.
← back to Rotating text

model output

LLaMA 4 Scout

Rotating text

A 0.86T 0.25
compare with ground truth →
1<!DOCTYPE html>
2<html lang="en">
3<head>
4    <meta charset="UTF-8">
5    <meta name="viewport" content="width=device-width, initial-scale=1.0">
6    <title>Nachos Animation</title>
7    <style>
8        body {
9            font-family: Arial, sans-serif;
10            background-color: #fff;
11            display: flex;
12            justify-content: center;
13            align-items: center;
14            height: 100vh;
15            margin: 0;
16        }
17        .text {
18            font-size: 24px;
19            font-weight: normal;
20        }
21    </style>
22</head>
23<body>
24    <span class="text">Nachos are </span><span id="change-text" class="text"></span>
25    <script>
26        const textArray = [
27            { text: 'tasty.', color: 'purple' },
28            { text: 'wo', color: 'blue' },
29            { text: 'wonderful', color: 'blue' },
30            { text: 'wonderful.', color: 'blue' },
31            { text: 'wonderful.', color: 'blue' },
32            { text: 'wonderful.', color: 'blue' },
33            { text: 'fa<ul>', color: 'red' },
34            { text: 'fancy.', color: 'red' },
35            { text: 'fancy.', color: 'red' },
36            { text: 'fancy.', color: 'red' },
37            { text: 'fancy.', color: 'red' },
38            { text: 'fancy.', color: 'red' },
39        ];
40        let index = 0;
41        const changeTextElement = document.getElementById('change-text');
42        function changeText() {
43            changeTextElement.textContent = textArray[index].text;
44            changeTextElement.style.color = textArray[index].color;
45            index = (index + 1) % textArray.length;
46        }
47        setInterval(changeText, 1000);
48    </script>
49</body>
50</html>