ABOUT ME

-

Today
-
Yesterday
-
Total
-
  • [NLP] FINE: Future-aware Inference For Streaming Speech Translation
    ✨ AI/AI papers 2023. 4. 18. 16:19

    FINE: FUTURE-AWARE INFERENCE FOR STREAMING SPEECH TRANSLATION [ICLR 2023]

     

    link : https://openreview.net/pdf?id=0VhwJYrZew 

     

     

    Abstract

    Streaming speech translation 문제를 다룰 때, 여러 latency requirement를 위해 multiple online model을 training하는 것보다, single offline translation model에 wait-k policy를 적용하는 것은 간단한 대안이 될 수 있다. 하지만, 이는 complete utterance를 가지고 training된 모델로 partial streaming speech inference를 하는 것은 분명한 mismatch 문제가 있다. 해당 논문에서는 완벽한 문장의 representation이 있을 때, 중간 부분의 representation과 partial utterance representation이 상당한 차이가 있음을 보인다. 그래서 Future-aware inference(FINE)라는 모델을 제안하고, future speech signal의 적은 frame을 도입하는 것으로 모델이 future을 인식하게 하여 해당 문제를 줄일 수 있다고 주장한다. 첫번째 방법은 "FINE-mask"로, 훈련가능한 masked speech model을 통해 future context를 합치는 것이고, 두번째 방법은 "FINE-wait"로 추가적인 latency cost를 감안하고 더 많은 actual future audio frame을 기다리는 것이다. 

     

     

    Introduction

    직관적으로 streaming input에서 추출된 speech representation은 full input보다 less informative한데, 그렇다면 2가지 질문이 생긴다.

    1. 둘 사이 representation은 inferenc시, 얼마나 다른가?
    2. 이는 문제를 일으키기에 충분히 다른가?

     

    저자들은 두 speech representation 차이를 cosine similarity로 측정했을 때 상당히 큰 차이로 다르다는 것을 확인했다.

    이를 근거해 저자들은 streaming input의 끝 지점에서의 부족한 future context는 streaming speech translation에 손상을 가한다고 가설을 세우고 "Future-aware inference(FINE)"이라는 strategies를 제안한다. 

    Figure 1 (c)의 "FINE-mask"는 현재 streaming speech tokens 끝에 추가적인 input으로 mask embedding을 추가하는 방법이다. 이는 masked modeling에서, 모델이 hidden representation을 따르는 미래 context 를 estimate할 수 있는 능력과, streaming input에서 정확한 representation을 추출할 수 있는 능력을 기반으로 한다. 저자들은 오직 마지막 몇 개의 포지션의 streaming input의 representation이 심각하게 mismatch problem에 영향을 주는 것을 발견했으므로, 가장 가까운 미래 context는 model을 향상시킬 수 있을 것으로 보았다.

    Figure 1 (c)의 "FINE-wait"는 단순하게 latency가 커짐을 감안하면서 input을 좀 더 기다리는 방법이지만, oracle future context를 기다림으로써 상당한 translation quality 개선이 있었다고 한다.

     

     

    Background

    Non-Streaming Speech Translation

     

    Streaming Speech Translation

    Non-Streaming과 달리 Streaming은 input x가 partial이다. 그 외에는 같다. streaming ST는 따라서 현재까지 input을 보고 디코딩을 할지 더 많은 context를 위해 input을 기다릴지 결정하는 policy가 필요하다. 가장 쉽고 직관적이고 많이 사용되는 Policy는 K개를 기다렸다가 Read/Write를 반복하는 Wait-k가 있고 Wait-k variants policy도 많이 제안되었다. 그리고, word boundary를 추출하는 방법들도 많이 시도되었는데, CTC를 이용해서 word boundary의 k를 기다리는 방법 등 CTC를 이용하는 방법들도 많이 사용되었다. 또 input의 정보가 충분한지 판단할 수 있는 integrate-and-fire이라는 방법도 최근 제안되었다. 그리고 k를 기다리는 방법 말고 dynamically한 read-write 결정을 할 수 있는 adaptive policy들도 있고, knowledge distillation과 prefix-to-prefix framework를 사용해 미래 정보를 채우는 식의 방법들도 제안되었다.

    해당 논문에서는 어떻게 offline training과 online inference mismatch 문제를 줄일 수 있느냐에 초점을 맞췄다.

     

     

    Preliminary Analysis

    이 섹션에서는 Transformer-based ST architecture에서 offline 과 online decoding의 mismatch에 대해 논의한다. full-sentence ST에서는, 각 frame의 speech representation은 transformer encoder layer에서 multi-head attention에 의해 모든 unmasked frame을 attending한다. 그러나 streaming inference에서 offline model은 오직 이전 frame들만 attend하기 때문에 현재 마지막 프레임들은 좋지 않은 representation을 갖게 된다.

     

    Which part of streaming speech representation is worse?

    full sentence와 partial sentence가 있을 때 같은 position에서의 representation의 cosine similarity를 쟀다.

    시작부분, 중간부분, 끝부분 consine similarity를 쟀을 때, 시작과 중간 부분은 cosine similarity가 0.8이상으로 꽤비슷했지만 가장 끝 부분이 아닌 끝 지점에서의 consine similarity는 꽤 차이가 나는 것을 figure2를 통해 볼 수 있다. 따라서 저자들은 끝 부분의 streaming speech representation은 특히나 inferior하다고 결론을 내렸다. 그리고 마지막 10 position의 representation이 low-quality를 결정지으며 이는 무시할 수 없는 수준이었다.

     

    Does the poor representation at the last positions of streaming speech affec streaming ST performance?

    위 질문에 대답하기 위해 평균 consine similarity와 quailty를 비교했을 때 representation이 낮은 구간일 수록 translation quality가 안 좋아짐을 확인할 수 있었다.

     

     

    FINE: Future-Aware Inference

    이러한 분석을 기반으로, streaming encoding 동안 짧은 미래를 인식할 수 있는 offline ST model은 필수적이라는 것을 발견했다. 그래서 FINE-mask와 FINE-wait라는 방법을 제안하고 이는 streaming speech의 representation을 강화할 수 있음을 보인다.

     

    FINE-Mask

    Wave2Vec의 mask token을 pseudo future context로써 이미 사용된 speech frame으로부터 생성된 speech token에 붙인다. mask token embedding은 Wav2vec pretrainig에서 training된다. 이는 Wav2Vec의 훈련 방식이 unmasked context로부터 만들어진 latent feature를 따르도록 reconstruct되는 것에 기반한다. 

    Wav2VEc은 multi-layer convolutional subsample f_c와 Transformer encoder f_e로 구성되어 있다. streaming speech token c와 m mask token embedding e를 concat한다. 그리고 new speech token은 transformer encoder로 fed되지만, 오직 첫 tau encoder output이 decoder를 위해 유지된다. 앞 섹션에서 얘기했듯 마지막 m speech feature가 poor quality에 영향을 주기 때문이다.

     

    FINE-Wait

    FINE-wait는 이전 섹션에서 마지막 m 토큰들이 poor representation을 가진다는 분석에 근거하여 가장 간단하게 수정할 수 있는 방법이다. 간단하게 끝 부분의 poor representation을 취소한다.

     

     

    Experiments

    실험은 MuST-C EnDe, EnES dataset으로 진행했으며 testset은 tst-COMMON set이다. offline model은 LibriSpeech corpus로 training된 Wav2vec을 acoustic encoder로 사용한 MoSST이다. 비교 Baseline model은 SimulSpeech, Real TranS, MoSST이다. FINE-Hybrid는 tau length의 streaming speech가 주어졌을 때, 처음 m extra oracle speech token을 기다리고, m' mask token을 streaming speech 끝에 붙인다. 그러면 총 길이는 tau+m+m'이 되는데 FINE-Mask와 WAIT처럼 처음 tau encoder output 만 디코딩시 유지된다. 여기서 m은 10 m'은 50을 사용했다.

     

    Ablation Study

    얼만큼의 Future context가 필요한지에 대한 Ablation study를 진행했을 때 future context가 클 수록 더 나은 quality를 보여줬다. 

     

    Conclusion

    Offline-training과 online-decoding에 대한 mismatch 문제에 대해 끝 지점의 representation이 성능에 안 좋은 영향을 미친다는 점을 분석한 뒤, 이에 대한 해결 방안으로 FINE이라는 방법을 제안하였다. FINE-Mask는 미래 context를 예측하고 FINE-Wait는 실제 미래 context를 기다리는 방법이었다. 특히 제안하는 방법은 Wav2Vec 어쿠스틱 인코더를 사용했을 때 쉽고 효과적으로 적용할 수 있었다.

    댓글

Designed by Tistory.