CONSULTING AGREEMENT (As Amended and Restated)