We found a software bug that has been reported to DJI that makes it so the X5S does not maintain a yaw value of zero when pointing the gimbal with the exact same control code that all other aircraft use. They will likely fix it in a future release.
Are you absolutely sure that it was straight at takeoff? Before takeoff or after? It will be pointed straight forward before takeoff but as it is taking off and points the gimbal down it rotates severely.
The workaround for this is to have C1 programmed to center the yaw. Pressing that button after takeoff will bring it back to center.
As with the release of the X5 there is a lot of weirdness with their top of the line cameras when first released. This is especially so when it comes to SDK support.
The currently released version of Map Pilot (v2.4.2) does not explicitly support the Inspire 2 but a new version of the app has been submitted that does and no changes were made in this respect since it is likely a firmware issue with DJI.