A correct equation can still encode the wrong rotation

Conventions are part of the API.

Quaternion multiplication order, active versus passive interpretation, frame direction, and Euler sequence cannot be left to caller intuition. Downstream estimation and control code must consume the same contract.

ContractWhat callers must establishFailure if ambiguous
Quaternion layoutScalar-first [w,x,y,z] wherever the public API declares quaternion arraysValid-looking but incorrect rotations
CompositionCurrent-to-target correction and multiplication direction are named at the call siteController commands rotate away from the target
Euler orderThe supported intrinsic/extrinsic sequence is explicitDifferent orientation from identical angles
DCM validityOrthonormality, determinant, finite values, and reflection rejection are checkedMalformed matrices silently become orientation state
UnitsAngles use radians inside numerical APIs unless explicitly convertedScale errors survive compilation

The exact accepted contract is enforced by checked functions and fixtures. Documentation describes that contract; tests decide whether an implementation still satisfies it.