The idea behind the model is that stock returns should approximate returns on treasury yields. If they do not, the theory goes that stocks are either over or undervalued. Let's illustrate with an example.
If treasury yields are 5%, but the S&P returns 10% (on an earnings basis), the theory goes that the S&P 500 is undervalued (since its returns are more attractive). Investors should thus buy the S&P 500, bidding it up until its yield becomes 5%. The opposite is also true: investors should sell if the S&P yield is low compared to treasuries, resulting in a lower S&P 500, but a higher yield.
Obviously, there are a couple of key assumptions made by this model. First of all, there is no risk premium added for owning stocks over government treasuries. The government is able to print money to pay its obligations, hence its risk is considered low. Corporations can do no such thing, therefore a higher yield should exist on the S&P 500 to pay investors for this risk.
Second, corporations can actually grow their returns, compared to the fixed payments of the treasuries. Consider a company that earns 10% on its assets. If they improve their processes or become more efficient between now and next year, perhaps they can earn more than 10% next year. It's important to note that "growth" here excludes any growth the company has experienced thanks to retained earnings, since they're only making that money because they never paid it out. An investor who is paid out can go and earn that "growth" himself by investing elsewhere.
Also note that the future payments from the treasury are known and fixed. Such is not the case with stocks. The best we can do is use analysts' forward estimates, which are prone to inaccuracies as we discuss here.
This is what the forward earnings yield for the S&P 500 and the 10-year treasury bond have looked like since 1962:
There is clearly some relationship between the yields of these two entities. However, it is clearly wrong to think you should buy the S&P 500 any time it pays a higher yield than the 10-yr, as there are many periods where bond yields have changed drastically. Consider the late 60s and early 80s for example. If you were blindly buying the S&P 500 because its yield was higher, you would have gotten burned as treasury yields soon spiked...making your returns not-so-attractive anymore.
Right now we can see S&P 500 returns are higher than the treasuries. Once again, though, be careful. If treasury yields rise, you don't want to be left holding the bag (of S&P 500 stocks).