C++ implementation of Alessandro Moschitti's Tree Kernel algorithm, from "Making Tree Kernels Practical for Natural Language Learning"
Fetching latest commit…
Cannot retrieve the latest commit at this time
A C++ implementation of nlp tree kernels per Alessandro Moschitti's 2006 paper, "Making Tree Kernels Practical for Natural Language Learning" This is incomplete as-is, it needs something called 'Tree' to parse from the Penn Treebank form, eg: (ROOT (S (NP (PRP$ My) (NN dog)) (ADVP (RB also)) (VP (VBZ likes) (S (VP (VBG eating) (NP (NN sausage))))) (. .))) See http://nlp.stanford.edu:8080/parser. Ask for my tree parser if you really want it. This is commercially useable. I have not yet integrated it with any SVM software, libSVM is my top candidate. If you succeed, let me know or better yet, offer your patches to libSVM. There are several optimizations possible - templating out sigma, making NodePairsDeltaTable an unordered_map, but most of all, storing the Nodes in Sentence in a vector and using indices as pointers to them (to save memory and cache). C bindings would be nice, too. if you make any improvements I'll be happy to take them. Of course, you can just do what you want with it, subject to the BSD license in LICENSE.