Self evolving AI agents modeled and predicted using gas dynamics

A Self-Evolving Agent Runs Like a Gas: Describing and Predicting Its Evolution with Fluid Dynamics

Graphics

Summary

The paper looks at AI agents that improve themselves by changing their own programs over time. The authors use ideas from how gases behave to describe and predict how these agents change and evolve continuously. They create mathematical rules that track how the agents' internal parts interact and conserve certain quantities like credit and momentum. Their experiments show patterns like waves or energy loss depending on these rules, helping people understand and control these evolving AI systems better.

What this means in practice

  • For ai system engineers: Use the fluid dynamics model to predict and control the evolution of continuously running AI agents with self-modifying code.
  • For distributed system architects: Design validation mechanisms that conserve key properties to improve stability and predictability in large, evolving software systems.

Authors

Haipeng Wang

Abstract

A self-evolving LLM agent improves in service by rewriting its own plugin library under a validation gate. Agent engineering is converging on exactly such agents: single systems in continuous operation, carrying populations of runtime instances (plugins, skills, tools) past the point where anyone can read the library and still predict what the system will do. Yet the run itself, the aggregate motion of that population across hundreds of edit rounds, is unstudied: no theory says whether it relaxes, oscillates, or freezes. A recent kinetic theory supplies the missing level: under four architectural properties, the plugin instances of one agent behave as identical hard spheres whose density obeys a master equation, and the theory is candid that its gate injects and drains credit, momentum is not conserved, and waves are excluded by construction. We argue the boundary is architectural; keeping the four safety theorems, we stack conservation axioms on top. A closed-credit ledger makes credit a collision invariant and unlocks acoustic waves at a measurable, engineerable speed; a zero-sum projection gate conserves centroid momentum unconditionally, for any proposal stream. Both layers are proven and executed: the axis total is conserved to the digit over 66 interventions under a live gate, and the pre-registered decisive probe returns the theory's directional verdict: linear wavefronts where the ledger holds, dissipation where it does not, replicated across two population sizes. For agents that must never stop, the gas description is not a metaphor: it is the measurement interface through which their future becomes readable.