We do this by abstracting the structure of the database (and accompanying texts) into a PCFG whose probabilities are learned from training data.
1 we convert the database into rewrite rules and represent them as a weighted directed hypergraph (Gallo et al., 1993).