We Realize who and what we really are, and come to behave like That.
Ignorance of That and associated bad habits result in mistakes and consequential suffering.
The accumulation of experience eventually brings us to realize that we are not separate from others, which forms habitual devotion to the ultimate welfare of all.