frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Show HN: ModernBERT in Pure C

https://github.com/hardik-vala/modernbert.c
3•HardikVala•1d ago
A minimal implementation of ModernBERT in pure C, inspired by karpathy's llama2.c. The core (tokenizer + inference code) is around 1000 lines of code with no dependencies (except OpenBLAS for fast matrix multiplication, and PCRE for regex).

If you don't know, ModernBERT is a new encoder-only model from answer.ai. Unlike decoder-only models like Llama, encoder models process all input tokens in a single pass (no autoregression), which makes them great for tasks like token classification.

The implementation supports loading any ModernBERT checkpoint from Hugging Face. I've tested it with the base model and a token classification model for anonymizing PII. You can get >1200 tokens/s throughput on a single thread (slightly better than pytorch implementation), though that's not directly comparable to decoder models since there's no token-by-token generation.

I hard-coded the architecture to keep things simple and readable. The tokenizer is a from-scratch BPE implementation that handles most cases (though it's missing some edge cases). The main goal was to support a lightweight deployment of this model, without the heavy baggage of the pytorch ecosystem.

Enjoy.

Comments

soleveloper•1h ago
Hey, cool initiative!

Worth mentioning in the title that it's CPU-only: >1200 tokens/s on a single thread is impressive.

Have you considered doing optimization iterations like nanogpt-speedrun? Would be interesting to see how far you can push the performance.

Show HN: A better Hacker News front end

https://hakkernieuws.vercel.app/top
24•AntonioEritas•1h ago•39 comments

Show HN: Newcomer Ranking – Alternative to GitHub Trending for New Repos

https://git-stars.org/ranking/newcomers
6•zxcholmes•1h ago•2 comments

Show HN: Nova: Open-source solution for CAD file conflicts

https://github.com/agg111/nova
2•aishwaryagune•1h ago•0 comments

Show HN: The Shape of YouTube

https://soy.leg.ovh/
26•hide_on_bush•1w ago•11 comments

Show HN: WP-Easy, framework to build WordPress themes

https://github.com/drewbaker/wp-easy
2•drewrbaker•7h ago•0 comments

Show HN: ServiceRadar – open-source Network Observability Platform

https://github.com/carverauto/serviceradar
55•carverauto•1d ago•3 comments

Show HN: We packaged an MCP server inside Chromium

https://github.com/browseros-ai/BrowserOS/blob/main/docs/browseros-mcp/how-to-guide.mdx
44•felarof•1d ago•16 comments

Show HN: Inkeep (YC W23) – Agent Builder to create agents in code or visually

https://github.com/inkeep/agents
77•engomez•2d ago•49 comments

Show HN: Land use visualization for European countries

https://onsland.koenvangilst.nl/
17•vnglst•1d ago•6 comments

Show HN: A large format XY scanning hyperspectral camera

https://www.anfractuosity.com/projects/waverider/
44•anfractuosity•1w ago•10 comments

Show HN: Firm, a text-based work management system

https://github.com/42futures/firm
168•danielrothmann•4d ago•60 comments

Show HN: Odyis: lunar lander (1979) clone written in Rust

https://ad301.org/blog/odyis.php
2•pilkiad•14h ago•0 comments

Show HN: Halloy – Modern IRC client

https://github.com/squidowl/halloy
373•culinary-robot•3d ago•97 comments

Show HN: Compression-Resistant Data Transfers

https://github.com/ianling/steg-experiments
27•iaaan•1w ago•6 comments

Show HN: Open-source implementation of Stanford's self-learning agent framework

https://github.com/kayba-ai/agentic-context-engine
6•kayba•18h ago•1 comments

SHOW HN: I made a site for 100% location independent jobs too

https://job.careers/
2•lanmao_163•19h ago•1 comments

Show HN: Silly Morse code chat app using WebSockets

https://noamtamir.github.io/morwse/
8•noamikotamir•19h ago•2 comments

Show HN: Scriber Pro – Offline AI transcription for macOS

https://scriberpro.cc/hn/
135•rezivor•3d ago•111 comments

Show HN: Metorial (YC F25) – Vercel for MCP

https://github.com/metorial/metorial
59•tobihrbr•4d ago•25 comments

Show HN: Trott – search,sort,extract social media videos(ig,yt,tiktok)

https://trott.hattimatimlabs.in
37•sudo712•3d ago•11 comments

Show HN: I Built an AI Maturity Model for Software Engineers (and No One Cared)

https://github.com/Gigacore/AI-Maturity-Model
11•Gigacore•2d ago•2 comments

Show HN: SQLite Online – 11 years of solo development, 11K daily users

https://sqliteonline.com/
463•sqliteonline•5d ago•142 comments

Show HN: I built a simple ambient sound app with no ads or subscriptions

https://ambisounds.app/
309•alpaca121•6d ago•118 comments

Show HN: Specific (YC F25) – Build backends with specifications instead of code

https://specific.dev/
29•fabianlindfors•3d ago•14 comments

Show HN: OnlyJPG – Client-Side PNG/HEIC/AVIF/PDF/etc to JPG

https://onlyjpg.com
61•johnnyApplePRNG•1d ago•41 comments

Show HN: FastApps – zero-boilerplate framework for building ChatGPT apps

https://www.fastapps.org
2•zachpark•1d ago•7 comments

Show HN: I made an esoteric programming language that's read like a spellbook

https://github.com/sirbread/spellscript
176•sirbread•1w ago•57 comments

Show HN: AI toy I worked on is in stores

https://www.walmart.com/ip/SANTA-SMAGICAL-PHONE/16364964771
156•Sean-Der•6d ago•174 comments

Show HN: Code First CDC from Postgres to ClickHouse with MooseStack

https://github.com/514-labs/debezium-cdc
10•okane•2d ago•6 comments

Show HN: Code review for AI native teams

https://github.com/areibman/bottleneck
2•Areibman•1d ago•0 comments