Note that VTK considers random walks in dependency trees instead of downward paths, i. e. potentially taking into account same nodes multiple times for phrase length greater than two, phenomenon known as tottering.
once we have phrases to compare, we may construct a kernel between them as the product of word kernels if they are of the same length l. we define the Product Kernel (PK) as: where w j i is the i-th word in phrase p j of length l. Alternatively, in particular for phrases of different lengths, we may embed phrases into the embedding space by taking a composition operation on the constituent word embeddings.