Journal of Computer Applications

    Next Articles

Dual-dimensional knowledge-guided label mapping method for few-shot text classification

  

  • Received:2026-03-12 Revised:2026-06-02 Online:2026-06-17 Published:2026-06-17
  • Supported by:
    Hubei Provincial Key Research and Development Program;the Hubei Provincial Major Science and Technology Program;the Wuhan Natural Science Foundation Focused Program

面向小样本文本分类的双维度知识引导标签映射方法

陈俊宇,曾诚   

  1. 湖北大学
  • 通讯作者: 曾诚
  • 基金资助:
    湖北省重点研发计划项目;湖北省重大攻关项目;武汉市自然科学基金聚力计划

Abstract: To address the issues of single semantic expression, limited coverage, and susceptibility to noise interference caused by the reliance on single label expansion for label mapper construction in prompt learning for few-shot text classification tasks, a dual-dimensional knowledge-guided label mapping construction algorithm was proposed. First, starting from two complementary dimensions of text instance semantics and category ontological semantics, the candidate label space was collaboratively expanded by combining multi-source external knowledge bases to obtain an initial candidate label set with high coverage. Secondly, a two-stage refined filtering mechanism of "semantic relevance-category discriminativeness" was constructed. In the first stage, coarse-grained semantic noise was eliminated using the joint constraints of instance-driven semantics and category priors. In the second stage, the prediction difference of candidate labels in positive and negative samples was strictly calculated based on the log-likelihood ratio to strengthen the category directivity of the labels. Finally, set-level aggregation was performed on the generation confidence of the filtered high-quality label word set to complete the final category determination. Few-shot classification experiments with sample sizes ranging from 1 to 20 were conducted on four mainstream Chinese classification datasets. Theoretical analysis and experimental data showed that, under the one-shot setting, accuracy rates of 72.70%, 61.48%, 63.38%, and 59.49% were achieved on various datasets, respectively, and the accuracy indicators were improved by 3.62%, 2.85%, 3.10%, and 1.32%, respectively, when compared with mainstream knowledge-enhanced prompt learning algorithms. Under the 10-shot scale, an accuracy of 89.43% was reached on the e-commerce sentiment dataset. Ablation analysis showed that the accuracy of one-shot news topic classification was significantly decreased to 56.05% after the two-stage filtering mechanism was removed. The experimental results indicate that the semantic boundary of the label mapping space is effectively broadened, and the interference of cross-category ambiguous words is suppressed. Consequently, the capture accuracy of complex semantic features and the category discrimination stability for pre-trained language models under extreme low-resource conditions are improved.

Key words: text classification, few-shot learning, prompt learning, external knowledge, label mapping, pre-trained language mode

摘要: 针对提示学习在小样本文本分类任务中标签映射器构建依赖单一标签扩展,导致语义表达单一、覆盖范围有限及易受噪声干扰的问题,提出了一种基于外部知识引导的双维度标签映射器构建算法。首先,从文本实例语义与类别本体语义两个互补维度出发,结合多源外部知识库对候选标签空间进行协同扩展,获取高覆盖度的初始候选标签集;其次,构建“语义相关性-类别区分度”两阶段精细化筛选机制,在第一阶段利用实例驱动与类别先验的联合约束剔除粗粒度语义噪声,在第二阶段严格基于对数似然比计算候选标签在正负样本中的预测差异,强化标签的类别指向性;最后,对筛选后的高质量标签词集的生成置信度进行集合级聚合,完成最终的类别判定。在四个主流中文分类数据集上进行了1至20个样本规模的小样本分类实验。理论分析和实验数据表明,与主流知识增强提示学习算法相比,所提方法在单样本设置下,于各类数据集上的准确率分别达到了72.70%、61.48%、63.38%和59.49%,其准确率指标分别提升了3.62%、2.85%、3.10%和1.32%;在10个样本规模下,基于电商情感数据集上的准确率达到了89.43%。消融分析显示,去除两阶段筛选机制后,单样本新闻主题分类的准确率大幅下降至56.05%。实验结果表明,该方法能够切实拓宽标签映射空间的语义边界,抑制跨类别歧义词的干扰,在极端低资源条件下提高了预训练语言模型对复杂语义特征的捕捉精度与类别判别稳定性。

关键词: 文本分类, 小样本学习, 提示学习, 外部知识, 标签映射, 预训练语言模型

CLC Number: