After-the-fact Explainer

Is our ego, the sense of self, nothing but an after-the-fact explainer? Does our mind do things of its own accord, and the ego's job is to just explain it away?