INK: Injecting kNN Knowledge in Nearest Neighbor Machine Translation
Year: 2023

Abstract:
Neural machine translation has achieved promising results on many translation tasks. However, previous studies have shown that neural models induce a non-smooth representation space, which harms its generalization results. Recently, kNN-MT has provided an effective paradigm to smooth the prediction based on neighbor representations during inference. Despite promising results, kNN-MT usually requires large inference overhead. We propose an effective training framework INK to directly smooth the representation space via adjusting representations of kNN neighbors with a small number of new parameters. The new parameters are then used to refresh the whole representation datastore to get new kNN knowledge asynchronously. This loop keeps running until convergence. Experiments on four benchmark datasets show that INK achieves average gains of 1.99 COMET and 1.0 BLEU, outperforming the state-of-the-art kNN-MT system with 0.02× memory space and 1.9× inference speedup1.

heading: 1 Introduction
text: Neural machine translation (NMT) have achieved promising results in recent years (Vaswani et al., 2017; Ng et al., 2019; Qian et al., 2021b). The target of NMT is to learn a generalized representation space to adapt to diverse scenarios. However, recent studies have shown that neural networks, such as BERT and GPT, induce non-smooth representation space, limiting the generalization abilities (Gao et al., 2018; Ethayarajh, 2019; Li et al., 2020). In NMT, we also observe a similar phenomenon in the learned representation space where low-frequency tokens disperse sparsely, even for a strong NMT model (More details are described in Section Experiments). Due to the sparsity, many
1Code will be released at https://github.com/ OwenNJU/INK
“holes” could be formed. When it is used to translate examples from an unseen domain, the performance drops sharply (Wang et al., 2022a,b)
Recently, k-Nearest-Neighbor Machine Translation (kNN-MT) (Khandelwal et al., 2021) provides an effective solution to smooth predictions by equipping an NMT model with a key-value datastore. For each entry, the value is the target token and key is the contextualized representation at the target position. It requires a training set to record tokens and representations. By aggregating nearest neighbors during inference, the NMT model can achieve decent translation results (Khandelwal et al., 2021; Zheng et al., 2021; Jiang et al., 2022). Despite the success, kNN-MT also brings new issues with the increasing scale of training data. Retrieving neighbors from a large datastore (Wang et al., 2022a) at each decoding step is time-consuming (Martins et al., 2022a; Meng et al., 2022). Furthermore, once the datastore is constructed, representations can not be easily updated, limiting the performance ceiling of kNNMT.
Given above strengths and weaknesses of kNNMT, we propose to directly smooth the representation space with a small number of parameters. In this paper, we propose a training framework INK,
15948
to iteratively refine the representation space with the help of extracted kNN knowledge (Fig. 1). Specifically, we adjust the representation distribution by aligning three kinds of representations with Kullback-Leibler (KL) divergence to train a small number of adaptation parameters. First, we align the contextualized representation and its target embedding to keep semantic meanings. Second, we align the contextualized representations of a target token and align the extracted kNN contextualized representations to address the sparsely dispersing problem. After a training epoch, we refresh the datastore asynchronously with refined models to update kNN representations. During inference, we only load the off-the-shelf NMT model and tune adaptation parameters.
We conduct experiments on four benchmark datasets. Experiment results show that our framework brings average gains of 1.99 COMET and 1.0 BLEU. Compared with the state-of-the-art kNNMT method (i.e. Robust kNN-MT; Jiang et al. 2022), INK achieves better translation performance with 0.02× memory space and 1.9× inference speed. Our contributions can be summarized below:
• We propose a training framework to smooth the representation space according to kNN knowledge.
• We devise an inject-and-refine training loop in our framework. Experiments show that refreshing the datastore asynchronously matters.
• Our INK system achieves promising improvements and beats the state-of-the-art kNN-MT system.

