Automated resolving of ambiguities in character classification