implement the auto mode for the application.