heading: 2 Background
text: This section briefly introduces the working process of kNN-MT and the architecture of adapter (Bapna and Firat, 2019). For the latter, we will use it to improve the representation space in our framework.
2.1 kNN-MT Given an off-the-shelf NMT model M and training set C, kNN-MT memorizes training examples explicitly with a key-value datastore D and use D to assist the NMT model during inference.
Memorize representations into datastore Specifically, we feed training example (X,Y ) in C into M in a teacher-forcing manner (Williams
and Zipser, 1989). At time step t, we record the contextualized representation2 ht as key and the corresponding target token yt as value. We then put the key-value pair into the datastore. In this way, the full datastore D can be created through a single forward pass over the training dataset C:
D = {(ht, yt) | ∀yt ∈ Y, (X,Y ) ∈ C} (1)
where each datastore entry explicitly memorizes the mapping relationship between the representation ht and its target token yt.
Translate with memorized representations During inference, the contextualized representation of the test translation context (X,Y<t) will be used to query the datastore for nearest neighbor representations and their corresponding target tokens Nk = {(ĥ, ŷ)}k1 . Then, the retrieved entries are converted to a distribution over the vocabulary:
pknn(y|X,Y<t) ∝ ∑
(ĥ,ŷ)∈Nk
1(y = ŷ)e −d(ht,ĥ) T (2)
where ht denotes h(X,Y<t) for short, d measures Euclidean distance and T is the temperature.

heading: 2.2 Adapter
text: Previous research shows that adapter can be an efficient plug-and-play module for adapting an NMT model (Bapna and Firat, 2019). In common, the adapter layer is inserted after each encoder and decoder layer of M. The architecture of the adapter layer is simple, which includes a feed-forward layer and a normalization layer. Given the output vector z ∈ Rd of a specific encoder/decoder layer, the computation result of the adapter layer can be written as:
z̃ = WT2 [W T 1 · f(z)] + z (3)
where f denotes layer-normalization, W1 ∈ Rd×d′ , W2 ∈ Rd′×d are two projection matrices. d′ is the inner dimension of these two projections. Bias term and activation function is omitted in the equation for clarity. z̃ is the output of the adapter layer.

heading: 3 Approach: INK
text: This section introduces our training framework INK. The key idea of the proposed approach is
2By default, the last decoder layer’s output is used as the contextualized representation of the translation context (X,Y<t).
to use kNN knowledge to smooth the representation space. The training process is built on a cycled loop: extracting kNN knowledge to adjust representations via a small adapter. The updated parameters are then used to refresh and refine the datastore to get new kNN knowledge. We define three kinds of alignment loss to adjust representations, which are described in Section 3.1, Section 3.2, and Section 3.3. An illustration of the proposed framework is shown in Figure 2.

heading: 3.1 Align Contextualized Representations and Token Embeddings
text: The basic way to optimize the adapter to minimize the KL divergence between the NMT system’s prediction probability pnmt and the one-hot golden distribution pgold:
Lat = DKL[ pgold(y|X,Y<t) ∥ pnmt(y|X,Y<t) ]
= − log ∑
(w,v)∈E 1(v = yt)κ(ht, w)∑ (w,v)∈E κ(ht, w)
where E is the embedding matrix. w and v denote the token embedding and its corresponding token respectively. ht denotes the contextualized representation h(X,Y<t). yt denotes the target token. κ(ht, w) = e
hTt w. Following the widely-accepted alignment-and-uniformity theory (Wang and Isola, 2020), this learning objective aligns the contextualized representation ht with the tokens embedding of its corresponding target token.
3.2 Align Contextualized Representations and kNN Token Embeddings
Previous research in kNN-MT has shown that the nearest neighbors in the representation space can produce better estimation via aggregating kNN neighbors (Khandelwal et al., 2021; Zheng et al., 2021; Yang et al., 2022). Apart from the reference target token, the retrieval results provide some other reasonable translation candidates. Taking the translation case in Figure 2 as an example, retrieval results provide three candidate words, where both “happens” and “occurs” are possible translations. Compared with the basic one-hot supervision signal, the diverse kNN knowledge in the datastore can be beneficial for building a representation space with more expressive abilities.
Therefore, we extract kNN knowledge by using the contextualized representation ht to query the datastore for nearest neighbors Nk = {(ĥ, ŷ)}k1 (illustrated in Fig. 2). For more stable training, we reformulate the computation process of kNN distribution as kernel density estimation (KDE) (Parzen, 1962).
Formulation The general idea of KDE is to estimate the probability density of a point by referring to its neighborhood, which shares the same spirit with kNN-MT. The computation of kNN distribution can be written as:
pknn(y|X,Y<t) = ∑
(ĥ,ŷ)∈Nk 1(y = ŷ)κ(ht, ĥ)∑ (ĥ,ŷ)∈Nk κ(ht, ĥ) (4)
where κ can be set as any kernel function. Thus, Equation 2 can be seen as a special case of Equation 4 by setting κ(·, ·) = e−d(·,·)/T .
After extracting kNN knowledge, we use it to smooth the representation space by by minimizing the KL divergence between the kNN distribution pknn and NMT distribution pnmt:
Lit = DKL[ pknn(y|X,Y<t) ∥ pnmt(y|X,Y<t) ]
= − ∑
ȳ∈Y pknn(ȳ) · log ∑ (w,v)∈E 1(v = ȳ)κ(ht, w)∑ (w,v)∈E κ(ht, w) · pknn(ȳ)
where Y denotes identical tokens in nearest neighbors Nk and pknn(ȳ) denotes pknn(y = ȳ|X,Y<t) for short. E is the embedding matrix. w and v denote the token embedding and its corresponding token respectively. ht denotes h(X,Y<t) for short. κ is the kernel function. Following the widely-accepted alignment-and-uniformity theory (Wang and Isola, 2020), this learning objective encourages ht to align with the embeddings of retrieved reasonable tokens, e.g., “occurs”, “happens”.

