That is the toughest problem of them all. It is something I myself have yet to figure out. One response I can give, which perhaps is less than satisfactory is that a large amount of human knowledge does not actually depend on self-referentiality. We often know in an unconscious way, and are surprised by the connections that have developed seemingly by themselves between concepts. Of course, in order to actively learn, or create, we need that self-referentiality. One thing I have seen proposed is a series of hierarchical models, with the top model modeling oneself. This was more theoretical however, and I am not sure how to create such a model with our current algorithms.