Added the ability to have commands be triggered by a validation function instead of just key words