With the broad and rapid adoption of Deep Neural Networks (DNNs) in various domains, an urgent need to validate their behaviour has risen, resulting in various test adequacy metrics for DNNs. One of the metrics, Surprise Adequacy (SA), aims to measure how surprising a new input is based on the similarity to the data used for training. While SA has been evaluated to be effective for image classifiers based on Convolutional Neural Networks (CNNs), it has not been studied for the Natural Language Processing (NLP) domain. This paper applies SA to NLP, in particular to three tasks: text classification, sequence labelling, and question answering task. The aim is to investigate whether SA correlates well with the correctness of the outputs. Also, SA enables prioritisation of failing inputs, thus, helps reducing the high labelling cost. An empirical evaluation shows that SA can generally work as a test adequacy metric in Natural Language Processing, especially for classification tasks.
다양한 분야에서 딥러닝이 급속도로 사용됨에 따라, 그 행동의 검증에 대한 필요성이 점차 커지고 있다. 이에 다양한 딥러닝의 테스트 적합도를 판별하는 연구들이 제시되어왔다. 그중의 하나인 놀라움 적합도 트레이닝 과정에서 사용된 데이터와의 유사도를 비교하여 새로운 입력이 얼마나 '놀라운지'를 측정한다. 놀라움 적합도가 컨볼루션 신경망 (CNN) 기반의 이미지 분류기에 효과적인 성능을 보이는 반면, 자연어 처리에 관하여 이루어진 연구는 미비하다. 본 연구는, 텍스트 분류, 시퀀스 레이블링 그리고 질의응답, 총 세 가지의 자연어 처리 작업에 놀라움 적합도를 적용하여 평가하였다. 해당 연구는 딥러닝 모델의 정확도와 놀라움 적합도가 연관되어 있음을 확인함에 목적을 두고 있다. 실험을 통해, 놀라움 적합도가 딥러닝 기반의 자연어 처리 작업의 정확도와 연관되어 있음을 검증하였다. 더불어, 본 연구의 실험결과는 실패하는 입력들을 효과적으로 선별함으로써 높은 라벨링 비용을 줄일 수 있음을 시사하였다.