English
Related papers

Related papers: kNN-Prompt: Nearest Neighbor Zero-Shot Inference

200 papers

Large language models are strong sequence predictors, yet standard inference relies on immutable context histories. After making an error at generation step t, the model lacks an updatable memory mechanism that improves predictions for step…

Computation and Language · Computer Science 2026-01-21 Yuxing Lu , J. Ben Tamo , Weichen Zhao , Nan Sun , Yishan Zhong , Wenqi Shi , Jinzhuo Wang , May D. Wang

Large Language Models (LLMs) are popular for their impressive abilities, but the need for model-specific fine-tuning or task-specific prompt engineering can hinder their generalization. We propose UPRISE (Universal Prompt Retrieval for…

Computation and Language · Computer Science 2023-12-19 Daixuan Cheng , Shaohan Huang , Junyu Bi , Yuefeng Zhan , Jianfeng Liu , Yujing Wang , Hao Sun , Furu Wei , Denvy Deng , Qi Zhang

To achieve non-parametric NMT domain adaptation, $k$-Nearest-Neighbor Machine Translation ($k$NN-MT) constructs an external datastore to store domain-specific translation knowledge, which derives a $k$NN distribution to interpolate the…

Computation and Language · Computer Science 2024-06-11 Yan Gao , Zhiwei Cao , Zhongjian Miao , Baosong Yang , Shiyu Liu , Min Zhang , Jinsong Su

Prompt optimization improves the reasoning abilities of large language models (LLMs) without requiring parameter updates to the target model. Following heuristic-based "Think step by step" approaches, the field has evolved in two main…

Computation and Language · Computer Science 2025-07-25 Andreea Nica , Ivan Zakazov , Nicolas Mario Baldwin , Saibo Geng , Robert West

Financial sentiment analysis is critical for valuation and investment decision-making. Traditional NLP models, however, are limited by their parameter size and the scope of their training datasets, which hampers their generalization…

Computation and Language · Computer Science 2023-11-07 Boyu Zhang , Hongyang Yang , Tianyu Zhou , Ali Babar , Xiao-Yang Liu

Nonparametric learning is a fundamental concept in machine learning that aims to capture complex patterns and relationships in data without making strong assumptions about the underlying data distribution. Owing to simplicity and…

Machine Learning · Computer Science 2024-02-06 Amartya Banerjee , Christopher J. Hazard , Jacob Beel , Cade Mack , Jack Xia , Michael Resnick , Will Goddin

K-Nearest Neighbor Neural Machine Translation (kNN-MT) successfully incorporates external corpus by retrieving word-level representations at test time. Generally, kNN-MT borrows the off-the-shelf context representation in the translation…

Computation and Language · Computer Science 2023-09-20 Qiang Wang , Rongxiang Weng , Ming Chen

Many recent studies have shown the ability of large language models (LLMs) to achieve state-of-the-art performance on many NLP tasks, such as question answering, text summarization, coding, and translation. In some cases, the results…

Computation and Language · Computer Science 2024-10-11 Elnara Galimzhanova , Cristina Ioana Muntean , Franco Maria Nardini , Raffaele Perego , Guido Rocchietti

Large language models (LLMs) have demonstrated impressive success in a wide range of natural language processing (NLP) tasks due to their extensive general knowledge of the world. Recent works discovered that the performance of LLMs is…

Computation and Language · Computer Science 2024-11-25 Yuze Liu , Tingjie Liu , Tiehua Zhang , Youhua Xia , Jinze Wang , Zhishu Shen , Jiong Jin , Fei Richard Yu

Wav2Prompt is proposed which allows straightforward integration between spoken input and a text-based large language model (LLM). Wav2Prompt uses a simple training process with only the same data used to train an automatic speech…

Audio and Speech Processing · Electrical Eng. & Systems 2024-06-05 Keqi Deng , Guangzhi Sun , Philip C. Woodland

$K$-NN classifier is one of the most famous classification algorithms, whose performance is crucially dependent on the distance metric. When we consider the distance metric as a parameter of $K$-NN, learning an appropriate distance metric…

Machine Learning · Computer Science 2019-11-26 Kun Song

Consistently scaling pre-trained language models (PLMs) imposes substantial burdens on model adaptation, necessitating more efficient alternatives to conventional fine-tuning. Given the advantage of prompting in the zero-shot setting and…

Computation and Language · Computer Science 2023-06-01 Yulin Chen , Ning Ding , Xiaobin Wang , Shengding Hu , Hai-Tao Zheng , Zhiyuan Liu , Pengjun Xie

Large Language Models (LLMs) have shown significant promise in various applications, including zero-shot and few-shot learning. However, their performance can be hampered by inherent biases. Instead of traditionally sought methods that aim…

Computation and Language · Computer Science 2024-01-19 Yong Zhang , Hanzhang Li , Zhitao Li , Ning Cheng , Ming Li , Jing Xiao , Jianzong Wang

Inspired by recent advances in retrieval augmented methods in NLP~\citep{khandelwal2019generalization,khandelwal2020nearest,meng2021gnn}, in this paper, we introduce a $k$ nearest neighbor NER ($k$NN-NER) framework, which augments the…

Computation and Language · Computer Science 2022-04-01 Shuhe Wang , Xiaoya Li , Yuxian Meng , Tianwei Zhang , Rongbin Ouyang , Jiwei Li , Guoyin Wang

This paper presents a hybrid system for intuitive item similarity search that combines a Large Language Model (LLM) with a custom K-Nearest Neighbors (KNN) algorithm. Unlike black-box dense vector systems, this architecture provides…

Information Retrieval · Computer Science 2025-09-29 Ana Rodrigues , João Mata , Rui Rego

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…

Computation and Language · Computer Science 2023-06-13 Wenhao Zhu , Jingjing Xu , Shujian Huang , Lingpeng Kong , Jiajun Chen

The remarkable performance of pre-trained large language models has revolutionised various natural language processing applications. Due to huge parametersizes and extensive running costs, companies or organisations tend to transfer the…

Computation and Language · Computer Science 2023-12-15 Jiazheng Li , Runcong Zhao , Yongxin Yang , Yulan He , Lin Gui

Large language models (LLMs) exhibited powerful capability in various natural language processing tasks. This work focuses on exploring LLM performance on zero-shot information extraction, with a focus on the ChatGPT and named entity…

Computation and Language · Computer Science 2023-10-17 Tingyu Xie , Qi Li , Jian Zhang , Yan Zhang , Zuozhu Liu , Hongwei Wang

Recent works have proven the effectiveness of k-nearest-neighbor machine translation(a.k.a kNN-MT) approaches to produce remarkable improvement in cross-domain translations. However, these models suffer from heavy retrieve overhead on the…

Computation and Language · Computer Science 2025-01-07 Xiangyu Shi , Yunlong Liang , Jinan Xu , Yufeng Chen

Pretrained language models (PLMs) have shown remarkable few-shot learning capabilities when provided with properly formatted examples. However, selecting the "best" examples remains an open challenge. We propose a complexity-based prompt…

Computation and Language · Computer Science 2024-08-01 Rishabh Adiga , Lakshminarayanan Subramanian , Varun Chandrasekaran