Could id-generation be hidden behind a function? Something like:
    (gen-id (:publisher entity) "schemaorg:Event")
?