[rdf] cleaning up usage of TermProxy.mint_node and TermProxy.build