You want to do NLP in postgres? I would say that you would need a tool like opennlp to get your tokens and phases, then run a fuzzy matching algorithm.
Unless postgres has nlp capabilities but I am not sure I would use them. You actually want something fairly complex.