HNHacker News
TopNewBestAskShowJobs

thamer

2,913 karma · joined October 5, 2007

submissionscomments
thamer··on Moving beyond fork() + exec()
Redis is the kind of process where this matters a lot, and while fork() doesn't copy the memory, it still needs to copy the page table. For a process holding tens of GBs of RAM, fork() can take a long time, and there's one every time Redis dumps its .rdb file or rewrites its binary log ("AOF").

Even back in 2012 this blog post showed the high cost of this operation: https://redis.io/blog/testing-fork-time-on-awsxen-infrastruc...

On an m2.xlarge using ~25GB of RAM, fork() took 5.67 seconds. That's a long pause when Redis clients typically experience single-digit msec latency for most operations. Yes, that's only the time needed to copy the page table. It's surprising they don't mention huge pages, it seems like it would be a key consideration here.

No doubt hardware is faster 14 years later, but Redis instances likely use more RAM too. It'd be interesting to see this benchmark revisited.

thamer··on David Attenborough's 100th Birthday
Searching for David Attenborough on Google also shows a tribute, with drawings of animals and a "Thank You Sir David".

https://www.google.com/search?q=david+attenborough

thamer··on GitHub Stacked PRs
> it invalidates so much work that comes after it.

No, not necessarily.

I work on a large repo and new features often involve changes to 3 different services: 2 from the backend, and the frontend UI. Sending a single PR with changes to all 3 services is really not ideal: the total diff size in a feature I added recently was maybe 600+ lines, and the reviewers for frontend and backend changes are different people. The changes in the 2 backend services can be thought of as business logic on one side and interactions with external platforms on the other. The business logic can't work without integrating calls to external APIs, and the UI can't work without the business logic.

These days I open 3 separate PRs and the software only works once all 3 are merged and built. It would be great to have all of them as a single package that's still testable and reviewable as 3 distinct parts. The UI reviewer can check out the whole stacked PR and see it running locally with a functional backend, something that's not possible without a lot of manual work when we have 3 PRs.

thamer··on Native Instant Space Switching on macOS
You don't need to full screen anything to use macOS spaces for O(1) app-switching, instead of O(N) by pressing Cmd+Tab repeatedly to linearly scan your list of applications.

The rule is simple: one app per space, and Ctrl+{1,2,3…} switches to the corresponding space in O(1). For me space 1 is an IDE + terminal, 2 browser, 3 messaging, 4 bug tracker, 5–6 AI agents etc. It was fast to learn: get a DM, press ^3; to file a bug, press ^4 etc. I use this with the Rectangle app for window tiling, and this combination works great for me; I rarely ever use Cmd+Tab.

I also have a personal menubar app that's very similar to SpaceName, to quickly get the current ID when multiple spaces have a similar layout (e.g. terminal takes the left half, a browser the right half).

thamer··on GitHub DMCA Notices to Anthropic Claude Code Repos
This was followed the next day by a partial retraction: https://github.com/github/dmca/blob/master/2026/04/2026-04-0...

The original applied to "8.1K" repositories, and now the partial retraction means they're only taking down one repo "and the 96 fork URLs individually listed in the original notice".

What was different about these?

thamer··on Apideck CLI – An AI-agent interface with much lower context consumption than MCP
There is not a lot to learn to understand the basics, but maybe one step that's not necessarily documented is the overall workflow and why it's arranged this way. You mentioned the LLM "using web search" and it's a related idea: LLMs don't run web searches themselves when you're using an MCP client, they ask the client to do it.

You can think of an MCP server as a process exposing some tools. It runs on your machine communicating via stdin/stdout, or on a server over HTTP. It exposes a list of tools, each tool has a name and named+typed parameters, just like a list of functions in a program. When you "add" an MCP server to Claude Code or any other client, you simply tell this client app on your machine about this list of tools and it will include this list in its requests to the LLM alongside your prompt.

When the LLM receives your prompt and decides that one of the tools listed alongside would be helpful to answer you, it doesn't return a regular response to your client but a "tool call" message saying: "call <this tool> with <these parameters>". Your client does this, and sends back the tool call result to the LLM, which will take this into account to respond to your prompt.

That's pretty much all there is to it: LLMs can't connect to your email or your GitHub account or anything else; your local apps can. MCP is just a way for LLMs to ask clients to call tools and provide the response.

1. You: {message: "hey Claude, how many PRs are open on my GitHub repo foo/bar?", tools: [... github__pr_list(org:string, repo:string) -> [PullRequest], ...] } 2. Anthropic API: {tool_use: {id: 123, name: github__pr_list, input:{org: foo, repo: bar}}} 3. You: {tool_result: {id: 123, content: [list of PRs in JSON]} } 4. Anthropic API: {message: "I see 3 PRs in your repo foo/bar"}

