finish Agent class