Cleaned up the schema and added additional validation