Mastering Stateful Agent Workflows for Enterprise Success