Clean up matching to share with brainx