Google released their AJAX UI framework, GWT, two days ago, following a similar move from Yahoo some months ago.
I haven't really looked at it in depth, yet, as I did with Yahoo's YUI, but I find myself asking the same question: Why?
It's nice and all, but who benefits? I mean, sure there's some goodwill effect - but is that the reason? Maybe - but that's likely only the tip.
Dave Besbris suggests its because of an anticipated "Platform Effect" - that developers will consume the tools, visit their forums, go to their developer website, participate in their eco-systems, and that will be good. But additionally, having used YUI or GWT, it'll be really trivial for them to embed the Yahoo Chat tool, or the Google message board system: they'll be emotionally and technically commited already, having written/included most of the code to consume more advanced services.
Its a tactic that, in the past, Microsoft has used to devastating effect. Lately, we've even seen the value of it from endeavors like YouTube. They'll give you the HTML code to play their hosted video on your own site - and that drives more video ON their site, as well as traffic and eyeballs back.