(1) the purpose and character of the use, including whether such use is of a commercial nature or is for nonprofit educational purposes;
(2) the nature of the copyrighted work;
(3) the amount and substantiality of the portion used in relation to the copyrighted work as a whole; and
(4) the effect of the use upon the potential market for or value of the copyrighted work.
Naturally remembering some parts of a legally purchased book verbatim is fair use. "Memorizing" the entire library obtained via torrents and incorporating that in a commercial product that can output all that content doesn't sound like fair use to me.
Gabe is in his mid 60s, I'm prepared that in the next decade or so there will be a change of guard at Valve and the slow train of enshittification will get moving.
P.S. There's been a lot of groupthink and bandwagoning for Valve, ignoring all the dirt under the rug. But at the end of the day, by comparison, they are the best behaving in the field.