The Fundamental Logic of Training