heading: 3.3 Align Contextualized Representations of the Same Target Token
text: Although kNN knowledge could provide fruitful translation knowledge, it is also sometimes noisy (Zheng et al., 2021; Jiang et al., 2022). For example, in Figure 2, the retrieved word “works” is a wrong translation here.
To address this problem, we propose to adjust local representation distribution. Specifically, our solution is to optimize the kNN distribution towards the reference distribution by minimizing the KL divergence between the gold distribution pgold and kNN distribution pknn. Thanks to the new formulation (Eq. 4), we can choose kernel function here to achieve better stability for gradient optimization. In the end, we find that exponential-cosine kernel works stably in our framework:
κ(h, ht) = e cos(h,ht) (5)
Therefore, the loss function can be written as:
Lrt = DKL[ pgold(y|X,Y<t) ∥ pknn(y|X,Y<t) ]
= − log ∑
(ĥ,ŷ)∈Nk 1(ŷ = yt)κ(ht, ĥ)∑ (ĥ,ŷ)∈Nk κ(ht, ĥ)
where Nk is the retrieved k nearest neighbors. ĥ and ŷ denotes the neighbor representations and the corresponding target token. ht denotes h(X,Y<t) for short. Following the widelyaccepted alignment-and-uniformity theory (Wang
and Isola, 2020), this learning objective aligns the contextualized representation of the same target token. With this goal, we can make the kNN knowledge less noisy in the next training loop by refreshing the datastore with the updated representations.

heading: 3.4 Overall Training Procedure
text: The combined learning objective To summarize, we adjust representation space via a small adapter with the combination of three alignment loss Lat , Lit, Lrt . Given one batch of training examples B = {(X,Y )}, the learning objective is minimizing the following loss:
L = 1|B| ∑
(X,Y )∈B
∑
t
(Lat + αLit + βLrt ) (6)
where α, β is the interpolation weight. We notice that, in general, all three learning objective pull together closely related vectors and push apart less related vectors in the representation space, which has an interesting connection to contrastive learning (Lee et al., 2021; An et al., 2022) by sharing the similar goal.
Refresh datastore asynchronously In our training loop, once the parameters are updated, we refresh the datastore with the refined representation. In practice, due to the computation cost, we refresh the datastore asynchronously at the end of each training epoch to strike a balance between efficiency and effectiveness As the training reaches convergence, we drop the datastore and only use the optimized adapter to help the off-the-shelf NMT model for the target domain translation.

heading: 4 Experiments

