Add constructor that handles identity and type checking
Merge