A new predictive framework reprograms T cells to sustain immune memory while preserving their ability to fight cancer and infections.