heading: 4.1 Setting
text: We introduce the general experiment setting in this section. For fair comparison, we adopt the same setting as previous research of kNN-MT (Khandelwal et al., 2021; Zheng et al., 2021; Jiang et al., 2022), e.g., using the same benchmark datasets and NMT model. For training INK, we tune the weight α and β among {0.1, 0.2, 0.3}. More implementation details are reported in the appendix.
Target Domain Data We use four benchmark German-English dataset (Medical, Law, IT, Koran) (Tiedemann, 2012) and directly use the preprocessed data3 released by Zheng et al. (2021). Statistics of four datasets are listed in Table 1.
3https://github.com/zhengxxn/adaptive-knn-mt
Dataset # Train # Dev # Test
NMT Model We choose the winner model4 (Ng et al., 2019) of WMT’19 German-English news translation task as the off-the-shelf NMT model for translation and datastore construction, which is based on the big Transformer architecture (Vaswani et al., 2017).
Baselines For comparison, we consider three kNN-MT systems, which use datastore in different fashions. We report the translation performance of the adapter baseline to show the effectiveness of our training framework. Besides, we report the translation performance of kNN-KD, which is another work using kNN knowledge to help NMT.
• V-kNN (Khandelwal et al., 2021), the vanilla version of k-nearest-neighbor machine translation.
• A-kNN (Zheng et al., 2021), an advanced variants of kNN-MT, which dynamically decides the usage of retrieval results and achieve more stable performance.
• R-kNN (Jiang et al., 2022), the state-of-theart kNN-MT variant, which dynamically calibrates kNN distribution and control more hyperparameters, e.g. temperature, interpolation weight.
• Adapter (Bapna and Firat, 2019), adjusting representation by simply align contextualized representation and token embeddings.
• kNN-KD (Yang et al., 2022), aiming at fromscratch train a NMT model by distilling kNN knowledge into it.
Metric To evaluate translation performance, we use the following two metrics:
• BLEU (Papineni et al., 2002), the standard evaluation metric for machine translation. We report case-sensitive detokenized sacrebleu5.
4https://github.com/facebookresearch/fairseq/ tree/main/examples/wmt19
5https://github.com/mjpost/sacrebleu
• COMET (Rei et al., 2020), a recently proposed metric, which has stronger correlation with human judgement. We report COMET score computed by publicly available wmt20comet-da6 model.
Approximate Nearest Neighbor Search We follow previous kNN-MT studies and use Faiss7 index (Johnson et al., 2019) to represent the datastore and accelerate nearest neighbors search. Basically, the key file can be removed to save memory space once the index is built. But, it is an exception that R-kNN relies on the key file to re-compute accurate distance between query representation and retrieved representations.

heading: 4.2 Main Results
text: We conduct experiments to explore the following questions to better understand the effectiveness of our proposed framework and relationship between two ways of smoothing predictions:
• RQ1: Can we smooth the representation space via small adapter and drop datastore aside during inference?
• RQ2: How much improvement can be brought by using kNN knowledge to adjust the representation distribution?
• RQ3: Will together using adapter and datastore bring further improvement?
INK system achieves the best performance by smoothing the representation space Table 2 presents the comparison results of different systems. Due to the poor quality of representation space, the off-the-shelf NMT model does not perform well. The performance of kNN-KD is unstable, e.g., it performs poorly on IT dataset. kNNMT systems generate more accurate translation. Among them, R-kNN achieves the best performance, which is consistent with previous observation (Jiang et al., 2022). Our INK system achieves the best translation performance with the least memory space. Compared with the strongest kNNMT system, i.e. R-kNN, INK achieves better performance on three out of four domains (Medical, IT, Koran). In average, INK outperforms R-kNN with an improvement of 4.84 COMET and 0.31 BLEU while occupying 0.02× memory space.
6https://github.com/Unbabel/COMET 7https://github.com/facebookresearch/faiss
Representation refinement according to kNN knowledge brings large performance improvement In Table 2, compared with the adapter baseline that simply align the contextualized representations and word embeddings, INK outperforms it by 1.99 COMET and 1.00 BLEU in average, which demonstrates the effectiveness of adjusting representation distribution with kNN knowledge. To better show the effect of INK framework, we use adapters of different sizes to refine the representation space. Figure 3 shows the BLEU scores and added memory of different systems on four datasets. We can see that representation-refined system occupies much less memory than the datastoreenhanced system. In general, INK systems locates on the top-right of each figure, which means that INK achieves higher BLEU scores with less memory space. In most cases, INK outperforms adapter with a large margin, which demonstrates the superiority of our training framework. Jointly applying adapter and datastore can further smooth predictions Given the fact that both INK and datastore can smooth predictions, we take a step further and explore to use them together as a hybrid approach. Specifically, on top of our INK system, we follow the fashion of R-kNN to use an additional datastore to assist it during inference. Experiment results are shown in Figure 4. On three out of four datasets, we can observe further improvements over INK. On the Law dataset,
the performance improvement even reaches 4.19 BLEU. On the Medical and IT dataset, the performance improvement is 0.71 BLEU and 0.79 BLEU respectively. Such phenomenon indicates that the representation space of the NMT model is not fully refined by the adapter. If a more effective framework can be designed, the benefit of smoothing representation space will be further revealed. The results on the Koran dataset is an exception here. We suggest that it is because of the sparse training data, which makes it difficult to accurately estimate kNN distribution during inference.

