An automatic XML generator for PGM