adding toggle for ai