encoding ontology entities now also takes a namespace