Restricting yourself to perfect opponents is very silly firstly, because there are no perfect opponents because chess is unsolved. So right out of the gate our definition assumes the counterfactual for all chess games every played and is both inaccurate (does not describe actual chess) and impractical (cannot be implemented)
Secondly, if there were such an opponent (which is not at all clear there ever will be), there is no way within the rules of chess to detect whether or not we face it in a given game. Imperfect opponents are allowed to play chess, and assuming they are all perfect while a defensible strategy is merely one of several.
Thirdly, it leads to very counterintuitive results. Consider the case in which chess is solved and well-balanced (e.g. a perfect opponent P can force a draw). We modify P to create opponent NP. NP behaves as follows: if NP's opponent is consistent with P, NP will implement P (e.g. force a draw), if NP's opponent deviates from P, NP will lose (forefeit or make bad moves). Therefore everyone can beat NP except "optimal" algorithm P, which can only force a draw. So now we have an "optimal" algorithm with a 0 tournament rating.
In reality the whole "perfect opponent" thing is mostly a notational convenience for Zermelo's Theorem. Which is very interesting and useful if you are writing a proof, less interesting if you are trying to win a chess tournament. A more practical definition of "optimal" is something like "wins a lot of games".