Fixes to XML parser. Word extraction seems to work now.