Have you tried turning it on and off? More seriously try to remove agent memory or make it refactor it or go through the docs and look for inconsistencies.
But I still don't know how people work with codex when it keeps resetting the context so often, I mean it's surprisingly good at making notes to itself and can follow a long task, but if there are multiple instructions it sometimes forgets some of them.