AI OnAI Off
No, the specific type in the attribute definition is necessary to be able to load the object again.
What happens when you add complex types (IEntity classes) as attribute values is that only a reference to the entity ID is stored. This ID together with the type from the attribute definitoin is used later to load the object.
You could however, for instance, add a string attribute and an int attribute and then store a string representation of the type as well as the ID of the entity as separate attributes and then use the EntityProvider system to load the actual entity.
Eg EPiServer.Common.Data.EntityProviderHandler.GetEntityProvider(theType).GetEntityInstance(theType, theId)
Is it possible to add an attribute which can hold a reference to any type of framework entity? Or is there some other neat way to connect any content to any other content? What I want to accomplish is the possibility to create a new blog post, forum post, instant message or anything else and attach an other entity to say "Hey, look at this image/video/blog/whatever".