Mehdi Akiki

Writing archive

Everything published under Writing, newest first. Each entry is labelled as part of an investigation, an article or reference. Short engineering notes have their own archive.

  • Published on

    Article · Through the layers

    Why Rust Async Futures Get So Large

    Rust async functions store every value needed after an await. Learn to measure future size, identify saved fields, and reduce it without boxing everything.
  • Published on

    Article · Through the layers

    Where a Rust String Literal Actually Lives

    When you write let s: &str = "hello world", there are really two things in one line, living in two different places. Here is what each one is, where it lives, and why that explains lifetimes.
  • Published on

    Reference · Interrupted execution

    Give Every Agent Tool Call a Deadline

    When an agent calls a tool, it stops and waits. If the tool is slow, the whole turn is slow, and the user waits with it. The fix is small: put a deadline on every tool call.
  • Published on

    Article · Derived state

    How to Keep Two Systems in Sync

    When you sync two systems with webhooks, the copy slowly becomes wrong: some events are lost, some are duplicated, some arrive in the wrong order. Reconciliation is the way to make the two systems agree again. Here is how to design an API for it.