Generations from large language models often fail to conform to desired constraints such as JSON schema. Existing locally constrained decoding (LCD) approaches enforce constraints by myopically masking out next tokens, resulting in biased sampling and degradation in performance. Recent work uses sequential Monte Carlo (SMC) methods to mitigate such biases, but designing effective proposal distributions or potential functions remains a key challenge. In this work, we propose a generic approach to construct proposals and potentials for SMC sampling from $p_{\mathrm{lm}}( \cdot \mid \mathrm{constraint})$. First, we show that constraints specified as finite automata can be tensorized for efficient execution on GPUs, which we use to construct globally constrained decoding (GCD) proposals. In addition, leveraging the fact that tensorized finite automata share the same circuit structure as hidden Markov models, we circuit-multiply them to obtain the probabilistic GCD (P-GCD) proposals encoding both logical and probabilistic information about the target distributions. We evaluate (P-)GCD on the tasks of function calling, keyword-based generation, and SQL generation. Experiments show that under the same SMC sampling setup, compared to LCD proposals, (P-)GCD converges faster to the target distribution with significantly fewer particles.
Mitigating Posterior Salience Attenuation in Long-Context LLMs with Positional Contrastive Decoding
Zhejiang University(浙江大学);University of Science and Technology of China(中国科学技术大学);Bytedance(字节跳动);Zhejiang Lab(浙江省实验室);Zhejiang Key Laboratory of Medical Imaging Artificial Intelligence(浙江省医学影像人工智能重点实验室)
Mitigating Hallucinations of Large Language Models in Medical Information Extraction via Contrastive Decoding
University of Science and Technology of China(中国科学技术大学);Jarvis Research Center, Tencent YouTu Lab(腾讯优图实验室贾维斯研究中心);Peking University(北京大学);Westlake University(西湖大学);City University of Hong Kong(香港城市大学)
Please refuse to answer me! Mitigating Over-Refusal in Large Language Models via Adaptive Contrastive Decoding
School of Cyber Science and Technology, Shenzhen Campus of Sun Yat-sen University(中山大学信息科学与技术学院深圳校区);School of Information, Central University of Finance and Economics(中央财经大学信息学院);School of Artificial Intelligence, Beijing Normal University(北京师范大学人工智能学院);School of Computing Technologies, RMIT University(皇家墨尔本理工大学计算技术学院)
Exploring and Mitigating Fawning Hallucinations in Large Language Models
School of Medical Technology, Beijing Institute of Technology(北京理工大学医学技术学院);Artificial Intelligence Research Institute, Shenzhen MSU-BIT University(深圳MSU-BIT大学人工智能研究院);Tianjin University(天津大学);The Hong Kong University of Science(香港科学大学)
Mitigating Object Hallucination via Robust Local Perception Search
Shanghai Artificial Intelligence Laboratory(上海人工智能实验室);Center for Future Media & School of Computer Science and Engineering, University of Electronic Science and Technology of China(未来媒体中心及电子科技大学计算机科学与工程学院)
Con-ReCall: Detecting Pre-training Data in LLMs via Contrastive Decoding
National University of Singapore(新加坡国立大学);University of California, Merced(加州大学默塞德分校);University of California, Los Angeles(加州大学洛杉矶分校);University of Queensland(昆士兰大学)
FlexDraft: Flexible Speculative Decoding via Attention Tuning and Bonus-Guided Calibration
EPIC Lab, SJTU(上海交通大学EPIC实验室);UESTC;School of Software Engineering, HUST(华中科技大学软件工程学院);Tsinghua University(清华大学);HKUST(GZ)(香港科技大学(广州));Shanghai AI Laboratory(上海人工智能实验室)
Focus on Your Question! Interpreting and Mitigating Toxic CoT Problems in Commonsense Reasoning
School of Artificial Intelligence, University of Chinese Academy of Sciences(中国科学院大学人工智能学院);Institute of Automation, Chinese Academy of Sciences(中国科学院自动化研究所);Hunan Normal University(湖南师范大学)
Mitigating Video Hallucinations via Attention-Guided Representation Perturbation
School of Computer Science and Engineering, Beihang University(北京航空航天大学计算机科学与工程学院);Beijing Institute for General Artificial Intelligence, BIGAI(北京通用人工智能研究院);Sino-French Engineer School, Beihang University(北京航空航天大学中法工程师学院)
Why Diffusion Language Models Struggle with Truly Parallel (Non-Autoregressive) Decoding?
The Hong Kong Polytechnic University, Hong Kong, China(香港理工大学);ELLIS Institute Tübingen, Tübingen, Germany(图宾根ELLIS研究所);Max Planck Institute for Intelligent Systems, Tübingen, Germany(智能系统马克斯·普朗克研究所);Tübingen AI Center, Tübingen, Germany(图宾根人工智能中心);University of Surrey, Guildford, United Kingdom(萨里大学);The University of North Carolina at Chapel Hill, Chapel Hill, NC, USA(北卡罗来纳大学教堂山分校)
Mitigating LLM Over-Refusal via Dynamic Semantic Routing Calibration
School of Artificial Intelligence, Jilin University(吉林大学人工智能学院);CSIRO(澳大利亚联邦科学与工业研究组织);Center of Excellence for Generative AI, King Abdullah University of Science and Technology(阿卜杜拉国王科技大学生成式人工智能卓越中心)
Mitigating Coordinate Prediction Bias from Positional Encoding Failures
The Hong Kong University of Science and Technology (Guangzhou)(香港科技大学(广州));The Hong Kong University of Science and Technology(香港科技大学);University of California, Los Angeles(加州大学洛杉矶分校);The University of Queensland(昆士兰大学);Shanghai University of Finance and Economics(上海财经大学)