heading: 5 Analysis and Discussion
text: We conduce more analysis in this section to better understand our INK system.
INK greatly refines the representation space of the NMT model Inspired by Li et al. (2022), we evaluate the quality of the representation space by
computing mean kNN accuracy, which measures the ratio of k-nearest representations sharing the same target token with the query representation. Ideally, all of the representations in a neighborhood should share the same target token. Here, we use the contextualized representations from the unseen development set as the query. For each query, the nearest representations from the training set will be checked. Table 3 shows the evaluation results on medical dataset. INK achieves higher accuracy than the NMT model consistently. For low frequency tokens, the representation quality gap is especially large.
Ablation study To show the necessity of different proposed techniques in our INK framework, we conduct ablation study in this section. In Table 4, we can see that keeping the datastore frozen degenerates the translation performance most, which demonstrates the necessity of refreshing datastore asynchronously during training. Removing either of the two alignment loss (Lit and Lrt ) would cause the translation performance to decline, which validates their importance for adjusting the representation distribution.
INK enjoys faster inference speed After refining the representation space, our adapted system no longer need to querying datastore during inference. We compare the inference speed 8 of INK and RkNN. Considering that decoding with large batch size is a more practical setting (Helcl et al., 2022), we evaluate their inference speed with increasing batch sizes. To make our evaluation results more reliable, we repeat each experiment three times and report averaged inference speed. Table 5 shows the results. As the decoding batch size grows, the speed gap between the two adapted system becomes larger. Our INK can achieve up to 1.9× speedup. Besides, due to the fact that neural parameters allows highly parallelizable computation, the inference speed of INK may be further accelerated in the future with the support of non-autoregressive decoding (Qian et al., 2021a; Bao et al., 2022).

heading: 6 Related Work
text: Nearest Neighbor Machine Translation kNNMT presents a novel paradigm for enhancing the NMT system with a symbolic datastore. However, kNN-MT has two major flaws: (1) querying the datastore at each decoding step is time consuming and the datastore occupies large space. (2) the noise representation in the datastore can not be easily updated, which causes the retrieval results to include noise.
Recently, a line of work focuses on optimizing system efficiency. Martins et al. (2022a) and Wang et al. (2022a) propose to prune datastore entries and conduct dimension reduction to compress the datastore. Meng et al. (2022) propose to in-advance narrow down the search space with word-alignment to accelerate retrieval speed. Martins et al. (2022b) propose to retrieve a chunk of tokens at a time and conduct retrieval only at a few decoding steps with a heuristic rule. However, according to their em-
8We evaluate the inference speed on a single NVIDIA Titan-RTX.
pirical results, the translation performance always declines after efficiency optimization.
To exclude noise in the retrieval results, Zheng et al. (2021) propose to dynamically decide the usage of retrieved nearest neighbors with a meta-k network. Jiang et al. (2022) propose to dynamically calibrate the kNN distribution and control more hyperparameters in kNN-MT. Li et al. (2022) propose to build datastore with more powerful pre-trained models, e.g. XLM-R (Conneau et al., 2020). However, all of this methods rely on a full datastore during inference. When the training data becomes larger, the inference efficiency of these approaches will becomes worse. Overall, it remains an open challenge to deploy a high-quality and efficient kNN-MT system.
Using kNN knowledge to build better NMT models As datastore stores a pile of helpful translation knowledge, recent research starts exploring to use kNN knowledge in the datastore to build a better NMT model. As an initial attempt, Yang et al. (2022) try to from scratch train a better NMT model by distilling kNN knowledge into it. Different from their work, we focus on smoothing the representation space of an off-the-shelf NMT model and enhancing its generalization ability via a small adapter. Besides, in our devised injectand-refine training loop we keep datastore being asynchronously updated, while they use a fixed datastore.

heading: 7 Conclusion
text: In this paper, we propose a novel training framework INK, to iteratively refine the representation space of the NMT model according to kNN knowledge. In our framework, we devise a inject-andrefine training loop, where we adjust the representation distribution by aligning three kinds of representation and refresh the datastore asynchronously with the refined representations to update kNN knowledge. Experiment results on four benchmark dataset shows that INK system achieves an average gain of 1.99 COMET and 1.0 BLEU. Compared with the state-of-the-art kNN system (Robust kNN-MT), our INK also achieves better translation performance with 0.02× memory space and 1.9× inference speed up.

heading: 8 Limitation
text: Despite promising results, we also observe that refreshing and querying the datastore during training
is time-consuming. Our proposed training framework usually takes 3× ∼ 4× training time. In future work, we will explore methods to improve training efficiency. We include a training loop to dynamically use the latest datastore to inject knowledge into neural networks. However, we still find that the kNN knowledge still helps the inference even after our training loops, demonstrating that there still remains space to improve the effectiveness of knowledge injection.

