More bug fixes in RDF generation