TAAF: A Trace Abstraction and Analysis Framework Synergizing Knowledge Graphs and LLMs
Alireza Ezaz, Ghazal Khodabandeh, Majid Babaei, Naser Ezzati-Jivan
TL;DR
TAAF tackles the challenge of analyzing massive kernel traces by introducing a three-layer framework that first abstracts traces into a time-indexed state system, then grounds query-specific semantics in a knowledge graph, and finally leverages LLMs to generate grounded natural-language answers. The approach is evaluated with TraceQA-100, a dedicated benchmark of kernel-trace QA tasks, showing substantial accuracy gains (up to 31.2%) across multiple LLM backends and temporal settings, especially for multi-hop and causal reasoning. The study demonstrates that graph-grounded reasoning improves robustness and explainability over raw or flattened inputs, and discusses how temporal grounding, schema usage, and model choice influence performance. The work provides a foundation for scalable, explainable trace analysis tools and outlines future directions in temporal KG reasoning and integration with autonomous workflows.
Abstract
Execution traces are a critical source of information for understanding, debugging, and optimizing complex software systems. However, traces from OS kernels or large-scale applications like Chrome or MySQL are massive and difficult to analyze. Existing tools rely on predefined analyses, and custom insights often require writing domain-specific scripts, which is an error-prone and time-consuming task. This paper introduces TAAF (Trace Abstraction and Analysis Framework), a novel approach that combines time-indexing, knowledge graphs (KGs), and large language models (LLMs) to transform raw trace data into actionable insights. TAAF constructs a time-indexed KG from trace events to capture relationships among entities such as threads, CPUs, and system resources. An LLM then interprets query-specific subgraphs to answer natural-language questions, reducing the need for manual inspection and deep system expertise. To evaluate TAAF, we introduce TraceQA-100, a benchmark of 100 questions grounded in real kernel traces. Experiments across three LLMs and multiple temporal settings show that TAAF improves answer accuracy by up to 31.2%, particularly in multi-hop and causal reasoning tasks. We further analyze where graph-grounded reasoning helps and where limitations remain, offering a foundation for next-generation trace analysis tools.
