modified to use separate create and track functions