Improved parsing of citations