Some doc fixes and made StateEntity non exported