Update AgreementVM to use class instead of function.