Founding sponsor spots openAI agent jobsThe numbersAgents rankedAgents with codeTopics
Agents in the Wild

Claude Code ported nanochat's inference to C++, roughly 1/3 as fast

Could AI write serious, low-level C++ from scratch? Leaning heavily on Claude Code, the writer rebuilt nanochat's inference on ggml as a drop-in replacement. On an M3 Max it runs at roughly 1/3 of PyTorch's throughput.

Done withClaude CodeSpotted· by HN user makechan· Oct 29, 2026

Result Suspected bottleneck: no bf16 support yet

“I relied heavily on Claude Code (CC) for the implementation. Overall, I am both impressed and genuinely pleased with the experience.”
From the source: Hacker News · 2026-01-10

Spotted: found in the wild. Details are as reported by the source above and have not been independently verified.

What they did

The writer, who used to work in C++ day to day at tech companies, wanted to see if AI could handle a lower-level C++ implementation of a complex system from scratch. They re-implemented the inference part of Andrej Karpathy’s nanochat in C++ on top of ggml, as a library and Python wrapper that swaps out nanochat’s GPT and KVCache classes. They relied heavily on Claude Code for the implementation.

How it went

It works as a drop-in replacement, so far tested only with chat_web.py, on CPU and Metal. On an M3 Max its throughput is roughly 1/3 that of the original PyTorch version, which the writer suspects comes from the lack of bf16 support. They’re impressed and genuinely pleased with the experience.

Try it yourself with Claude Code
I want a C++ re-implementation of the inference part of [project], built on [ggml], as a library with a Python wrapper that can replace [these classes] in the existing pipeline. Keep dependencies to a minimum and add unit tests. Benchmark it against the original on my machine and show me the results before I swap it into anything.

A starting prompt written by Agents in the Wild. Fill in the [brackets], and check what the agent does before it sends, pays for or deletes anything.

★ 2 · Apache-2.0 · C++ · Last update Jan 10, 2026

The builder's own repo, as the source says. We haven't audited this code. Read it before you run it.

Keep browsing

All 149 Claude Code use casesAll 309 Engineering use cases
Agents rankedAgents with codeTopicsFounding sponsor spots openAI agent jobsThe numbers

Hire here

Reach people who put AI agents to work.

2,208Open AI jobs listed
124AI companies hiring
Founding5 employer slots, price locked

Post a job

$299 for 30 days in its lane, on the jobs page and in Google's job search. $499 to pin it to the top of its lane and the homepage. Live within minutes of payment.

Post a job ($299) →

Featured employer slot

Your brand in the rotating slots on desktop sidebars and the sponsor strips on phones, across every page, rotating every 10 seconds. Your link carries ?ref=agentsinthewild, so you see every visit we send. $250/month; the first 5 keep that price for 12 months.

Become a founding employer ($250/month) →

Paid through Stripe. Paying never changes which jobs or cases we list, or their order, except a Featured post's pin. See the terms.

Submit an agent in the wild

Have an agent doing real work, or spotted one? Send the link and tell us the result. You'll be credited on the case, and every submission is reviewed before it's published.

By submitting, you agree to our Terms and Privacy Policy.