split parsing and validation