logoalt Hacker News

I'm making LLMs work on small and old devices

268 points • by mrashad74 • yesterday at 3:23 PM • 88 comments • view on HN

Comments

Farmadupe2 • yesterday at 5:25 PM

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."

➕ show 3 replies
mrashad74 • yesterday at 3:23 PM

Recently I started this open source project at my AI company, where I'm trying to make LLMs working

Now Reached 16B models running on iPad Air 1st gen and xiaomi tv box, both have less than 1GB of usable memory, and reached some decent speeds given the hardware.

I'm open sourcing the effort done, kernels developed and results for everyone to re-produce and push more, also the modified models are on hugging face : https://huggingface.co/hyperionaidev

I want a more challenging device, what do you think?

➕ show 5 replies
nico • yesterday at 6:10 PM

This is very cool. Love the trend of optimizing small models

I’ve been working on small local models and it’s amazing how fast the tech has progressed

A year ago, I was creating conversational characters by finetuning a qwen 2.5 0.5b param model, and it worked pretty well. But no reasoning or math capabilities, and still required some decent specs to run; could maybe do well enough in a beefy raspberry pi

But now, I have a locally trained 6.5M param model that does reasoning, solves multi-step math problems, does simple physics problem simulation, tool calling, RAG and conversational chat. Total size about 30MB packaged for ONNX, and runs with <10ms latency in the browser

➕ show 1 reply
yjftsjthsd-h • yesterday at 5:16 PM

It's technically sweet regardless, so don't take this as even a little bit of negative pushback, but I am curious what the utility of these small models is? Are they smart enough to be useful on practical tasks? What are people doing with them?

➕ show 6 replies
genxy • yesterday at 9:31 PM

The AI botnet is going to fill every crevice of civilization, do you want AI ants? This is how we get AI ants.

➕ show 1 reply
jedbrooke • yesterday at 4:47 PM

in a similar vein, somebody got tinystories LLM running on the nintendo wii, including gpu acceleration [0].

0: https://github.com/brysontang/iiama2.c

➕ show 1 reply
simedw • yesterday at 6:54 PM

Thanks for sharing! I'm exploring a similar direction, but optimising for extreme model size. I have gotten an LLM down to 970 KB, with some interesting results compared to GPT-2 (small).

➕ show 2 replies
dava96 • yesterday at 4:08 PM

This is really cool man. I like this on going trend of resurrecting old tech with AI and this is yet another avenue to explore.

I'd be interested in seeing some older flag ship mobile devices

➕ show 1 reply
rcarmo • yesterday at 8:25 PM

I'm doing https://github.com/rcarmo/go-pherence for the same reason. We should swap notes.

meisel • yesterday at 9:55 PM

Is this the new version of "Can it run Doom"?. Maybe, "can it run Qwen?"

hasperdi • yesterday at 5:31 PM

What can these small models do? Are they just for novelty?

➕ show 1 reply
datadrivenangel • yesterday at 6:07 PM

So does it make sense to try and run models on older 4gb GPUs? I assume the energy efficiency isn't worth it?

➕ show 2 replies
nico • yesterday at 6:02 PM

> Device #1 is a Xiaomi TV Box S (3rd Gen): Amlogic S7D, 4× Cortex-A55 @ 2.5 GHz, 1.9 GB of RAM (about 1 GB usable)

Whoah!! A tv has almost 2GB of ram?! Does it need it to run Chrome or Electron? /s Ouch

➕ show 1 reply
ForHackernews • yesterday at 4:38 PM

This is great. I've recently been playing with repurposing some old thin clients as homelab Linux machines

Not my site, but same idea: https://www.parkytowers.me.uk/thin/

All this old/obsolete gear is plenty capable when used with the right software.

➕ show 2 replies
raadxa09 • yesterday at 10:03 PM

but why that matters in the age of scaling llm ??

fiestaman • yesterday at 6:09 PM

machine spirits are coming for my calculator

nullstyle • yesterday at 6:05 PM

This is the lord’s work right here. Models at the the intersection of small and useful — forthcoming models, admittedly— will be in the toolset that the next generation of poor kids will use to build a more egalitarian world.

➕ show 1 reply
hypfer • yesterday at 5:57 PM

It appears that it's not you doing that but claude doing that.

➕ show 3 replies
mkanephl • yesterday at 5:11 PM

ESP P4 or ESP S31?

➕ show 1 reply
shevy-java • yesterday at 9:32 PM

AI skynet is winning. The spread of the slop is unstoppable now.

Alice_0307 • yesterday at 7:33 PM

[dead]

bigfamilyparent • yesterday at 5:42 PM

[flagged]

gabucino • yesterday at 4:43 PM

[dead]