Metric learning for text documents | Synapse