State Machine
3 posts

Agent Loop——How Does an AI's "Brain" Work?
Deep dive into Claude Code’s core Agent Loop: the complete lifecycle from user input to model response. Unveiling the query.ts state machine, tool execution orchestration, and continuation decision logic to understand how the AI coding assistant “thinks” and “acts.”

Don't Underestimate Rust Enums: A Complete Hands-On Guide
Rust enums are far more than a set of constants. They carry data, drive state machines, replace null, and unify error handling. This guide walks you from basics to recursive enums with real code examples.

Rust Async State Machine, Unmasked: How Future, poll, and Waker Really Work
A practical deep dive into Rust async: why calling an async function doesn’t run it, how the compiler turns async into a state machine, and how executors drive tasks forward with poll and Waker. Understand the real mechanics behind async/await.
