did the logic, did some minor integration