What kind of script do you use for that? By the way, if your target is biblatex you could use buyer's toolmode to do the transformation...