function to convert json to rdf