improve command parser