Added basic validator as main loop of io.py