add environment factory