scaffold and validation