An AI agent combines a model with instructions, tools, memory, and a control loop. Understanding how those parts interact ...