Added support for querying the known knowledge.

Use 'query f(a,?x).' for example.