Chain-of-memory reasoning helps AI agents retrieve from tens of thousands of pages of long contexts without hallucinating.