heading: Acknowledgement
text: We would like to thank the anonymous reviewers for their insightful comments. Shujian Huang is the corresponding author. This work is supported by National Science Foundation of China (No. 62176120), the Liaoning Provincial Research Foundation for Basic Research (No. 2022-KF-2602).

heading: A Used Scientific Artifacts
text: Below lists scientific artifacts that are used in our work. For the sake of ethic, our use of these artifacts is consistent with their intended use.
• Fairseq (MIT-license), a sequence modeling toolkit that allows researchers and developers to train custom models for translation, summarization and other text generation tasks.
• Faiss (MIT-license), a library for approximate nearest neighbor search.
B Implementation Details
We reproduce baseline systems with their released code. We implement our system with fairseq (Ott et al., 2019). Adam is used as the optimizer and inverse sqrt is used as the learning rate scheduler. We set 4k warm-up steps and a maximum learning rate as 5e-4. We set batch size as 4096 tokens. All INK systems are trained on a single Tesla A100. During inference, we set beam size as 4 and length penalty as 0.6.
ACL 2023 Responsible NLP Checklist

heading: A For every submission:
text: 3 A1. Did you describe the limitations of your work?
section 8
A2. Did you discuss any potential risks of your work? Not applicable. Left blank.
3 A3. Do the abstract and introduction summarize the paper’s main claims? section 1
7 A4. Have you used AI writing assistants when working on this paper? Left blank.
B 3 Did you use or create scientific artifacts? section 4
3 B1. Did you cite the creators of artifacts you used? section 4
3 B2. Did you discuss the license or terms for use and / or distribution of any artifacts? appendix a
3 B3. Did you discuss if your use of existing artifact(s) was consistent with their intended use, provided that it was specified? For the artifacts you create, do you specify intended use and whether that is compatible with the original access conditions (in particular, derivatives of data accessed for research purposes should not be used outside of research contexts)? appendix a
B4. Did you discuss the steps taken to check whether the data that was collected / used contains any information that names or uniquely identifies individual people or offensive content, and the steps taken to protect / anonymize it? Not applicable. Left blank.
B5. Did you provide documentation of the artifacts, e.g., coverage of domains, languages, and linguistic phenomena, demographic groups represented, etc.? Not applicable. Left blank.
3 B6. Did you report relevant statistics like the number of examples, details of train / test / dev splits, etc. for the data that you used / created? Even for commonly-used benchmark datasets, include the number of examples in train / validation / test splits, as these provide necessary context for a reader to understand experimental results. For example, small differences in accuracy on large test sets may be significant, while on small test sets they may not be. section 4
C 3 Did you run computational experiments? section 4, 5
3 C1. Did you report the number of parameters in the models used, the total computational budget (e.g., GPU hours), and computing infrastructure used? section 4, 5
The Responsible NLP Checklist used at ACL 2023 is adopted from NAACL 2022, with the addition of a question on AI writing assistance.
3 C2. Did you discuss the experimental setup, including hyperparameter search and best-found hyperparameter values? section 4
3 C3. Did you report descriptive statistics about your results (e.g., error bars around results, summary statistics from sets of experiments), and is it transparent whether you are reporting the max, mean, etc. or just a single run? section 4
C4. If you used existing packages (e.g., for preprocessing, for normalization, or for evaluation), did you report the implementation, model, and parameter settings used (e.g., NLTK, Spacy, ROUGE, etc.)? Not applicable. Left blank.
D 7 Did you use human annotators (e.g., crowdworkers) or research with human participants? Left blank.
D1. Did you report the full text of instructions given to participants, including e.g., screenshots, disclaimers of any risks to participants or annotators, etc.? No response.
D2. Did you report information about how you recruited (e.g., crowdsourcing platform, students) and paid participants, and discuss if such payment is adequate given the participants’ demographic (e.g., country of residence)? No response.
D3. Did you discuss whether and how consent was obtained from people whose data you’re using/curating? For example, if you collected data via crowdsourcing, did your instructions to crowdworkers explain how the data would be used? No response.
D4. Was the data collection protocol approved (or determined exempt) by an ethics review board? No response.
D5. Did you report the basic demographic and geographic characteristics of the annotator population that is the source of the data? No response.

heading: Future Work
text: In future work, we will explore methods to improve training efficiency. We include a training loop to dynamically use the latest datastore to inject knowledge into neural networks. However, we still find that the kNN knowledge still helps the inference even after our training loops, demonstrating that there still remains space to improve the effectiveness of knowledge injection