that's it.

If you want to go deeper the MCP website[1] is relatively accessible, although you definitely don't need to know all the details of the protocol to use MCP. If all you need is to use MCP servers and not blow up your context with a massive list of tools that are included with each prompt, I don't think you need to know much more than what I described above.

[1] https://modelcontextprotocol.io/docs/learn/architecture

thamer··on Show HN: Deff – Side-by-side Git diff review in your terminal
I had tried `delta` a few years ago but eventually went with `diff-so-fancy`[1]

The two are kind of similar if I remember correctly, and both offer a lot of config options to change the style and more. I mostly use it for diffs involving long lines since it highlights changes within a line, which makes it easier to spot such edits.

I have an alias set in `~/.gitconfig` to pipe the output of `git diff` (with options) to `diff-so-fancy` with `git diffs`:

    diffs = "!f() { git diff $@ | diff-so-fancy; }; f"

[1] https://github.com/so-fancy/diff-so-fancy
thamer··on Map To Poster – Create Art of your favourite city
Yes, the blue and orange dots are from the water and parks Nodes and Ways in the OSM data.

It doesn't look like the orange and blue colors are part of the theme definitions, so the rendering library may be using some default values. This is why they are rendered in the same color on images using different theme files.

thamer··on BERT is just a single text diffusion step
The March 2025 blog post by Anthropic titled "Tracing the thoughts of a large language model"[1] is a great introduction to this research, showing how their language model activates features representing concepts that will eventually get connected at some later point as the output tokens are produced.

The associated paper[2] goes into a lot more detail, and includes interactive features that help illustrate how the model "thinks" ahead of time.

[1] https://www.anthropic.com/research/tracing-thoughts-language...

[2] https://transformer-circuits.pub/2025/attribution-graphs/bio...

thamer··on Show HN: MCP Server Installation Instructions Generator
> Is there a specific reason, you prefer stio servers over http servers?

Yes: the main reason is that I control which applications are configured with the command/args/environment to run the MCP server, instead of exposing a service on my localhost that any process on my computer can connect to (or worse, on my network if it listens on all interfaces).

I mostly run MCP servers that I've written, but otherwise most of the third party ones I use are related to software development and AI providers (e.g. context7, Replicate, ElevenLabs…). The last two costs me money when their tools are invoked, so I'm not about to expose them on a port given that auth doesn't happen at the protocol level.

thamer··on Show HN: MCP Server Installation Instructions Generator
Is this only about remote MCP servers? The instructions all seem to contain a URL, but personally almost all the MCP servers I'm running locally are stdio based and not networked. Are you planning to support those in some way?

There's also this new effort by Anthropic to provide a packaging system for MCP servers, called MCPB or MCP Bundles[1]. A bundle is a zip file with a manifest inside it, a bit like how Chrome extensions are structured (maybe VSCode extensions too?).

Is this something you're looking to integrate with? I can't say I have seen any MCPB files anywhere just yet, but with a focus on simple installs and given that Anthropic introduced MCP in the first place, I wouldn't be surprised if this new format also got some traction. These archives could contain a lot more data than the small amount you're currently encoding in the URL though[2].

[1] https://www.npmjs.com/package/@anthropic-ai/mcpb

[2] https://github.com/anthropics/mcpb/blob/main/README.md#direc...

thamer··on More on Apple's Trust-Eroding 'F1 the Movie' Wallet Ad
This is what it looks like, the switch is for "Offers & Promotions": https://i.imgur.com/wodOoBo.jpeg

From the Wallet app, tap on "…" at the top right, then "notifications".

thamer··on Highlights from the Claude 4 system prompt
They're not just from AI-generated text. Some of us humans use en dashes and em dashes in the right context, since they're easy to type on macOS: alt+hyphen and alt+shift+hyphen respectively.

On both iOS and modern Android I believe you can access them with a long press on hyphen.

thamer··on Show HN: Real-time AI Voice Chat at ~500ms Latency
Does Dia support configuring voices now? I looked at it when it was first released, and you could only specify [S1] [S2] for the speakers, but not how they would sound.

There was also a very prominent issue where the voices would be sped up if the text was over a few sentences long; the longer the text, the faster it was spoken. One suggestion was to split the conversation into chunks with only one or two "turns" per speaker, but then you'd hear two voices then two more, then two more… with no way to configure any of it.

Dia looked cool on the surface when it was released, but it was only a demo for now and not at all usable for any real use case, even for a personal app. I'm sure they'll get to these issues eventually, but most comments I've seen so far recommending it are from people who have not actually used it or they would know of these major limitations.

