added entity factory