NEWS & ANALYSIS / SOFTWARE ENGINEERING
How Anthropic rewrote the front door to Claude without closing it.
Anthropic used one Claude reply to check two versions of its Messages API. Customers didn’t have to ask twice.
Published · Software engineering · How to read our dates
When an app asks Claude a question, the Messages application programming interface (API) gets the request ready and delivers the answer a piece at a time. Anthropic wanted to replace the Python code doing that work with Rust. The new code had to be more efficient, but to the person asking the question, the switch should be unremarkable.
In a November 25 engineering report, Anthropic explains how it moved public traffic to Rust in September without taking the service offline. Claude wrote a first version of the main request path in about a week. The harder job for the Super Intelligence (SI) tool and its engineers was showing that the replacement handled all the little things customers already relied on.
What an emoji revealed
One difference came down to how the two languages wrote an emoji. In a message describing a tool call, Python could spell the character out as a sequence of codes, while Rust kept the character itself. A reader would recognize the same emoji, but the two versions weren’t sending exactly the same bytes to Claude. A passing test hadn’t told the team that.
Checking the answers posed a different puzzle. Ask a model the same question twice and you may get two perfectly good but different replies. Which differences came from the rewrite? Anthropic ran Claude just once, then let the Rust code process the same reply as the Python code. Engineers could compare what each version delivered without a second model call or a second charge to the customer.
The team recorded where differences occurred and how long they were, rather than reading customers’ messages. Claude could use those clues to make its own examples and propose fixes. Engineers still decided whether a fix belonged in the service: making two outputs match today wasn’t enough if the change would have to be thrown away tomorrow.
Less work for the same request
Anthropic reports that the new API used about 70% less central processing unit (CPU) time per request in the region it measured. That is a saving in the software around Claude, not a claim that the model itself needs 70% less computing power. For a developer maintaining a busy service, the most useful part may be the comparison itself: before asking customers to trust a replacement, let it handle the same answer and show where it differs.