Added utils part and added some type inference thing