generating model hooked up