better definition of types