More intelligent AutomaticEnv behavior and updated documentation.