Search papers, labs, and topics across Lattice.
This paper introduces LLM-Detector, a novel framework leveraging the in-context learning capabilities of large language models (LLMs) to perform anomaly detection in tabular data by synthesizing structured prompts from normal training data. By transforming normal samples into statistical summaries and causal dependencies, the framework generates a scoring engine that evaluates anomalies based on statistical deviation and structural inconsistency without requiring fine-tuning of the LLM. The evaluation across 24 tabular datasets demonstrates significant performance improvements over 15 state-of-the-art baselines, highlighting its efficiency and practicality for real-world applications.
LLM-Detector achieves superior anomaly detection in tabular data without the need for fine-tuning, making it a game-changer for real-world applications.
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.