Improved Attributes by only allowing creation of keys with valid types