The source code of our system PARASEMPRE is released at http://www-nlp.stanford.edu/ software/sempre/.
the basic template is a join of a binary and an entity, where a binary can either be one property p.e (#1 in the table) or two properties p 1 .p 2 .e (#2).