thamer··on Someone at YouTube needs glasses
The following CSS equivalent worked for me, using the "Custom CSS by Denis" Chrome extension[1]:

    ytd-rich-grid-renderer div#contents {
      /* number of video thumbnails per row */
      --ytd-rich-grid-items-per-row: 5 !important;
    
      /* number of Shorts per row in its dedicated section */
      --ytd-rich-grid-slim-items-per-row: 6 !important;
    }

I first tried it with the "User JavaScript and CSS" extension, but somehow it didn't seem able to inject CSS on YouTube. Even a simple `html { border: 5px solid red; }` would not show anything, while I could see it being applied immediately with the "Denis" CSS extension.

If someone can recommend a better alternative for custom CSS, I'd be interested to hear it. I guess Tampermonkey could work, if you have that.

[1] https://chromewebstore.google.com/detail/custom-css-by-denis...

thamer··on Lvgl: Embedded graphics library to create beautiful UIs
The main alternative to LVGL seems to be TouchGFX[1], at least that's the one I've seen mentioned the most in conversations around UI libraries for microcontrollers.

As you wrote these aren't made for desktop apps, but you can use desktop apps to help with UI development using these libraries.

For LVGL there's SquareLine Studio[2], I used it a few years ago and it was helpful. For TouchGFX there's TouchGFXDesigner[3], I haven't used it myself and it seems to run only on Windows.

[1] https://touchgfx.com/

[1] https://squareline.io/

[2] https://www.st.com/en/development-tools/touchgfxdesigner.htm...

thamer··on Lvgl: Embedded graphics library to create beautiful UIs
This is for screens usually controlled by microcontrollers, nothing running close to an operating system like Linux and rarely coming with a GPU.

See for examples ILI9341 or SSD1306 displays[1] or integrated boards with (often) an ESP32 microcontroller and a display attached[2].

[1] displays: https://www.google.com/search?q=SSD1306+OR+ILI9341+display&u...

[2] integrated: https://www.aliexpress.us/w/wholesale-ESP32-LVGL.html?spm=a2...

thamer··on Send Data with Sound
It's probably not slower than words, the rate for English pronunciation is something like 150-200 words per minute only.

