1. The knowledge is worthwhile to a small group (often just one) of investors, who fund it. The memorable phrase for this is "the exploitation of the large by the small." (A practical example of this is OPEC and high oil prices. The complicated negotiations OPEC engages in illustrate the desire of members of the group to contribute as little as possible to provisioning the public good.)
2. An organization exists that investors belong to for some other reason which funds the ratings. (A practical example of this how people belong to AAA for membership benefits, but then AAA lobbies for road improvements.)
3. A coercive organization intervenes and forces the matter. (Virtually all government regulations fall into this category.)
4. The public good is not provisioned. (What happened to investors who wanted trustworthy ratings.)
Read The Logic of Collective Action for the classic introduction to this topic.
I'm not sure how this applies to an investor funded rating agency. I don't know that there is any strategic advantage to large firms having accurate bond ratings publicly available, but it would be interesting to hear business models where there would be.
Normally there are transaction barriers that inhibit cooperation in providing public goods. However software has far fewer of those barriers. And so you get a situation where a network of loosely connected people each pursuing individual goals can collectively provision a public good.
I remember running across a footnote in The Logic of Collective Action saying that this was a theoretical possibility, but no example was known of it. (The book was written back in the 1960s.) In any case it is an extremely unusual example.