The Role of Global and Local Context in Named Entity Recognition