updated trestle to use graph search to do matching.