Lune

FSE2025Top-tier venue

No More Labelled Examples? An Unsupervised Log Parser with LLMs

Junjie Huang, Zhihan Jiang, Zhuangbin Chen, Michael R. Lyu

Abstract

Log parsing serves as an essential prerequisite for various log analysis tasks. Recent advancements in this field have improved parsing accuracy by leveraging the semantics in logs through fine-tuning large language models (LLMs) or learning from in-context demonstrations. However, these methods heavily depend on high-quality labeled examples to achieve optimal performance. In practice, continuously collecting high-quality labeled data is challenging since logs are huge in volume and under frequent evolution, leading to performance degradation or heavy maintenance efforts for existing log parsers after deployment. To address this issue, we propose LUNAR, an unsupervised LLM-based method for efficient and off-the-shelf log parsing. Our key insight is that while LLMs may struggle with direct log parsing, their performance can be significantly enhanced through comparative analysis across multiple logs that differ only in their parameter parts. We refer to such groups of logs as Log Contrastive Units (LCUs). Given the vast volume of logs, obtaining LCUs is difficult. Therefore, LUNAR introduces a hybrid ranking scheme to effectively search for LCUs by jointly considering the commonality and variability among logs. Additionally, LUNAR crafts a novel parsing prompt for LLMs to identify contrastive patterns and extract meaningful log structures from LCUs. Experiments on large-scale public and industrial log datasets demonstrate that LUNAR significantly outperforms state-of-theart log parsers in terms of accuracy and efficiency, providing an effective and practical solution for real-world deployment.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

3 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • InferLog: Accelerating LLM Inference for Online Log Parsing via ICL-oriented Prefix Caching cites A Survey on In-context Learning
  • InferLog: Accelerating LLM Inference for Online Log Parsing via ICL-oriented Prefix Caching cites Rethinking the Role of Demonstrations: What Makes In-Context Learning Work?
  • InferLog: Accelerating LLM Inference for Online Log Parsing via ICL-oriented Prefix Caching cites UniParser: A Unified Log Parser for Heterogeneous Log Data
  • InferLog: Accelerating LLM Inference for Online Log Parsing via ICL-oriented Prefix Caching cites Log Parsing with Prompt-based Few-shot Learning
  • Small Is Beautiful: A Practical and Efficient Log Parsing Framework cites DeepTraLog: Trace-Log Combined Microservice Anomaly Detection through Graph-based Deep Learning
  • A Survey on In-context Learning cites Rethinking the Role of Demonstrations: What Makes In-Context Learning Work?
  • Log Parsing with Prompt-based Few-shot Learning cites UniParser: A Unified Log Parser for Heterogeneous Log Data
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers3

  1. United We Stand: Towards End-to-End Log-based Fault Diagnosis via Interactive Multi-Task LearningMinghua He, Chiming Duan, Pei Xiao, Tong Jia et al.ASE 2025 · 1 citation
  2. InferLog: Accelerating LLM Inference for Online Log Parsing via ICL-oriented Prefix CachingYilun Wang, Pengfei Chen, Haiyu Huang, Zilong He et al.ICSE 2026 · 1 citation
  3. Small Is Beautiful: A Practical and Efficient Log Parsing FrameworkMinxing Wang, Yintong HuoFSE 2026 · 1 citation

Builds on21

  1. Rethinking the Role of Demonstrations: What Makes In-Context Learning Work?Sewon Min, Xinxi Lyu, Ari Holtzman, Mikel Artetxe et al.EMNLP 2022 · 634 citations
  2. A Survey on In-context LearningQingxiu Dong, Lei Li, Damai Dai, Ce Zheng et al.EMNLP 2024 · 479 citations
  3. DeepTraLog: Trace-Log Combined Microservice Anomaly Detection through Graph-based Deep LearningChenxi Zhang, Xin Peng, Chaofeng Sha, Ke Zhang et al.ICSE 2022 · 163 citations
  4. UniParser: A Unified Log Parser for Heterogeneous Log DataYudong Liu, Xu Zhang, Shilin He, Hongyu Zhang et al.WWW 2022 · 148 citations
  5. Log Parsing with Prompt-based Few-shot LearningVan-Hoang Le, Hongyu ZhangICSE 2023 · 98 citations

Related papers

  1. SLGParser: Practical and Efficient Label-Free Log Parsing Using Large Language ModelsYibing Hu, Cong Wang, Lixin Zhao, Aimin YuICDE 2026
  2. Demonstration-Free: Towards More Practical Log Parsing with Large Language ModelsYi Xiao, Van-Hoang Le, Hongyu ZhangASE 2024 · 9 citations
  3. LibreLog: Accurate and Efficient Unsupervised Log Parsing Using Open-Source Large Language ModelsZeyang Ma, Dong Jae Kim, Tse-Hsun Peter ChenICSE 2025 · 7 citations
  4. Unleashing the True Potential of Semantic-Based Log Parsing with Pre-Trained Language ModelsVan-Hoang Le, Yi Xiao, Hongyu ZhangICSE 2025 · 6 citations
  5. VarParser: Unleashing the Neglected Power of Variables for LLM-based Log ParsingJinrui Sun, Tong Jia, Minghua He, Ying LiWWW 2026
Dusk over the sea between two cliffs drawn in fine vertical lines