Put logic to find matching spec into #get_matching_spec