Lurker News
Hi HN,

I built a specialized inference engine for running 4-bit Gemma 4 26B-A4B-IT on any M-series Mac using about 2 GB of RAM. It is called TurboFieldfare and is written in Swift and Metal.
I have always adored on-device AI. It feels like magic that you can run a powerful NN on your Mac or iPhone. So I wanted to push the limits a bit and run a model whose weights don’t fit in memory.
The model’s 4-bit quantized weights occupy roughly 14 GB, which makes running it with conventional inference tools almost impossible on an 8 GB or even 16 GB Mac once the OS, applications, and KV cache are included.
The trick is to keep the shared part of the model and the KV cache in RAM, then stream only the routed experts needed for each token from SSD. An SSD is way slower than RAM, so the runtime uses a small expert cache and bounded parallel `pread`. While those reads are in flight, the GPU runs the shared part of the layer.
I ran more than 100 experiments. Most didn’t work. A few got me here. The experiments are described in the GitHub repo.
It currently generates 5–6 tok/s on an 8 GB M2 MacBook Air and 31–35 tok/s on an M5 MacBook Pro.
I also added an experimental OpenAI-compatible local server. It supports streaming and tool calls, and reuses one prompt prefix from the KV cache.
Try it! The Mac app is easy to install. On the first run, it will download 15 GB of weights from Hugging Face. The model is surprisingly capable.
I would love any kind of feedback!

Comments (342) 81 threads

Show all comments

Showing thread 6 of 81

woadwarrior017 replies#
> The measured result is a reference point, not a performance ceiling.

Claude was here.

sebmellen1 reply#
I grind my teeth when I see it. It's so pervasive that I worry I'll pick up the same ticks by reading so much Claudeslop.
micromacrofoot1 reply#
you're absolutely right
0x20cowboy10 replies#
But here’s the thing nobody tells you, it’s a repository not a spaceship. Not a pizza, not a cow, but an undeniable disco boot. Let’s delve into this.

Continue this thread — 10 replies

UmYeahNo#
"I ran more than 100 experiments. Most didn’t work. A few got me here."

And here.

jddj#
I'm sure it was a chatgptism first, but I wouldn't accuse a western company of distillation.

In all fairness, maybe it's just that they let some post-2022 recipe blogs get into the training runs around ~4.6-4.8 time

andrehacker6 replies#
Let my karma burn for saying this: Maybe it is time to let this go man. These comments are really the new incarnation of "grammar policing". (1)

They don't add anything of value, did the author use an LLM to fix his prose but no useless slop was added in the process: who cares ? Is the article useless slop: fine, downvote it to oblivion.
(1) For those not old enough to remember that wonderful practice please use your nearest LLM to find out or, you know, visit a library and do your own research.

woadwarrior011 reply#
I'm not making any moral judgements based on it, merely observing it.
rpdillon1 reply#
The criticism is not that it's moralizing, but that it's boring.

Continue this thread — 1 reply

itsdesmond3 replies#
The writing is made worse by a specific choice which the commentator identified. That’s actionable feedback.
govping8 replies#
how is it made worse in this case?

Continue this thread — 8 replies

e12e#
I don't know what the author's native language is, but I assume it's something I'd need machine translation for anyway. Having it in good (if not Nobel prize level great) English is much easier - and will probably be easier to find again via search.
trinix912#
If they feel the need to polish their texts with LLMs because they’re not comfortable with English, how would they tell the output is bad?

I can tell you first hand it’s sometimes hard to figure out what is LLM writing and what isn’t, English isn’t my first language either.

wellthisisgreat#
I am with you in principle.

There is 0 wrong with using AI to write a draft.
However catching the glaring LLMisms shows that the person did a pass and tried to edit the obvious LLMisms.
For me, unprocessed AI output is perfectly fine as the means to the end, but not as a final output.

latexr1 reply#
> Is the article useless slop: fine, downvote it to oblivion.

You can’t downvote submissions on HN, only flag them. Identifying when text was written by LLMs is a useful signal. Maybe you don’t like these repeated comments, but I’d bet the people making them hate even more that they feel they wasted their time reading it.

rpdillon#
This attitude will just cause people to write the same thing with AI and then ask it to strip out all the tells. I found it works just fine, but then you push usage underground, making it harder to detect, which isn't in your best interest, assuming you want to be able to detect and avoid low-effort writing.
JSR_FDED2 replies#
Why would you want to signal low effort for your writing and the related project?
jryle701 reply#
It's not low effort. The author had to write in English, not their native, and then used LLM to polish it. The sentence itself conveyed a real point. They cared how their article came across. That's much more effort than the boring "Claude was here" comment that took a second to write but costs real energy to appear, and once again spurred a worthless debate.

Let it go FFS.

Continue this thread — 1 reply

Almondsetat#
The world is not the Unites States
gitpusher42#
Thank you! Text is not the main part of this repo. The main part is the technology and the list of experiments (and some useful knowledge I got from this project, haha). I have always been bad at writing or editing text (in both my native language and English), but without text it is impossible to share this project online.

Text was the last and most difficult part for me. It is not perfect (and this project is not perfect as well), but I believe it does the job of communicating my ideas

gitpusher421 reply#
I am not native, my English is far away from perfect. I am using LLMs for checking my texts or grammar. I always trying to edit it properly, but sometimes I missing parts like that because I don't really have this "language feeling" as natives. Apologies for this
sebmellen1 reply#
Friendly feedback: write in your native language and use https://deepl.com to translate. I am fluent in both German and English. I find Deepl does a much better job at capturing the direct translation of what I’m saying than using Claude/ChatGPT, etc. Results may very for your language…

Very nice work! Sorry that the AI comments partially overshadowed it.

gitpusher42#
Thanks! Will try!
apothegm1 reply#
Okay, I’m the first to get annoyed at LLM-ese. But language requires the ability to say that something is A and not B. There are certain phrasings of that that are painfully Claude-esque, but ffs the one you quoted is the type of thing an actual human being is just as likely to say.
nsonha1 reply#
I don’t get why that construction is associated with Claude. I’ve never picked it up from reading Claude output.

As a English-as-a-second-language speaker I’ve been using that formation long before llm and it has legitimate usage

Continue this thread — 1 reply

Continue this thread — 1 more reply