Your second example is actually how Doctrine 1.2+ works. You could define your models in a YAML file which was then transformed into PHP classes at runtime.
That of course, leads to the issue of having your configuration separate from your implementation/code.
That of course, leads to the issue of having your configuration separate from your implementation/code.