I was fortunately able to offload the entire mess to some other poor soul, who made a much more custom solution. My draft solution was to use an xslt (or whatever it is called), basically a markup file that specifies a mapping from xml to a more sensible format, and let python parse that. That way, the tap can be generic and simply take the xslt(?) file as an config. I have absolutely no code for it though.