Morningstar Quantitative Ratings for Stocks are generated using an algorithm that compares companies that are not under analyst coverage to peer companies that do receive analyst-driven ratings.
If you thought grep was powerful, wait until you get a hold of ast-grep, which takes it to a whole new level.