arXiv:2608.19463cs.LG2026-08中稿 · NeurIPS

用大模型上下文学习能力,不训练直接检测表格异常。

LLM as Detector: An In-context Learning Approach for Tabular Anomaly Detection

论文配图:LLM as Detector: An In-context Learning Approach for Tabular Anomaly Detection
图 1 · 摘自论文原文
  • 用统计摘要和因果关系构造提示,让大模型生成异常评分逻辑
  • 在24个数据集上超越15个顶尖方法,尤其适合混合类型数据
  • 无需微调模型,降低算力成本,适合实际系统部署

表格数据中的异常通常源于多特征间的依赖关系破坏,而非单一变量的偏离。现有方法依赖几何或重构信号,而早期基于大模型的方法主要通过正常样本微调或生成合成异常。我们提出LLM-Detector,利用大模型的上下文学习能力,通过结构化提示条件生成评分机制,使大模型能从正常状态知识中推导出异常检测逻辑。具体地,将正常训练数据转化为统计摘要、因果依赖和压缩原型,并组织成代码生成提示。生成的评分引擎综合评估统计偏差、结构不一致性和密度异常,为每个测试样本计算异常分数。我们在24个表格数据集上评估,对比15个最先进基线。结果表明,在混合类型与仅连续型设置下均实现稳定提升。该设计无需大模型微调或神经网络训练,显著降低计算开销,适用于真实场景中的表格异常检测。

原文摘要 · Abstract (English)

Anomaly detection in tabular data is challenging because abnormal samples often arise as violations of cross-feature dependencies rather than simple marginal deviations. Existing detectors rely on geometric or reconstruction signals, while prior LLM-based approaches mainly fine-tune LLMs with normal samples or generate synthetic anomalies. We propose LLM-Detector, a framework that utilizes the in-context learning capacity of LLMs for structured, prompt-conditioned scoring synthesis, enabling LLMs to derive anomaly detection logic from structured normal-state knowledge. Specifically, normal training data are converted into statistical summaries, causal dependencies, and distilled prototypes that are organized into a prompt for code generation. The resulting scoring engine evaluates statistical deviation, structural inconsistency, and density-based abnormality then computes an anomaly score for each test sample. We evaluate LLM-Detector on 24 tabular datasets, comparing against 15 SOTA baselines. Results show consistent improvements across both mixed-type and continuous-only settings. Moreover, this design eliminates the need for LLM fine-tuning or neural network training, reducing computational cost and enabling practical anomaly detection in real-world tabular systems.

异常检测大模型表格数据零样本

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。