redesign code for parse/invoke sections