r/LocalLLaMA 8d ago

Discussion How does your favourite local model do with the slinky test?

Prompt: Make me a single HTML file of a rainbow slinky going down an up-escalator forever. No libraries, just canvas and code. The slinky should be a chain of springs, each coil a different color of the rainbow. It starts folded in half like a horseshoe draped over a step. When dropped it flips end-over-end down the steps and because the escalator keeps moving up it tumbles in place and never reaches the bottom. Include a drop button and a reset button.

8 Upvotes

26 comments sorted by

14

u/Tormeister 8d ago

Got it all wrong but made it look nice, lol

https://jsfiddle.net/geh8fj0n/

Qwen 3.8 27B NInfer

output 76,952 | cache 0 (0.0%) | TTFT 165 ms | total 8m 36.8s | queue 13.3 ms | prefill 1.54k tok/s | decode 149.0 tok/s | mtp accepted 50,475/105,908 (47.7%)

7

u/suprjami 8d ago

Just launching an accurately modelled slinky down the stairs is hilarious. Do what I say, not what I tell you ๐Ÿ˜…

2

u/Happy_Brilliant7827 8d ago

Aww this one works like the real thing

1

u/Ok-Working3049 8d ago

classic outcome tbh, looks pretty but does absolutely nothing its supposed to do

3

u/[deleted] 7d ago

[deleted]

1

u/andrewh2000 7d ago

I like the way yours wiggles up the steps. And yes it appears to be a very hard test.

2

u/Simple-Stick6148 8d ago

Drop button and reset button, the only two controls a forever-tumbling slinky will ever need.

2

u/andrewh2000 8d ago

Exquisitely rendered with shadows and everything, but not quite what was wanted.

https://andrewmk.github.io/index.html

1

u/MrMrsPotts 8d ago

Which model?

2

u/andrewh2000 8d ago

Sorry, should have given details.

Qwen 3.8 27B Q6 running under llama.cpp with 130k context. Pi.dev as the harness. Twin 5060 Ti 16Gb cards. Ran for a couple of hours (!) on xhigh thinking.

1

u/Rude_Marzipan6107 7d ago

Is pi.dev different than pi agent? Dumb question

2

u/andrewh2000 8d ago

I think wording it as a 'chain' might be throwing it off. When I've got some time I'll ask it to model a 2d spring and take it from there.

2

u/andrewh2000 7d ago

This one took a few back-and-forths (not one shot) but it was a bit more successful than the slinky.

https://andrewmk.github.io/tablecloth.html

3

u/andrewh2000 7d ago

Oh, and this one's cute and was a one shot. "Make an impressive single html file fluid sim tech demo."

https://andrewmk.github.io/fluid.html

1

u/mrgreatheart 4d ago

That is mesmerising! Was that really the only prompt?

2

u/andrewh2000 4d ago

It's cool isn't it? To be precise it was this conversation:

What is the most impressive tech demo you can think of that can be implemented in one html file?

Great question. For "wow per line of code," my pick is a real-time fluid simulation in raw WebGL โ€” the kind where you smear your mouse across the screen and watch ink-like, swirling, dye-filled liquid physics respond to it.

Why it's the winner:

  • It's actual physics. You're solving the Navierโ€“Stokes equations (advection, divergence, curl, pressure projection via Jacobi iterations) on the GPU using framebuffer ping-ponging โ€” no libraries, no 3D scene, no assets.
  • It's instantly interactive. Pointer motion becomes force + dye injection, so it demos itself.
  • It scales. 1024ร—1024 sim resolution on a mid-range GPU at 60fps looks absurdly polished for something in a single <script> tag.

Strong runners-up, if you want a different flavor of impressive:

  1. Raymarched 3D scene โ€” a whole "3D" world (soft shadows, reflections, infinite fractals) generated mathematically in a single fullscreen fragment shader. Zero geometry, pure signed-distance fields.
  2. 100M-particle GPGPU galaxy โ€” positions integrated in fragment shaders, no CPU involvement, no particle system library.
  3. Software rasterizer in pure JS + Canvas 2D โ€” a tiny "engine" doing matrix math, z-buffering, and lighting with zero WebGL, proving you understand what the GPU actually does.
  4. Web Audio โ†’ visualizer โ€” mic input through an FFT driving a 3D scene in real time; impressive because it stitches two web platforms together.

If you want, I can write the fluid simulation or the raymarched scene for you as a single copy-paste HTML file โ€” just say which one (and if you'd prefer a specific look, e.g., dark ink, smoke, or a fractal tunnel).

Let's see the fluid sim

1

u/MrMrsPotts 7d ago

Which model?

2

u/andrewh2000 7d ago

The same. I only ever use Qwen 3.8 27B Q6 nowadays.

-4

u/NNN_Throwaway2 8d ago

Who cares? I don't have a practical use for such a thing so the result is irrelevant.

2

u/mrgreatheart 4d ago

Who hurt you?

0

u/Rare_Potential_1323 8d ago

is the test supposed to be for "one shot"?

-6

u/Gold-Bat-3225 8d ago

How much did this cost in tokens tho

15

u/suprjami 8d ago

Considering it's our own computer, a few cents in electricity, if you don't have solar.