Knowledge did not equate to wisdom, and education did not equate to savvy. Whether it was Y'zaks or Mimir, both of them were experts in the field of soul and mind; their theoretical knowledge of rebirth and memory inheritance were second to none, at least on Earth. But when it came to things that happened to Lily, they had not been able to gain an insight, which was as good as Hao Ren's.
Lily's memory loss had nothing to do with the reincarnation of her soul. Instead, it was purely because the First Sage had accidentally chosen the wrong body—a dog, the brain of which was too small for her reincarnation and in the process, the soul of the First Sage had been diluted.
Hao Ren could have described the formula to explain the dilution process during the reincarnation: (genius + idiot) ÷ 2 = Lily.