This Ruby gem provides a Hash#to_uddf method which will return a UDDF encoded XML data object.