Add some validations into the graph model used by domgen