Agentic Pattern Libraryby Vikas Goyal

The math under agentic AI

Patterns tell you what to build. These models tell you how well it will work: how reliable a chain is, whether an eval result is real, when voting helps and when an agent should stop and ask.

Each page has the same parts: a one-line takeaway, the intuition, the math with derivations, a calculator or simulation, a worked agent example, where it breaks, and a spec for coding agents.

Reliability

Will the agent finish, and how fast? Models for chains, loops and capacity.

Evaluation

Can you trust the numbers your evals report? Models for consistency, significance and judges.

Multi-model interactions

How should several models vote, cascade or route work between them?

Planning and uncertainty

When should the agent act, search further or abstain?