That said, the "gibberlink" demo is definitely much slower than even a 28.8k modem (that's kilobit). It sounds cool because we can't understand it and it seems kinda fast, but this is a terribly inefficient way for machines to communicate. It's hard to say how fast they're exchanging data from just listening, but it can't be much more than ~100 bits/sec if I had to guess.

Even in the audible range you could absolutely go hundreds of times faster, but it's much easier to train an LLM that has some audio input capabilities if you keep this low rate and likely very distinct symbols, rather than implementing a proper modem.

But why even have to use a modem though? Limiting communication to audio-only is a severe restriction. When AIs are going to "call" other AIs, they will use APIs… not ancient phone lines.

thamer··on Record-breaking neutrino is most energetic ever detected
The kilogram is the base unit of mass in the International System of Units (SI): https://en.wikipedia.org/wiki/SI_base_unit

Time is in seconds, length in meters, temperature in kelvin, etc. A unit of energy like a joule is then defined using these base units, so 1 joule is 1⋅kg⋅m^2⋅s^-2.

thamer··on YouTube's New Hue
> We change the product constantly — we’re talking over 1,700 updates per year!

Good job, the new red is a huge improvement.

Meanwhile the YouTube comment sections are still getting pummeled by bots, trying to scam viewers with fake crypto offerings (90%+ involving an "Elon Musk giveaway") or writing entire threads praising the great investment returns from a genius trader named "Mr Definitely A. RealName" who operates only on WhatsApp.

Take a look at the comments under this video for example, all the references to AMZ6OP are for a scam crypto token that they pretend is being launched by Amazon: https://www.youtube.com/watch?v=JRd_wNHJG4o.

I'm having doubts even reposting this link… please do not believe for a second that any of these claims are real.

I guess changing red to red-ish magenta was apparently more important than addressing the widespread issues that have been plaguing YouTube for years.

thamer··on Record-breaking neutrino is most energetic ever detected
It took a few tries, but I got Wolfram Alpha to compute its velocity compared to the speed of light[1].

I started with:

    sqrt(1-((1/(1+120 PeV / (neutrino mass * c^2)))^2))
but it simply said "data not available". So I changed:

    120 PeV to 120e15 * 1.602176634e-19 kg m^2 s^-2
    neutrino mass to 1.25e-37kg
    speed of light to 299792458 m/s
and finally it gave a numeric result:

    0.999999999999999999999999999999999999829277971
(that's 36 nines in a row). Pasting it in Google says the value is "1", which is… not far off.

If you want details about the way this is calculated, I dug up the formula from an article I'd written about particle velocities in the LHC, back in 2008[2]. For comparison, their 7 TeV protons were going at 0.999999991 × c.

[1] https://www.wolframalpha.com/input?i=sqrt%281-%28%281%2F%281...

[2] https://log.kv.io/post/2008/09/12/lhc-how-fast-do-these-prot...

thamer··on Software engineer pay heatmap for Europe
It's not just by region, but at the city level too. There are often significant differences between salaries in capital cities vs others, as one would expect.

The cost of living is different, larger companies in major population centers have more capital, etc.

thamer··on Botan: Crypto and TLS for Modern C++
For what it's worth, I've used Botan in a personal project where I needed a few hashing algorithms to verify file integrity (SHA-1, SHA-256, even MD5), and also used Botan's base 64 decoder in the same project.

I found its modern "style" pleasant to write code for, and easy to integrate with good docs. That said, I did notice the large number of algorithms as others have pointed out, and I'm not sure I'd use it for more serious purposes when libsodium is well-established. It certainly wouldn't be an obvious choice.

But to quickly add support for common hash algorithms in a small project, I thought it was a good option and enjoyed its API design and simplicity.

thamer··on Boeing 787s must be reset every 51 days or 'misleading data' is shown (2020)
Where did you get 5 hours and a half? It seems to be closer to 31 hours:

    >>> round((4406400000 - 2**32)/(1000 * 3600), 3)
    30.954
thamer··on Can SpaceX land a rocket with 1/2 cm accuracy?
> I think < 10 cm accuracy is achievable

If you don't know how precise GPS receivers can get with dead reckoning techniques, this demo of someone "drawing" onto a map of their driveway using a GPS receiver is very impressive: https://youtu.be/3tQjIHFcJVg?t=245

It looks like they're getting measurements that are only a few inches away of the module's real position, although of course the conditions seem favorable with an unobstructed sky and consistent alignment.

The module they use is a ZED-F9P by u-blox. I've used ~$50 u-blox GPS modules in DIY electronic projects before since they're often the brand you'll get when buying GPS modules, but this particular type with dead reckoning is much more expensive. Sparkfun has it for $275 for example: https://www.sparkfun.com/products/16481.

thamer··on IOCCC Flight Simulator (2010)
There are a number of blog posts online and StackOverflow questions explaining IOCCC entries, and they generally seem to be built/obfuscated by hand. It's an art and it's far from trivial, which is one of the reasons why the contest exists :)

For an example, see this StackOverflow question and its detailed answers for an overview of what obfuscation techniques can be used, although many more exist of course: https://stackoverflow.com/questions/15393441/obfuscated-c-co...

I was able to compile it on macOS, but had to include an extra flag to stop clang from being too strict (version 16):

    cc -Wno-implicit-function-declaration -std=c89 -o test test.c
    ./test
thamer··on C++ proposal: There are exactly 8 bits in a byte
This doesn't feel like a serious question, but in case this is still a mystery to you… the name bit is a portmanteau of binary digit, and as indicated by the word "binary", there are only two possible digits that can be used as values for a bit: 0 and 1.
thamer··on Telegram founder Pavel Durov arrested at French airport
From the article, that's a massive pile of charges they're dumping onto him, all apparently because people use Telegram in ways the French state disapproves of?

> Why was he under threat of a search warrant? > The justice department considers that the lack of moderation, lack of cooperation with law enforcement, and the tools offered by Telegram (disposable number, cryptocurrencies, etc.) make him an accomplice to drug trafficking, pedo-criminal offenses and fraud.

thamer··on Don't use booleans (2019)
As far as I know it is not a native feature, but inline hints for parameter names can be added with a VSCode extension called "Inline Parameters for VSCode": https://marketplace.visualstudio.com/items?itemName=liamhamm...

The only languages it supports are JavaScript, TypeScript, PHP, and Lua. I can confirm that it works for JavaScript and TypeScript, I haven't tried the other two.

A similar extension named "Inline Parameters Extended for VSCode" supports a different set of languages: Golang, Java, Lua, PHP, and Python. It seems to be a fork of the aforementioned.

thamer··on The Pumpkin Eclipse
This attack happened a few days before Halloween 2023 (pumpkins), with a large drop in the number of devices connected to the Internet – like how an eclipse suddenly brings a period of darkness, maybe?

This is just my interpretation, I also found it cryptic.

Page 1 of 17Next →