Hacker News new | ask | show | jobs
by Farmadupe2 23 days ago
For the last five months or so, opus and fable have both been able to do this task as a soneshot prompt. An inference engine is almost pure compute and to a first approximation the only operation your hardware needs to support to do llm inference is multiplication [the rest of an inference engine is "some trig"].

So to get any model working on $OLD_HARDWARE, the hardest part of the task is now sourcing the hardware itself and giving the agent ssh access -- a modern agent will be able to source a compiler, write the implementation, optimize it, test in qemu (or any other simulator) and push it onto the device.

Example prompt: "write an inference engine for qwen3 0.6b in pure assembly that runs on this device. Write a script to attach the weights to the resulting binary. Prefix is supplied as a stream of u32 token IDs on stdin. The engine streams u32 token IDs on stdout."

5 comments

I agree with you, and I'm using claude and other models heavily, the idea is not in the soneshot - because actually as you see in the logs I posted on github, it took around 107 + 50-ish experiments to figure out which models to run which and push the speed.

I'm treating it as a search algorithm project, where I develop the methdology and search for pushing the limit of devices and searching in a big space of possible kernels and so for what works for a specific hardware.

so I'm looking at it from a different prespective, it takes a lot of brute forcing, and claude can do this well, the whole game (to me) is which directions you push the model into to reduce the search space. and how that learning from very small and tight devices you can scale these techniques.

But in essence, I don't disagree with your sentiment - the goal is not 0.6B models, these are extremely trivial as you mentioned and as I showed in the experiments, the goal is 16B+ models, and this as far as I've seen, requires smart methods to search for optimizations and customizations both to the model and inference engines.

Why did you both say "soneshot"? Same typo of oneshot?
I just asked myself the same thing and wondered if this was some new technique that completely slipped past me. - But it certainly must be a double typo
"double typo"

When you find two sants in the kitchen, you are certain to find more sants. Won't fool ME.

This actually dates back to Warren Buffet saying, there is never just one scockroach in the ktichen
orrr we can listen to paranoia that these 2 comments are just an elaborate advertisement
soneshot - super one shot!
the kind of one shots you get with fable 5.5 :D (it was a double typo)
Soneshot is a much better technique for such and such type of projects
Because the response was written by an LLM running on a tamagotchi
a sentient tamagotchi is not far from us..
It's not clear whether the second one isn't a scheapshot at making fun of the first one.
Hey, this is the Internet. It’s serious business! We shouldn’t make sfun of people!
So funny, I saw this before bed and planned to look it up in the morning thinking I recently missed out on some kind of killer prompt technique. Woke up and came back to this thread to find typos
Typos are a sign of human intelligence :D
What is “soneshot”?
I think it's a typo of "oneshot", referring to a single prompt being able to handle the entire task.
Yes that was my typo. Sorry about that.
It won’t one shot it and it’ll be packed with issues. I know, I have done a few similar toys in the past months. And the biggest challenges will be on the integrity and performance especially if we aren’t too knowledgeable. And considering that I feel the current iteration bullshit more than at one stage this year…
I put my tokens where my mouth is and submitted that exact prompt. Haiku 5.5 is capable of writing that inference engine.

I used my subscription, but the equivalent API cost was $1.20.

https://github.com/Farmadupe/qwen3-asm-agent-demo

Haiku was able to optimize to within reasonably close to the memory bandwidth limit of my laptop.

Not making any statement that this engine is useful, just that it's possible.

KLD is 1e-11 nats vs f32 inference in transformers (measurement script is in branch kld)

Woah I am highly surprised, maybe because I struggled a bit to optimise it on a fpga.
Well, my netbook. Atom n270, 1GB of RAM, 1.5GB potentially with ZRAM. If it can run in that, a Pentium 4 with SSE2 would be the closest setup down.
this would be a nice challange but from what I did, very doable.. not a usable speed maybe.
You mentioned one-shot prompts. What you provided is a zero-shot prompt, not a one-shot prompt. The main difference is that one-shot prompts provide an example and use fewer tokens, where zero-shot prompts will tend to have output that differs in format and correctness on every run.
So true, people think they can prompt AI, tell it to create something amazing and "Novel" so they can feel cool and bragg about it. Shame on such people.
no one said it's amazing or novel, it's just a fun experiement I'm not selling this :) just out of curiousity to explore.
It's okay to share fun thoughts even if you haven't put blood sweat and tears into them.