All posts
Tag

concurrency

2 posts

Architecture

Tasks and Concurrency: Background Agents at Work

A production AI harness is not single-threaded. Background agents explore codebases, shell commands execute, remote agents run on cloud infrastructure — all while the main conversation continues. This post dissects the task system that manages this concurrency.

8 min read
Tutorial

Clean Code Python: Locking, Idempotency, and Sagas

At 1M transactions per day, two requests modifying the same inventory record is not an edge case. Here is how to prevent lost updates with optimistic locking, double charges with idempotency keys, and partial failures with the saga pattern.

13 min read