PiLLar: Matching for Pivot Table Schema via LLM-guided Monte-Carlo Tree Search Yunjun Gao
Zhejiang University [email protected]
Congcong Ge
arXiv:2604.26356v1 [cs.DB] 29 Apr 2026
Zhejiang University [email protected]
Abstract Pivot tables are ubiquitous in data lakes of modern data ecosystems, making accurate schema matching over pivot tables a key prerequisite for data integration. In this paper, we focus on matching for pivot table schema, which is a novel joint schema-value matching task. It aims to align schemas between pivot tables and standard relational tables, where a correct match must be semantically consistent at the schema level and compatible at the value level. However, due to the inherent data sensitivity of this task, the prevalence of anonymized data in practice poses significant challenges to its matching accuracy and generalization capability. To tackle these challenges, we propose PiLLar, the first matching for pivot table schema framework. We first formulate PiLLar as an LLM-driven search paradigm that operates with minimal annotated privacycompliant data, thereby achieving training-free adaptation across diverse domains. Next, we provide a theoretical analysis on the error dynamics of the paradigm to ensure the asymptotic convergence of the proposed method. Furthermore, we introduce a new benchmark PTbench, derived from four representative real-world domains and constructed by mining unpivot-suitable tables, performing unpivot on semantically coherent attributes, and applying sampling and anonymization. Extensive experiments demonstrate the superiority of PiLLar, which achieves an average accuracy of 87.94% on the correctly predicted matches.
CCS Concepts • Information systems → Extraction, transformation and loading; • Computing methodologies → Information extraction.
Keywords Schema Matching, Pivot Tables, Large Language Models, MonteCarlo Tree Search
1
Introduction
It is becoming increasingly easier for companies to acquire large amounts of data from diverse sources [3, 16]. This trend enables SaaS providers (e.g., Salesforce) to deliver richer data analysis capabilities [9, 11, 12, 14] by integrating or linking datasets from different sources. Schema matching [52] serves as a prerequisite for such integration. It aims to identify the semantic correspondence between attributes across disparate data sources. Recently, researchers have devoted considerable efforts to schema matching on standard relational tables [23, 39, 57]. However, they overlook schema matching
Chuangyu Ouyang Zhejiang University [email protected]
Yifan Zhu
Zhejiang University [email protected] for pivot tables, a task of critical importance given their ubiquity in enterprise reporting and business intelligence tools [20, 31, 51]. New task – matching for pivot table schema. In modern data ecosystems, the prevalence of data lakes has led to the proliferation of diverse wild tables [29, 59], among which pivot tables are ubiquitous [31]. Pivot operations transpose values into attribute headers, which obscure semantics and complicate schema matching [60]. Meanwhile, pivot and unpivot are integral reshaping transformations in business intelligence (BI) and machine learning (ML) data preparation pipelines [63, 64]. Thus, effectively matching between pivot tables and standard relational tables is essential for facilitating critical tasks such as master data management [5, 42] and cross-system data interoperability [52, 61]. Notably, matching for pivot table schema introduces an additional data quality pitfall beyond conventional schema matching: the choice of the unpivot attribute set implicitly determines the semantics of the generated Metric–Value fields, and an incompatible choice can silently alter attribute semantics. Such subtle errors arising from changes in data semantics can be difficult to detect yet can severely disrupt downstream decision-making and ML pipelines [54]. Accordingly, industrial data governance and profiling systems emphasize early validation of both schema evolution and semantic drift to prevent error propagation along data pipelines [6, 47]. Therefore, matching for pivot table schema requires a joint schema–value perspective to ensure both schema-level semantic correspondence and value compatibility. Solving this task is non-trivial, and existing approaches fall short. We illustrate the challenges in Example 1. Example 1. We consider two datasets from Football-Data [7], recording information about football match results. Matching schemas between these datasets enables data integration for downstream team and tactical analysis. Figure 1 depicts a snippet. Figure 1(A) is a pivot table 𝑇𝑙 that reports, for each match, four shot-related statistics as attributes: home shots (HS), away shots (AS), home shots on target (HST), and away shots on target (AST). Figure 1(B) is a standard relational table 𝑇𝑟 that adopts a pairwise Metric–Value schema, where each row corresponds to one metric-value record of a match, facilitating aggregation and comparison. In addition, data records of Date and Metric attributes are anonymized to protect sensitive information. Specifically, the Date values may reveal schedules of football teams; the Metric values often encode proprietary performance indicators used by clubs or analytics providers. To correctly align 𝑇𝑙 with 𝑇𝑟 , one must first identify the value-compatible unpivot attribute set {HS, AS} and unpivot 𝑇𝑙 into the intended shot-count records shown in Figure 1(D). Schema
This work has been submitted to the IEEE for possible publication. Copyright may be transferred without notice, after which this version may no longer be accessible.
Yunjun Gao, Chuangyu Ouyang, Congcong Ge, and Yifan Zhu
Div
HS, AS → Metric 11, 20, ⋯ → Value Div
Date
HS
AS
HST
AST
E0 0******0
11
20
8
14
E0 1******0
14
11
13
2
E0 2******1
14
11
4
5
E0 0******1
8
7
1
2
E0 1******1
10
9
7
2
E0 1******0
27
11
15
4
E0 1******1
15
18
11
12
(A) Pivot table
Pairwise
(C) Unpivot
Date
Metric Value
HST
AST
E0 0******0
HS
11
8
14
Div
E0 0******0
AS
20
8
14
Date
E0 1******0
HS
14
13
2
Metric
E0 1******0
AS
11
13
2
Value
…… E0 1******1
AS
18
11
12
HS, AS, HST, AST → Metric 11, 20, 8, 14, ⋯ → Value
Pairwise
Date
Metric Value
E0 0******0
H*
11
AST
Date
E0 1******1
A*
18
Metric
E0 0******1
A*
19
E0 2******0
H*
17
E0 0******1
A*
17
E0 1******1
H*
13
E0 0******1
H*
13
Value
Metric Value
E0 0******0
HS
11
Div
E0 0******0
AS
20
Date
E0 0******0
HST
8
Metric
E0 0******0
AST
14
Value
18
(G) Schema Matching
(E) Flawed Unpivot
Date
Div
(D) Unpivoted table Div
Div
HST
(B) Standard table
…… E0 1******1
AS
(F) Flawed unpivoted table
Figure 1: An example of performing matching for pivot table schema with separate unpivot and schema matching steps matching is then performed between the unpivoted table 𝑇𝑙′ and 𝑇𝑟 , obtaining the correct matches illustrated in Figure 1(G). Challenge I: How to guarantee the matching for pivot table schema accuracy with anonymous data? In practice, schema matching typically occurs in cross-departmental collaboration [46]. In this scenario, data providers can access table metadata (i.e., attributes) but are denied access to the actual data records due to privacy policy, wherein sensitive data is often anonymized. Conventional schema matching methods rely primarily on features derived from attributes themselves. Data records are optional for providing external knowledge [22, 39, 67]. In contrast, matching for pivot table schema highly demands access to data records to identify the value-compatible unpivot attribute set. For example, in Figure 1, the candidate set {HS, AS, HST, AST} is reasonable if one only considers the schema of 𝑇𝑙 . However, this selection would lead to a resulting unpivoted table (as shown in Figure 1(F)) that conflates distinct semantics, namely shots and shots on target, making the generated fields semantically inconsistent with the standard table 𝑇𝑟 . Under such semantic drift, a matcher may still produce seemingly plausible matching at the schema level, but it becomes incorrect at the value level. This ambiguity can only be resolved through record-level data patterns. Such a strong requirement for data records conflicts with the recently growing privacy concerns of data providers in practice [2, 4]. Therefore, our work focuses on matching schemas under the constraint of data minimization, which is a widely accepted concept in data protection regulations and commercial systems [1, 2, 48], to achieve a deliberate balance between privacy preservation and matching accuracy. Challenge II: How to effectively perform matching for pivot table schema? The dual demands of generality and data privacy make Large Language Models (LLMs) particularly suitable for this task. LLMs with billions of parameters exhibit strong zero-shot/fewshot generalization capabilities [17], which facilitates matching for pivot table schema across diverse domains without requiring sensitive data or intensive training. Despite this, their inherent instability means that even the most advanced LLMs are not a reliable standalone solution. We still take Figure 1 as an example. Current schema matching approaches cannot directly match these attribute groups, as they ignore the transformations of schema
structure. A straightforward solution to perform matching for pivot table schema on this example is to first unpivot 𝑇𝑙 and then perform conventional schema matching. Yet 𝑇𝑙 contains a candidate set of attributes that are probably to be unpivoted, namely Acand. = {HS, AS, HST, AST}. Experiments show that both opensource and closed-source state-of-the-art LLMs generate the unpivot result Aunpivot = {HS, AS, HST, AST} (detailed results are presented in Appendix A). This result is reasonable when querying only for attributes unpivotable in the schema of 𝑇𝑙 , but it is incorrect in our task since we aim to obtain correct matching results between the two input tables. Although extensive SOTA LLM-driven approaches have been devoted to schema matching, matching schemas on these flawed input tables can only amplify the error, as described in Example 1. Hence, the core challenge is to mitigate error propagation by jointly ensuring a value-compatible unpivot attribute set choice and a verifiable schema matching to the standard table. In light of these challenges, we make the following contributions: • Flexible Framework. We propose PiLLar, the first LLM-guided search framework for matching pivot table schemas, requiring only few-shot labeled anonymized data and enabling trainingfree adaptation across domains. • Convergent Search Paradigm. We formulate the task as a boundedstochastic search to mitigate LLM instability, guaranteeing both exploration completeness and search efficiency. We further provide a formal analysis establishing asymptotic convergence. • Self-correcting Iterative Search Strategy. We design an identifier— judger iteration in which robust prompts drive the identifier to propose candidate unpivot attribute set, and a multi-dimensional validator serving as a judger provides per-iteration feedback that steers the identifier in the next iteration, mitigating unreliable unpivoting and error propagation during search. • Extensive Experiments. We propose a new benchmark from four real-world domains and show the effectiveness of PiLLar, which achieves an average accuracy of 87.94% on the correctly predicted matches and 94.45% on the correctly operated attributes.
2
Problem Statement
Given a relational table 𝑇 = (A, D, V), where A refers to the attributes, D refers to the description of attributes, and V refers to the sampled anonymized data records. In this paper, we focus on the
PiLLar: Matching for Pivot Table Schema via LLM-guided Monte-Carlo Tree Search
task of matching for pivot table schema. Let 𝑇𝑙 = (A𝑙 , D𝑙 , V𝑙 ) and 𝑇𝑟 = (A𝑟 , D𝑟 , V𝑟 ) be the two given tables. The objective is to first identify the unpivot operator Φ = (Aunpivot, 𝐴var, 𝐴value ) that can transform 𝑇𝑙 into 𝑇𝑙′ to align with 𝑇𝑟 , where Aunpivot represents unpivot attribute set, 𝐴var represents the attribute name derived from the unpivoted attribute names, and 𝐴value represents the attribute name derived from the corresponding data records. The matching result 𝜋 is then generated between the two attribute sets. Here, we consider one-to-one matches where a match specifies that the two attributes are equal to each other, which is a common assumption in schema matching [23, 39, 55, 67, 68]. Formally, 𝜋 : A𝑙′ → A𝑟 ∪ {Null}
(1)
s.t. ∀𝐴𝑖 , 𝐴 𝑗 ∈ A𝑙′, 𝜋 (𝐴𝑖 ) ≠ 𝜋 (𝐴 𝑗 ) ∨ 𝜋 (𝐴𝑖 ) = Null
3
PiLLar Framework
In this section, we describe the framework of PiLLar in detail. Since we formulate matching for pivot table schema as a search problem, we first introduce the proposed search paradigm; we then detail the self-correcting iterative search strategy of PiLLar.
3.1
Search Paradigm
Recall that LLM is a powerful tool for matching for pivot table schema. However, due to the inherent hallucination problem of LLMs [26], it is unsafe to rely solely on LLM generation, as described in Section 1. Considering that search paradigm can effectively mitigate the problem of losing correct answers caused by LLM’s uncertainty [56], we would like to formulate the task of matching for pivot table schema as an LLM-guided search problem. For matching for pivot table schema, identifying the attributes to be unpivoted is a necessary step; however, exploring the complete search space of all attribute subsets is computationally prohibitive, with a complexity of 𝑂 (2𝑛 ). Motivated by the effectiveness of MCTS in balancing the accuracy and efficiency in search problems [18], we propose a bounded-stochastic MCTS variant guided by the LLM. To ensure theoretical convergence—and thereby mitigate potential hallucination from the LLM—we incorporate a bounded-stochastic expansion strategy into the search process. Detailed theoretical analysis can be found in Section 3.1.3. 3.1.1 Overview of the Search Process. We first outline how the proposed bounded-stochastic MCTS variant is involved in our framework. Starting from an initial candidate unpivot attribute set, the MCTS repeatedly executes four phases in each iteration: selection, expansion, evaluation and backpropagation. During the selection phase, the search process traverses the current search tree by applying a UCT policy to identify the most promising node to be expanded. In the expansion phase, a new candidate set is generated by our proposed bound-stochastic expansion policy. Once generated, the evaluation phase performs schema matching between the unpivoted table and the standard table, producing a deterministic reward. Finally, in the backpropagation phase, this reward is propagated along the visited path, which gradually biases the search toward high-quality candidates. Detailed implementation of this process is presented in Section 3.2. Then, we detail the design of our proposed search paradigm, together with a theoretical convergence analysis.
3.1.2 Search and Update Mechanism. Bounded Stochastic Strategy Design. To ensure theoretical convergence while maintaining LLM guidance, we adopt a boundedstochastic strategy in the expansion phase. During expansion, a new child is produced either by an LLM-guided generation with probability 1 − 𝜀, or by a radius-1 random modification (i.e., a single add/remove/swap operation of one attribute) with probability 𝜀 > 0. Each set generated by the random modification is prohibited from being regenerated by it. This mechanism guarantees that all feasible candidates are theoretically reachable (formal proof can be found in Appendix B). Combined with the LLM-guided generation, PiLLar reaches a balance between directed reasoning and theoretical search completeness, enabling the search to cover potential candidate unpivot attribute sets without exhaustive enumeration. Node Evaluation and Reward Propagation. For each candidate attribute set, we generate a corresponding schema matching result and a quantized reward. To ensure stability and analytical tractability, PiLLar adopts a deterministic reward formulation. The reward of each node is designed to be bounded and noise-free, ensuring that every evaluation consistently reflects the true quality of the node. Formally, we assume the reward 𝑅(𝑣) of a node 𝑣 satisfies 𝑅(𝑣) ∈ [0, Ω(𝑇𝑙 ,𝑇𝑟 )], ∀𝑣, where Ω(𝑇𝑙 ,𝑇𝑟 ) is a deterministic upper bound of the reward based solely on the given input tables. Once a node is evaluated, its estimated reward is updated through the max–average backpropagation rule: 1 𝑄 𝑣𝑖 ← 𝑄 𝑣𝑖 + max 𝑅𝑣𝑖 , max 𝑄𝑣𝑗 (2) 2 𝑣 𝑗 ∈children(𝑣𝑖 ) where 𝑄 𝑣𝑖 represents the estimated value for node 𝑣𝑖 , and 𝑅𝑣𝑖 represents the reward of node 𝑣𝑖 . This update design reflects the optimization-oriented role of our framework: instead of using simulated rollouts to estimate the value of a node as in traditional MCTS, each node’s 𝑄-value in our framework measures the potential improvement obtainable by further exploration from that node. Therefore, only better descendants are allowed to update their ancestors through the max operator, guiding the search toward regions of higher potential. Together, the 𝜀-random expansion and the max–average backpropagation construct a bounded-stochastic MCTS variant that achieves asymptotic search completeness, while preserving the efficiency advantages of LLM-guided reasoning. 3.1.3 Theoretical Analysis. To understand how bounded stochasticity influences convergence, we analyze the error dynamics, including weak-hit disturbance, a single-hit contraction kernel, and an asymptotic block recursion. Analysis Setup. Let S be the finite candidate unpivot attribute sets (defined by the finite attribute universe). Each search-tree node 𝑣 encodes a candidate 𝑠 = 𝜏 (𝑣) ∈ S (where 𝜏 is many-to-one since Self-Refine may generate distinct nodes for the same 𝑠). For each node 𝑣, its deterministic reward is denoted by 𝑅(𝑣) ∈ [0, Ω(𝑇𝑙 ,𝑇𝑟 )]. Suppose there exists an optimal node 𝑣 ★ corresponding to the optimal candidate 𝑠 ★ = 𝜏 (𝑣 ★), such that 𝑅(𝑣 ★) = max𝑣 𝑅(𝑣). Let (𝑣 0, . . . , 𝑣 𝐻 ) denote a minimal witnessing path from the root (depth 0) to 𝑣 ★ (depth 0 ≤ 𝐻 ≤ |S|). Let 𝑒𝑑 be the absolute error at depth 𝑑 with respect to 𝑅(𝑣 ★) before an iteration’s backpropagation, and 𝑒𝑑′ the error after that backpropagation in the same iteration.
Yunjun Gao, Chuangyu Ouyang, Congcong Ge, and Yifan Zhu
Inputs
Outputs
Schema Flattening
Pivot Table:
Evaluate
Initialization
Div
HS
AS
HST
E0
6
11
20
E0
14
11
11
{Div, HS, AS, HST}
E0
H*
8
E0
A*
9
History Node
{HS, AS, HST}
Div, Metric, Value, HST
Unpivoted Table: {AS, HST}
{HS, HST}
Visited Edge LLM
{HS, AS}
Div Metric Value HST E0 HS 6 20 E0 AS 11 20 E0 HS 14 11 E0 AS 11 11
Lexical Similarity
Div, Metric, Value
Semantic Similarity
}
Expanded Node
Schema Matching
Refine
{
Visited Node
Div Metric Value
Feedback
Distribution Similarity
}
Standard Table:
{Div, HS, AS}
### Evaluation of the Selected Columns for unpivot ……
Div → Div Metric → Metric Value → Value
{
{Div, AS, HST}
: [HS, AS] : Metric : Value
Reward
Maximum Weighted Bipartite Matching
1 0.179 0.103
0.179 1 0.154
Average Combiner 0.104 0.154 0.948
0.076 0.115 0.297
Similarity Matrix
Figure 2: Overview of the PiLLar framework Sketch. We sketch the argument and defer details to Appendix B. Since S is finite and expansion is 𝜀-randomized, every feasible candidate is generated with probability 1 (probabilistic completeness). Once the optimal node 𝑣 ★ is discovered, the max–average backup yields a contraction effect on the root’s estimation error whenever 𝑣 ★ is reached and backpropagated. Moreover, under UCT with deterministic rewards, suboptimal selections become asymptotically negligible, so the disturbance from weak updates vanishes. Therefore the root estimate converges asymptotically to 𝑅(𝑣 ★). □
3.2
Role: system Instruction Role: user Definition & Requirement
Role: user Examples Role: assistant Instruction
Persona Definition & Prompt Frame Explanation Unpivot Concept Definition Task Requirement & Response Format Requirement Few-Shot Examples Regular Output Empty Output
Acknowledge Receipt
Self-correcting Iterative Search Strategy
Based on the bounded stochastic search paradigm described in Section 3.1, we now detail how to perform PiLLar in an iterative manner via two key components, i.e., schema flattening and schema matching. Figure 2 depicts an overview. 3.2.1 Schema Flattening. This component serves as an identifier, which aims to flatten the schema of the input pivot table 𝑇𝑙 into a standard format that complies with the input standard table 𝑇𝑟 . It leverages the proposed LLM-guided MCTS variant to explore candidate unpivot operators. To better leverage the semantic capability of LLMs, we adopt the Self-Refine [43] mechanism to optimize the generated operators. Self-Refine provides a feedback-controlled update mechanism that turns unguided exploration into a directional process that incrementally improves candidate quality. Besides, this mechanism can integrate well with MCTS, as the tree structure naturally preserves refinement paths while maintaining candidate diversity through branching exploration. Under this design, each node on the Monte-Carlo tree represents a candidate unpivot operator, and each edge represents a Self-Refine/random radius-1 modification process. Schema flattening consists of four phases, namely initialization, selection, expansion and backpropagation. The detailed description of the backpropagation phase can be found in Section 3.1.2. The details of initialization, selection, and expansion are described below. Initialization. It acts as the start of the PiLLar framework. During this phase, the root node of the Monte-Carlo tree is generated by querying LLM for an initial candidate unpivot attribute set. Motivated by the clear layout prompt style [24], we design a standardized initialization prompt template to facilitate this generation, as shown in Figure 3. The prompt begins with a persona definition and a prompt frame explanation, which are system-level
Instruction Role: user Inputs
Inputs Source Attributes Target Attributes Attribute Descriptions
Figure 3: An example of an initialization prompt template instructions that define the model’s persona and the frame of the following prompt. This instruction ensures domain alignment and establishes a consistent interpretive frame before specific requirements and input are provided. This is followed by the definition and requirement section, which clarifies the unpivot concept definition, introduces the task of detecting unpivotable attributes in task requirement and specifies the output in response format requirement. Here, LLM is required to select more attributes within reason so that in the expansion phase we can ask LLM to unidirectionally reduce the attributes in the candidate unpivot attribute set, and thus avoid getting stuck in a cycle. After that, we provide two illustrative few-shot examples that serve as few-shot demonstrations to help the model understand the task definition and output pattern. The first example presents a typical unpivot scenario, clarifying the task semantics and indicating the correct output format, while the second specifies the edge case where no attribute should be unpivoted. We empirically found that these examples are sufficient for conveying the task intent, i.e., to propose a reasonably inclusive set of potentially unpivotable attributes, narrowing and structuring the search space for later refinement. The challenge of identifying the unpivot attribute set is resolved during the subsequent expansion phase rather than through additional examples at initialization. In the last section, we provide the input information with sharp symbols to make the prompt clearer.
PiLLar: Matching for Pivot Table Schema via LLM-guided Monte-Carlo Tree Search
Selection. The selection phase is the beginning of each iteration after initialization. Starting from the root node, this phase traverses the search tree by visiting child nodes until reaching a node not fully expanded. Since each child node represents a refinement of the current unpivot attribute set, a node actually has infinite expansion space. Therefore, we define a node as fully expanded when it reaches a maximum number of child nodes, where the maximum number is a user-defined hyper-parameter. When the selection is currently performed at node 𝑣𝑖 , each child node 𝑣 𝑗 ∈ C(𝑣𝑖 ) is assigned a UCT [32] score: √︄ ln 𝑁 𝑣𝑖 (3) UCT𝑣 𝑗 = 𝑄 𝑣 𝑗 + 𝐶 𝑁𝑣𝑗 + 𝜖 where 𝑄 𝑣 𝑗 represents the cumulative reward of node 𝑣 𝑗 , 𝑁 𝑣𝑖 represents the visit count of 𝑣𝑖 , 𝑁 𝑣 𝑗 represents the visit count of 𝑣 𝑗 , 𝐶 is a hyperparameter to balance exploitation and exploration, 𝜖 is a small constant preventing Equation (3) from dividing zero. The child node with the greatest UCT score is selected. Expansion. This phase generates child nodes for the selected node, similar to the expansion phase in traditional MCTS. The difference is that it does not randomly generate a child node in the possible search space, but follows a combined expansion strategy. With a probability of 1 − 𝜀, it asks LLM to optimize the current unpivot attribute set, and with a probability of 𝜀 it performs a radius-1 random modification. This strategy avoids inefficient blind exploration by leveraging semantic guidance from LLM while still preserving sufficient randomness for convergence. For a node 𝑣 to be expanded, we have (4)
𝑓 𝑏 = M (𝑝 fb ∥𝑇𝑙 ∥𝑇𝑟 ∥𝑣) ( 𝑣′ =
M (𝑝 init ∥𝑇𝑙 ∥𝑇𝑟 ∥𝑣 ∥𝑝 refine ∥𝑓 𝑏)
w.p. 1 − 𝜀
(5)
N (𝑣)
w.p. 𝜀
(6)
where 𝑝 init refers to the prompt that guides model M to generate the initial unpivot attribute set, 𝑝 fb refers to the prompt that guides M to generate the feedback 𝑓 𝑏 for 𝑣, 𝑝 refine refers to the prompt that guides M to generate optimized output 𝑣 ′ , and N (𝑣) refers to a random neighbor obtained by a radius-1 modification of the candidate unpivot attribute set of node 𝑣. Although the use of iterative LLM querying here increases the time cost compared to traditional schema matching approaches, this cost remains acceptable in real-world schema matching scenarios. Industrial studies [30] have reported that Amazon’s large-scale schema matching systems, which also rely on LLM reasoning for attribute alignment, typically operate on an hour-level timescale while still achieving substantial efficiency gains, reducing human review time by more than 90%. Equation (4) represents the process of model M evaluating the current unpivot attribute set and offering feedback. We design the following three calibration hints in the prompt for this query to calibrate some biases we found empirically: (1) The evaluation should focus on the transformation between the input tables using the current unpivot attribute set. Sometimes LLM may judge the design of input tables which is not what we expect here, so we use this hint to calibrate it. (2) The optimization task should focus on reducing the size of the current unpivot attribute set. This hint is designed to coordinate
with 𝑝 init in order to build a unidirectional reasoning path, as we mentioned in the initialization phase. (3) All attributes mentioned in the feedback should be selected from the attribute sets A𝑙 and A𝑟 . This hint is used to prevent M from generating feedback that contains attributes that do not exist and leads to an illegal unpivot attribute set. Equation (5) represents the process of M refining the current unpivot attribute set based on the feedback generated from Equation (4). The prompt template for this step produces a multi-turn conversation by sequentially incorporating refinement requirements and feedback after the initialization prompt and the LLM’s response. Based on the bias we discovered in experiments that even if the feedback indicates the selection is ideal, LLM may still modify the unpivot attribute set according to the analysis procedure in the feedback, we calibrate LLM with the calibration hint that it can leave the unpivot attribute set unchanged under this circumstance. After the new candidate unpivot attribute set is generated, we can query LLM for a pair of corresponding attribute names 𝐴var and 𝐴value derived from the unpivot attributes to obtain an unpivot operator, and apply the operator to the pivot table 𝑇𝑙 to get the unpivoted table 𝑇𝑙′ . Evaluation of this operator is performed in the schema matching component, for which we provide a detailed illustration in Section 3.2.2. 3.2.2 Schema Matching. The schema matching component acts as the judger. It aligns the unpivoted table 𝑇𝑙′ with 𝑇𝑟 and evaluates the reward of the unpivot operation. This component operates in two phases: Similarity Calculation and Matching Generation. Similarity Calculation. During this phase, we compute the similarity score between each pair of attributes and obtain a similarity matrix between 𝑇𝑙′ and 𝑇𝑟 . To comprehensively measure attribute correspondence, we adopt a multi-dimensional evaluation metric that integrates three complementary dimensions: (i) a lexical signal using Levenshtein distance [35] on attribute names, (ii) a semantic signal using the cosine similarity of embeddings [27] of attribute names, and (iii) a distributional signal based on Jensen–Shannon (JS) divergence [38] between the value distributions of the two attributes. Each dimension outputs a similarity score in [0, 1]. For each attribute pair, all three similarity scores are computed when both attributes are integer-valued, since the JS divergence applies solely to numerical distributions. Otherwise, only lexical and semantic similarities are used for computation. The similarity of the value distribution with limited precision from sampled data records acts as complementary evidence for the metric to evaluate the plausibility of unpivot attributes Aunpivot . This design complements the LLM-based unpivot identification in the schema flattening component, enabling PiLLar to achieve a balanced selection that aligns both semantic consistency and data distribution. In order to combine these scores into a comprehensive similarity score, we apply a combiner that takes these scores as input and outputs a similarity score between 0 and 1. In our current implementation, we use a simple average combiner based on the experiments (detailed experimental results can be found in Appendix E.2). Matching Generation. A similarity matrix 𝑀 is formed after calculating all pairs of attributes between 𝑇𝑙′ and 𝑇𝑟 . To get a schema matching and a quantized evaluation, we apply maximum weighted bipartite matching to the matrix with a modified Jonker-Volgenant
Yunjun Gao, Chuangyu Ouyang, Congcong Ge, and Yifan Zhu
Table 1: Statistics of PTbench used in experiments Dataset pivot table Adult standard table pivot table Football standard table pivot table President standard table pivot table Gene standard table
# Total Entities 32,561 65,122 380 2,280 43 215 48,231 1,205,775
# Attributes 19 19 23 13 12 4 119 96
algorithm without initialization [21]. The maximum reward and the corresponding matching are sent back to the schema flattening component and guide the subsequent iterations.
4
Experiments
In this section, we conduct extensive experiments to evaluate the effectiveness of PiLLar using our benchmark datasets.
4.1
Experimental Settings
Datasets. To the best of our knowledge, there is no widelyacknowledged benchmark dataset for assessing schema matching over pivoted tables. To study the performance of PiLLar in realworld scenarios, we propose a new benchmark named PTbench, which contains four datasets, using real cases from two categories: (i) online user forums and (ii) spreadsheet-tables from real-life ETL processes [37]. Table 1 shows the statistics of PTbench. Adult. This dataset is extracted from the 1994 Census Bureau database [15]. It contains data relevant to demographic information and economic conditions. Both the pivot table 𝑇𝑙 and standard table 𝑇𝑟 contain 19 attributes, and the unpivot attribute set contains 2 attributes. 19 pairs of attributes are matched between the two tables. Football. This is the Premier League dataset published in Footballdata [7]. It contains data such as team information, goals and shots, etc. The pivot table consists of 23 attributes, among which 6 form the unpivot attribute set, while the standard table contains 13 attributes. There are 13 attribute matches between the two tables. President. This dataset is extracted from real-life ETL processes. It contains evaluation data from various perspectives on presidents of the USA including war record, economic approval rate and so on. The pivot table contains 12 attributes and the standard table contains 4 attributes. The unpivot attribute set consists of 5 attributes, and the ground truth contains 4 pairs of matches. Gene. This dataset is derived from the GTEx v11 public sample annotation table [10]. It contains rich metadata for human tissue samples such as tissue type, detailed tissue subtype and RNA quality metrics. The pivot table contains 119 attributes and the standard table contains 96 attributes. The unpivot attribute set consists of 25 attributes, and the ground truth contains 96 pairs of matches. All four tables have been stratified sampled to balance the requirements between user privacy and data distribution. In addition, we apply anonymization to string attributes to protect user privacy. Comparative Approaches. We compare PiLLar against the following representative approaches: COMA 3.0 [45], DisB [66],
GRAM [39] and NaiveP (a naive pipeline that performs unpivot attribute identification and schema matching independently without iterative refinement). See Appendix D.1 for more details. Evaluation Metrics. The end-to-end accuracy is the traditional evaluation metric for the schema matching approaches. Since our datasets contain unpivot attributes, this metric cannot evaluate the performance of the approaches, so we additionally adopt perattribute accuracy as a second metric. Specifically, we use the following two metrics: • End-to-End Accuracy (𝑨𝒄𝒄 E2E ). 𝐴𝑐𝑐 E2E represents the ratio of correctly predicted matches to ground truth matches, evaluating the performance of approaches end-to-end. For the attributes generated by the unpivot operation, a match is counted as correct only if the approach correctly identifies the unpivot attribute set and matches the generated attributes with the correct target. • Per-Attribute Accuracy (𝑨𝒄𝒄 per_attr. ). 𝐴𝑐𝑐 per_attr. captures the ratio of correctly operated attributes to all attributes. For attributes in the unpivot attribute set, correctly operated means successfully recognizing them as the attributes to be unpivoted, while for other attributes, it means matching them to the correct target. Formally, for input attribute sets A𝑙 and A𝑟 , the ground truth unpivot attribute set is Aunpivot and the ground truth matching ′ is 𝜋. If the approach identifies an unpivot attribute set Aunpivot , ′ ′ transform A𝑙 into A𝑙 , and generate a matching 𝜋 , we have: 𝐴 | 𝐴 ∈ A𝑙′ ∧ 𝜋 (𝐴) = 𝜋 ′ (𝐴) ≠ Null (7)
𝐴𝑐𝑐 E2E = 𝐴 | 𝐴 ∈ A𝑙′ ∧ 𝜋 (𝐴) ≠ Null 𝐴𝑐𝑐 per_attr. =
|Acorrect | |A𝑙 | + |A𝑟 |
(8)
where Acorrect = 𝐴 | 𝐴 ∈ (A𝑙 − Aunpivot ) ∧ 𝜋 (𝐴) = 𝜋 ′ (𝐴) ∪ 𝐴 | 𝐴 ∈ A𝑟 ∧ ∃𝐴′ ∈ A𝑙′, 𝜋 (𝐴′ ) = 𝜋 ′ (𝐴′ ) = 𝐴
(9)
′ ∪ (Aunpivot ∩ Aunpivot )
4.2
Overall Performance
We first conduct a comprehensive comparison of various schema matching methods. Table 2 reports the overall performance. This table consists of two parts. The first part shows the performance of approaches considering all attributes. Since all the competitors are not designed for pivot tables, PiLLar significantly outperforms all baselines on all datasets. Compared to the strongest baseline (NaiveP), it achieves improvements of 15.63% and 15.90% in 𝐴𝑐𝑐 E2E and 𝐴𝑐𝑐 per_attr. , respectively. The noticeably lower performance of NaiveP demonstrates that the absence of iterative feedback limits matching effectiveness, whereas PiLLar benefits from refinement and cross-component interaction. In particular, we observe that PiLLar achieves 100% accuracy on both the Adult dataset, while the performance on the President dataset is relatively low. This is because the difficulty in the four datasets lies in accurately identifying the unpivot attribute set. For Adult, the unpivot attributes are structurally explicit and semantically distinguishable from the rest of the schema, making the optimal unpivot subset almost uniquely
PiLLar: Matching for Pivot Table Schema via LLM-guided Monte-Carlo Tree Search
Table 2: 𝐴𝑐𝑐 E2E (%) and 𝐴𝑐𝑐 per_attr. (%) of various approaches on different datasets
𝐴𝑐𝑐 E2E
Adult 𝐴𝑐𝑐 per_attr.
COMA 3.0 DisB GRAM NaiveP PiLLar
78.94 56.84 78.94 100.00 100.00
COMA 3.0 DisB GRAM NaiveP PiLLar
88.23 70.59 88.23 100.00 100.00
Methods
1.0 0.9 0.8 0.7 0.6 0.5 0.4
𝐴𝑐𝑐 E2E
78.94 56.83 78.94 100.00 100.00
84.62 35.38 86.42 84.62 93.85
97.92 12.50 93.75 69.58 97.92
87.44 11.16 83.72 73.86 92.93
77.87 33.68 76.83 76.05 87.94
73.54 38.23 74.17 81.49 94.45
88.23 70.59 88.23 100.00 100.00
100.00 36.36 100.00 100.00 100.00
100.00 12.77 95.74 71.06 100.00
100.00 12.77 95.74 71.06 100.00
97.06 54.93 95.99 92.77 100.00
97.06 54.93 95.99 92.77 100.00
President Gene
0
1
2
3
Iterations
4
5
(a) 𝐴𝑐𝑐 E2E
President 𝐴𝑐𝑐 E2E 𝐴𝑐𝑐 per_attr. All attributes 77.78 50.00 50.00 37.78 30.00 47.14 77.78 50.00 56.25 83.33 50.00 68.75 96.11 60.00 88.75 Without unpivot attributes 100.00 100.00 100.00 36.36 100.00 100.00 100.00 100.00 100.00 100.00 100.00 100.00 100.00 100.00 100.00
Adult Football
ACCper_attr.
ACCE2E
Adult Football
Football 𝐴𝑐𝑐 E2E 𝐴𝑐𝑐 per_attr.
1.0 0.9 0.8 0.7 0.6 0.5 0.4
0
1
President Gene
2
3
Iterations
4
5
(b) 𝐴𝑐𝑐 per_attr.
Figure 4: Performance of different iteration times identifiable. In contrast, the President dataset contains 10 similar president evaluation metrics, and semantically many subsets of these 10 attributes are plausible candidates. This ambiguity results in vast exploration of suboptimal branches, making it harder to reach the ground-truth unpivot attribute set. The second part shows the accuracy of attributes without unpivot-related ones, i.e., attributes to be unpivoted in the source table and the attributes to be generated in the target table. Since the core challenge of the datasets lies in identifying the correct unpivot attributes, once the unpivot attributes are correctly removed, most approaches can achieve strong matching accuracy. In contrast, the DisB method performs the worst because it relies solely on statistical distributions of values, while our datasets contain only stratified sampled records, making such distribution signals unreliable. PiLLar again performs the best among all competitors.
4.3
Effect of Iterations
In this section, we investigate the impact of iteration times in PiLLar. We include iteration 0 as a baseline case where no iterative refinement is performed. In this setting, the pipeline degenerates into the NaiveP baseline, with the two components executing independently without interaction. We explore the accuracy with iterations from 0 to 5, and the results are plotted in Figure 4. For the Adult dataset, the accuracy remains 100% from iteration 0 to iteration 5 since this dataset does not have many challenges in unpivot identification; for the other three datasets, the plot shows a significant increase in accuracy for iterations from 0 to 2; however, for iterations from 3 to 5, this increase diminishes quickly. The low 𝐴𝑐𝑐 E2E and 𝐴𝑐𝑐 per_attr. observed at iteration 0 validate the Challenge II
Gene 𝐴𝑐𝑐 per_attr.
Average 𝐴𝑐𝑐 E2E 𝐴𝑐𝑐 per_attr.
discussed in Section 1, demonstrating that treating unpivot identification and schema matching as isolated processes yields suboptimal performance. The noticeable increase in accuracy across iterations from 0 to 2 indicates the effectiveness of Self-Refine for the unpivot attribute set identification task, but the markedly slowed and even stabilized improvement after iteration 3 shows that Self-Refine’s capability has an upper bound; the LLM cannot infinitely improve its answers. As additional iterations incur higher computational and interaction costs (especially with large models) while offering only marginal accuracy gains, we set the number of iterations in PiLLar to 2 by default to balance the efficiency and accuracy. Two iterations already provide sufficient interaction between the two components to achieve a satisfying performance.
4.4
Effect of Stochastic Probability 𝜀
In this section, we evaluate the effect of different probability 𝜀 for random radius-1 modification in the expansion phase. We explore the accuracy for 𝜀 ∈ {0.05, 0.2, 0.4, 0.6, 0.8, 1.0}, and the results are plotted in Figure 5. Since the Adult dataset is not challenging, and the initialization phase at iteration 0 can already reach 100% accuracy (as verified in Section 4.3), we focus on the performance on the other three datasets, i.e., Football, President and Gene. Figure 5 presents the different iteration-accuracy curves under different 𝜀 values. Overall, the accuracy increases as the iterations increase from a broad perspective for all settings. When comparing across different 𝜀 values, smaller 𝜀 leads to a faster and more stable accuracy improvement, whereas larger 𝜀 results in slower convergence and more frequent local fluctuations. This effect is more pronounced on the large-scale Gene dataset, where we observe more outliers in the curves, because its much larger search space makes the 𝜀-induced random exploration markedly less effective under a limited number of iterations. This demonstrates that LLM-guided refinement effectively steers the search toward correct unpivot operators and accelerates convergence.
4.5
Ablation Study on Root Node Generation
In this section, we conduct an ablation study on the generation of the root node. We compared the accuracy of different generation methods of the unpivot attribute set for the root node or the MonteCarlo search tree on Qwen3 models of different sizes. Our study
1.0 0.8 0.6 0.4 0.2 0.0
AccE2E
AccE2E
Yunjun Gao, Chuangyu Ouyang, Congcong Ge, and Yifan Zhu
=0.05 =0.2
0
1
=0.4 =0.6
2
3
Iterations
=0.8 =1.0
4
5
1.0 0.8 0.6 0.4 0.2 0.0
=0.05 =0.2
0
1
=0.4 =0.6
2
3
Iterations
=0.8 =1.0
4
Accper_attr.
AccE2E
(a) 𝐴𝑐𝑐 E2E on Football
5
1.0 0.8 0.6 0.4 0.2 0.0
=0.05 =0.2
0
1
=0.4 =0.6
2
3
Iterations
=0.8 =1.0
4
=0.05 =0.2
0
1
=0.4 =0.6
2
3
Iterations
=0.8 =1.0
4
5
(e) 𝐴𝑐𝑐 per_attr. on President
(b) 𝐴𝑐𝑐 E2E on President
5
1.0 0.8 0.6 0.4 0.2 0.0
Rule-based approaches. Rule-based schema matching relies on manually designed rules to measure similarity between source and target attributes. Representative systems [23, 44, 49, 68] combine lexical, structural, and distributional heuristics, usually with fixed or lightweight aggregation. COMA [22] integrates multiple handcrafted matchers via predefined combine strategies (e.g., average/max/min-threshold). DistributionBased [66] leverages distribution similarity and intersection signals to group semantically related columns into shared attributes. While these methods are efficient and interpretable, they often miss deeper semantic correspondences, and designing robust rules remains non-trivial. Deep-learning-based approaches. Deep-learning methods (semi)automatically discover schema matches using neural models. Many works [58, 62, 65, 67] encode attribute names (and optionally metadata) with pretrained language models, then compute similarities via neural modules or self-training. ADnEV [57] instead refines a similarity matrix produced by conventional matchers using two neural networks. Compared to rule-based methods, these approaches better capture semantics and can adapt with labeled data or feedback, but they typically require substantial training data; models trained on one domain may also generalize poorly to new domains. LLM-based approaches. Recent work leverages LLMs for schema matching. GRAM [39] combines named-entity-resolution (NER) and retrieval-augmented generation (RAG) [36] to generate privacyaware prompts and improve efficiency and accuracy. Other systems [41, 50, 55] use LLMs for reranking, synthetic in-context learning, or hybrid pipelines, largely treating LLMs as semantic reasoners or validators rather than redesigning the workflow. These approaches offer strong semantic generalization and can work under privacy constraints, but still struggle with ambiguous domain abbreviations and cases requiring knowledge beyond semantics.
=0.05 =0.2
0
1
=0.4 =0.6
2
3
Iterations
=0.8 =1.0
4
5
1.0 0.8 0.6 0.4 0.2 0.0
=0.05 =0.2
0
1
=0.4 =0.6
2
3
Iterations
=0.8 =1.0
4
5
(f) 𝐴𝑐𝑐 per_attr. on Gene
Time (s)
Figure 5: Performance of different epsilon 210 28 26 24 22 20
PiLLar GRAM
101
102
103
# Attributes Figure 6: Runtime scalability w.r.t. the number of attributes shows that querying LLM for an initial set outperforms both simply selecting all the source attributes and selecting random attributes on the 235B version Qwen3 model. More details of the evaluation results are presented in Appendix E.1.
4.6
number of LLM calls constant, so the overhead comes only from the modest increase in prompt length within a fixed number of calls, yielding a much more gradual runtime increase as the schema scales. As discussed in Section 3.2, we consider this runtime as acceptable given the significant performance gains.
5
(d) 𝐴𝑐𝑐 per_attr. on Football
Accper_attr.
Accper_attr.
(c) 𝐴𝑐𝑐 E2E on Gene
1.0 0.8 0.6 0.4 0.2 0.0
Scalability of PiLLar
In this section, we evaluate the runtime scalability of PiLLar on different numbers of attributes across three orders of magnitude (101 , 102 and 103 ). To evaluate the 103 -scale runtime, we additionally use the M5 Forecasting (Walmart sales) dataset from Kaggle 1 , which contains around 2000 time-series columns. As mentioned in Challenge II discussed in Section 1, matching for pivot table schema inherently requires LLM reasoning. Therefore, we compare runtime scalability against a representative LLM-based baseline, GRAM. As shown in Figure 6, PiLLar exhibits a noticeably flatter growth trend than GRAM as the number of attributes increases, indicating better scalability for large schemas. This is because GRAM issues one LLM call per attribute, so its total number of calls grows linearly with the number of attributes; with the increase in per-call latency as the prompt becomes longer on larger schemas, the runtime grows worse than linear in practice. In contrast, our method keeps the 1 https://www.kaggle.com/competitions/m5-forecasting-accuracy
6
Related Work
Conclusions
In this paper, we study the joint schema-value matching problem between pivot tables and standard relational tables under the setting where only a minimum of data records can be accessed due to privacy concerns. We present PiLLar, an LLM-driven matching for pivot table schema method that relies on our proposed MCTS-based search paradigm. In PiLLar, we divide the matching generation process into two stages, namely schema flattening and schema matching, which are iteratively executed and mutually adjust each other. Schema flattening is a component that identifies the unpivot operator for the input pivot table, and schema matching is a component that generates matches and evaluates the reward. Our experiments shows the superiority of PiLLar. As for future works, a promising direction is to handle more complex mapping transformations for tables in the wild.
PiLLar: Matching for Pivot Table Schema via LLM-guided Monte-Carlo Tree Search
References [1] 2016. General Data Protection Regulation. https://gdpr-info.eu/ [2] 2018. Regulation (EU) 2018/1725 of the European Parliament. https://eurlex.europa.eu/legal-content/EN/TXT/?uri=CELEX%3A32018R1725 [3] 2020. Rethink Data: Put More of Your Business Data to Work-From Edge to Cloud. https://www.seagate.com/files/www- content/our- story/rethinkdata/files/Rethink_Data_Report_2020.pdf [4] 2024. California Consumer Privacy Act. https://oag.ca.gov/privacy/ccpa [5] 2024. Informatica – Master Data Management. https://www.informatica.com/re sources/articles/what-is-master-data-management.html [6] 2025. Cloud Data Governance and Catalog. Technical Report. Salesforce, Inc. https://www.informatica.com/content/dam/informatica-com/en/collateral/da ta-sheet/cloud-data-governance-and-catalog_data-sheet_4152en.pdf [7] 2025. Football-Data. https://www.football-data.co.uk/ [8] 2025. Foundry Ontology Overview. https://www.palantir.com/docs/foundry/on tology/overview. [9] 2025. Google Cloud Looker. https://cloud.google.com/looker [10] 2025. GTEx Portal. https://www.gtexportal.org/home/ [11] 2025. Microsoft Fabric. https://app.fabric.microsoft.com [12] 2025. Microsoft Power BI. https://app.powerbi.com [13] 2025. PowerCenter 10.5.9 Designer Guide: Editing Columns. https://docs.inf ormatica.com/data-integration/powercenter/10-5-9/designer-guide/workingwith-flat-files/editing-flat-file-definitions/editing-columns.html. [14] 2025. Salesforce CRM. https://www.salesforce.com/crm/ [15] 2025. U.S. Census Bureau Homepage. https://www.census.gov/ [16] Michael Armbrust, Tathagata Das, Liwen Sun, Burak Yavuz, Shixiong Zhu, Mukul Murthy, Joseph Torres, Herman van Hovell, Adrian Ionescu, Alicja Łuszczak, et al. 2020. Delta Lake: High-Performance ACID Table Storage over Cloud Object Stores. PVLDB 13, 12 (2020), 3411–3424. [17] Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. 2020. Language Models are Few-Shot Learners. Advances in Neural Information Processing Systems 33 (2020), 1877–1901. [18] Cameron B Browne, Edward Powley, Daniel Whitehouse, Simon M Lucas, Peter I Cowling, Philipp Rohlfshagen, Stephen Tavener, Diego Perez, Spyridon Samothrakis, and Simon Colton. 2012. A Survey of Monte Carlo Tree Search Methods. TCIAIG 4, 1 (2012), 1–43. [19] Nancy Chinchor and Patricia Robinson. 1997. MUC-7 Named Entity Task Definition. In MUC, Vol. 29. 1–21. [20] Whanhee Cho and Anna Fariha. 2025. Data-Semantics-Aware Recommendation of Diverse Pivot Tables. arXiv preprint arXiv:2507.06171 (2025). [21] David F Crouse. 2016. On Implementing 2D Rectangular Assignment Algorithms. IEEE Trans. Aerospace Electron. Systems 52, 4 (2016), 1679–1696. [22] Hong-Hai Do and Erhard Rahm. 2002. COMA — A System for Flexible Combination of Schema Matching Approaches. In PVLDB. 610–621. [23] AnHai Doan, Pedro Domingos, and Alon Levy. 2000. Learning Source Description for Data Integration. In WebDB. 81–86. [24] Xuemei Dong, Chao Zhang, Yuhang Ge, Yuren Mao, Yunjun Gao, Jinshu Lin, Dongfang Lou, et al. 2023. C3: Zero-shot Text-to-SQL with ChatGPT. arXiv preprint arXiv:2307.07306 (2023). [25] Pavan Edara and Mosha Pasumansky. 2021. Big Metadata: When Metadata is Big Data. PVLDB 14, 12 (2021), 3083–3095. [26] Sebastian Farquhar, Jannik Kossen, Lorenz Kuhn, and Yarin Gal. 2024. Detecting hallucinations in large language models using semantic entropy. Nature 630, 8017 (2024), 625–630. [27] Wael H Gomaa, Aly A Fahmy, et al. 2013. A Survey of Text Similarity Approaches. International Journal of Computer Applications 68, 13 (2013), 13–18. [28] Jessica B. Hamrick, Victor Bapst, Alvaro Sanchez-Gonzalez, Tobias Pfaff, Theophane Weber, Lars Buesing, and Peter W. Battaglia. 2020. Combining Q-Learning and Search with Amortized Value Estimates. In ICLR. [29] Zhipeng Huang and Yeye He. 2018. Auto-Detect: Data-Driven Error Detection in Tables. In SIGMOD. 1377–1392. [30] Andrea Iovine, Yunhan Huang, Melvin Monteiro, Mohamed Yakout, and Sedat Gokalp. 2025. Effective Product Schema Matching and Duplicate Detection with Large Language Models. (2025). https://www.amazon.science/publications/ ef fective-product-schema-matching-and-duplicate-detection-with-largelanguage-models [31] Bas Jansen and Felienne Hermans. 2018. The Use of Charts, Pivot Tables, and Array Formulas in Two Popular Spreadsheet Corpora. arXiv preprint arXiv:1808.10642 (2018). [32] Levente Kocsis and Csaba Szepesvári. 2006. Bandit Based Monte-Carlo Planning. In ECML. 282–293. [33] Farnaz Kohankhaki, Kiarash Aghakasiri, Hongming Zhang, Ting-Han Wei, Chao Gao, and Martin Müller. 2024. Monte Carlo Tree Search in the Presence of Transition Uncertainty. In AAAI, Vol. 38. 20151–20158.
[34] Christos Koutras, George Siachamis, Andra Ionescu, Kyriakos Psarakis, Jerry Brons, Marios Fragkoulis, Christoph Lofi, Angela Bonifati, and Asterios Katsifodimos. 2021. Valentine: Evaluating Matching Techniques for Dataset Discovery. In ICDE. 468–479. [35] Vladimir I Levenshtein. 1966. Binary Codes Capable of Correcting Deletions, Insertions, and Reversals. In Soviet Physics Doklady. 707–710. [36] Patrick Lewis, Ethan Perez, Aleksandra Piktus, Fabio Petroni, Vladimir Karpukhin, Naman Goyal, Heinrich Küttler, Mike Lewis, Wen-tau Yih, Tim Rocktäschel, et al. 2020. Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks. NeurIPS 33 (2020), 9459–9474. [37] Peng Li, Yeye He, Cong Yan, Yue Wang, and Surajit Chaudhuri. 2023. Auto-Tables: Synthesizing Multi-Step Transformations to Relationalize Tables without Using Examples. PVLDB 16, 11 (2023), 3391–3403. [38] Jianhua Lin. 2002. Divergence Measures Based on the Shannon Entropy. IEEE Transactions on Information Theory 37, 1 (2002), 145–151. [39] Xuanqing Liu, Runhui Wang, Yang Song, and Luyang Kong. 2024. GRAM: Generative Retrieval Augmented Matching of Data Schemas in the Context of Data Security. In SIGKDD. 5476–5486. [40] Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. Roberta: A Robustly Optimized BERT Pretraining Approach. arXiv preprint arXiv:1907.11692 (2019). [41] Yurong Liu, Eduardo H. M. Pena, Aécio Santos, Eden Wu, and Juliana Freire. 2025. Magneto: Combining Small and Large Language Models for Schema Matching. PVLDB 18, 8 (2025), 2681–2694. [42] David Loshin. 2010. Master Data Management. [43] Aman Madaan, Niket Tandon, Prakhar Gupta, Skyler Hallinan, Luyu Gao, Sarah Wiegreffe, Uri Alon, Nouha Dziri, Shrimai Prabhumoye, Yiming Yang, et al. 2023. Self-Refine: Iterative Refinement with Self-Feedback. NeurIPS 36 (2023), 46534–46594. [44] Jayant Madhavan, Philip A Bernstein, and Erhard Rahm. 2001. Generic Schema Matching with Cupid. In PVLDB, Vol. 1. 49–58. [45] Sabine Massmann, Salvatore Raunich, David Aumüller, Patrick Arnold, Erhard Rahm, et al. 2011. Evolution of the COMA match system. Ontology Matching 49 (2011), 49–60. [46] Sergi Nadal, Petar Jovanovic, Besim Bilalli, and Oscar Romero. 2022. Operationalizing and automating Data Governance. Journal of Big Data 9, 1 (2022), 117. [47] Palantir Technologies Inc. 2021. Trust in Data. Technical Report. Palantir Technologies Inc. https://www.palantir.com/assets/xrfr7uokpv1b/621jZEFhAkz eFjj6fndeW/f8e96ca8a08ee8afb50ad61ea3ff10a0/Trust_in_Data_Whitepaper__ US_.pdf [48] Palantir Technologies Inc. 2024. Palantir Privacy and Governance Whitepaper. Technical Report. Palantir Technologies Inc. https://www.palantir.com/assets/ xrfr7uokpv1b/6pey1VnYHULqeggNbPKqP0/9f577de3e3dfb9fc031bd75dc75265 17/Palantir_Privacy_and_Governance_Whitepaper__1_.pdf [49] Luigi Palopoli, Giorgio Terracina, Domenico Ursino, et al. 2000. The System DIKE: Towards the Semi-Automatic Synthesis of Cooperative Information Systems and Data Warehouses. In ADBIS-DASFAA. 108–117. [50] Marcel Parciak, Brecht Vandevoort, Frank Neven, Liesbet M Peeters, and Stijn Vansummeren. 2024. Schema Matching with Large Language Models: an Experimental Study. PVLDB 2150 (2024), 8097. [51] Neil Raden. 2023. Shadow IT Never Dies: Why Spreadsheets Are Still Running Your Business. https://diginomica.com/shadow-it-never-dies-why-spreadsheetsare-still-running-your-business. [52] Erhard Rahm and Philip A Bernstein. 2001. A Survey of Approaches to Automatic Schema Matching. the VLDB Journal 10, 4 (2001), 334–350. [53] Victor Sanh, Lysandre Debut, Julien Chaumond, and Thomas Wolf. 2019. DistilBERT, a distilled version of BERT: smaller, faster, cheaper and lighter. arXiv preprint arXiv:1910.01108 (2019). [54] Sebastian Schelter, Dustin Lange, Philipp Schmidt, Meltem Celikel, Felix Biessmann, and Andreas Grafberger. 2018. Automating Large-Scale Data Quality Verification. PVLDB 11, 12 (2018), 1781–1794. [55] Nabeel Seedat and Mihaela van der Schaar. 2024. Matchmaker: Self-Improving Large Language Model Programs for Schema Matching. In GenAI for Health: Potential, Trust and Policy Compliance. [56] Ola Shorinwa, Zhiting Mei, Justin Lidard, Allen Z Ren, and Anirudha Majumdar. 2025. A Survey on Uncertainty Quantification of Large Language Models: Taxonomy, Open Research Challenges, and Future Directions. Comput. Surveys (2025). [57] Roee Shraga, Avigdor Gal, and Haggai Roitman. 2020. ADnEV: Cross-domain Schema Matching Using Deep Similarity Matrix Adjustment and Evaluation. PVLDB 13, 9 (2020), 1401–1415. [58] Jianhong Tu, Ju Fan, Nan Tang, Peng Wang, Guoliang Li, Xiaoyong Du, Xiaofeng Jia, and Song Gao. 2023. Unicorn: A Unified Multi-tasking Model for Supporting Matching Tasks in Data Integration. PACMMOD 1, 1 (2023), 1–26. [59] Pei Wang and Yeye He. 2019. Uni-Detect: A Unified Approach to Automated Error Detection in Tables. In SIGMOD. 811–828.
Yunjun Gao, Chuangyu Ouyang, Congcong Ge, and Yifan Zhu
[60] Hadley Wickham. 2014. Tidy Data. Journal of Statistical Software 59 (2014), 1–23. [61] Mark D Wilkinson, Michel Dumontier, IJsbrand Jan Aalbersberg, Gabrielle Appleton, Myles Axton, Arie Baak, Niklas Blomberg, Jan-Willem Boiten, Luiz Bonino da Silva Santos, Philip E Bourne, et al. 2016. The FAIR Guiding Principles for scientific data management and stewardship. Scientific Data 3, 1 (2016), 1–9. [62] Kevin Wu, Jing Zhang, and Joyce C Ho. 2023. CONSchema: Schema Matching with Semantics and Constraints. In European Conference on Advances in Databases and Information Systems. 231–241. [63] Cong Yan and Yeye He. 2020. Auto-Suggest: Learning-to-Recommend Data Preparation Steps Using Data Science Notebooks. In SIGMOD. 1539–1554. [64] Junwen Yang, Yeye He, and Surajit Chaudhuri. 2021. Auto-Pipeline: Synthesizing Complex Data Pipelines By-Target Using Reinforcement Learning and Search. PVLDB 14, 11 (2021), 2563–2575. [65] Jing Zhang, Bonggun Shin, Jinho D Choi, and Joyce C Ho. 2021. SMAT: An Attention-based Deep Learning Solution to the Automation of Schema Matching. In ADBIS. 260–274. [66] Meihui Zhang, Marios Hadjieleftheriou, Beng Chin Ooi, Cecilia M Procopiuc, and Divesh Srivastava. 2011. Automatic Discovery of Attributes in Relational Databases. In SIGMOD. 109–120. [67] Yunjia Zhang, Avrilia Floratou, Joyce Cahoon, Subru Krishnan, Andreas C Müller, Dalitso Banda, Fotis Psallidas, and Jignesh M Patel. 2023. Schema Matching Using Pre-trained Language Models. In ICDE. 1558–1571. [68] Yu Zhang, Di Mei, Haozheng Luo, Chenwei Xu, and Richard Tzong-Han Tsai. 2025. SMUTF: Schema Matching Using Generative Tags and Hybrid Features. Information Systems (2025), 102570.
A
(B) Qwen3-Max
(C) DeepSeek R1
(D) ChatGPT 5.2 Thinking
(E) OpenAI o3
(F) Gemini 3 Pro
Figure 7: Unpivoted attributes identified by SOTA LLMs
[Turn 3] user: ### Identify the columns that can be unpivoted in a list of column names and with no explanation. ### Source column names: # # Div # Date # HS # AS # HST # AST # ### Description: # # Div: League division abbreviation (e.g., ‘E0’ for English Premier League) # Date: Match date (format: DD/MM/YY) # HS: Home Shots (total shots attempted by the home team) # AS: Away Shots (total shots attempted by the away team) # HST: Home Shots on Target (shots on goal by the home team) # AST: Away Shots on Target (shots on goal by the away team) # ### Target column names for reference: # # Div # Date # Metric # Value
Supplementary Case Study Result
This appendix provides supplementary qualitative outputs for the running example in Figure 7, together with the web-chat prompt transcript used to obtain them (we omit intermediate assistant acknowledgements for brevity.). [Turn 1] user: You are now an expert in data governance, first I’ll give you a definition, a requirement and some examples, and I need you to remember them for the following request. [Turn 2] user: Definition: Unpivot: Transforming multiple horizontally arranged numeric columns into vertical attribute-value pairs, preserving identifier columns, where original column names become values in a new attribute column and their corresponding data is consolidated into a unified value column. Requirement: Your task is to detect the attributes that can be unpivoted in the source table. A source table and a target table for reference will be provided. Your answer should be in JSON format and no explanation is needed. For example, if the attributes to be unpivoted is [A, B, C, D], your answer should be {“unpivot_columns” : [“A”, “B”, “C”, “D”] }. If no attribute is in the unpivot subset, answer with an empty unpivot_columns array, that is, {“unpivot_columns” : [ ] }. And remember that your JSON string should be pure text, do not put it in a code block. Example: For input attributes [Product, Jan_Sales, Feb_Sales], the corresponding output attribute is [Jan_Sales, Feb_Sales], and the output answer should be {“unpivot_columns” : [“Jan_Sales”, “Feb_Sales”] }. Example: For input attributes [Trade, Date, Quantity], the corresponding output attribute is [ ], because there is no attribute to be unpivoted, and the output answer should be {“unpivot_columns” : [ ] }.
(A) Qwen3-235B-A22B
B
Detailed Proofs for Convergence Analysis
Assumption 1 (𝜀-Randomized Expansion). During expansion, a new child is generated either by an LLM-guided refinement with probability 1 − 𝜀, or by a radius-1 random modification with probability 𝜀 > 0. The random modification assigns a strictly positive probability to every yet-unexpanded neighbor candidate of the current node, and duplicate generations are forbidden. Consequently, every feasible candidate in the finite search space will eventually be generated with reachability 1.
PiLLar: Matching for Pivot Table Schema via LLM-guided Monte-Carlo Tree Search
Lemma 1 (Exploration Completeness). Under Assumption 1, the randomized expansion mechanism is probabilistically complete: every feasible candidate in the finite search space will eventually be generated with probability 1. Sketch. Consider any candidate 𝑢 that has not yet been generated. Whenever its parent node is expanded, the random expansion branch is taken with probability 𝜀 > 0, and conditional on that branch, 𝑢 is selected with some fixed probability 𝑝𝑢 > 0. Since duplicate generations are forbidden, the probability that 𝑢 is never generated after 𝐾 such expansion trials is at most (1 −𝜀𝑝𝑢 ) 𝐾 , which converges to 0 as 𝐾 → ∞. Because the candidate space is finite, applying this argument to all remaining candidates ensures that each will be generated in finite time with probability 1. □ Assumption 2 (UCT Selection: Infinite Visits). Internal selection follows the UCT rule. As visit counts grow, every edge (in particular, the optimal child on each prefix of the witnessing path) is visited infinitely many times as 𝑡 → ∞. Strong vs. Weak Hits. A strong hit occurs when the optimal node 𝑣 ★ is first generated and its reward 𝑅(𝑣 ★) is backpropagated, or when a selection reaches the already-generated 𝑣 ★ and backpropagates 𝑅(𝑣 ★). A weak hit denotes a non-optimal expansion. Let the 𝑗-th block be the interval between two consecutive strong hits 𝜎 𝑗 −1 →𝜎 𝑗 and define the root endpoint difference of block 𝑗 ) of block 𝑗 ) 𝑊 𝑗 := 𝑄 𝑣(end − 𝑄 𝑣(start , 0 0
|𝑊 𝑗 | ≤ Ω.
(10)
(after 𝜎 𝑗 ) Let 𝐸 𝑗 := |𝑅(𝑠 ★) − 𝑄 𝑣0 | be the root error after the 𝑗-th strong
hit. Single Strong Hit Kernel. Writing the one-step (single strong hit) recursion layerwise as in Equation (2) gives, for 𝑑 = 0, . . . , 𝐻 − 2, ′ 𝑒𝑑′ ≤ 21 𝑒𝑑 + 12 𝑒𝑑+1 ,
𝑒𝐻′ = 0,
(11)
𝐻 ∑︁ 1 𝑘 𝑆 𝑒. 𝑘+1 2 𝑘=0
(12)
which compactly yields 𝑒 ′ ≤ 12 𝐼 − 21 𝑆
−1
𝑒=
In particular, for the root component 𝑒 0′ ≤
𝐻 ∑︁ 1 1 |𝑒 | ≤ 1 − ∥𝑒 ∥ ∞ =: 𝑐 𝐻 ∥𝑒 ∥ ∞, 𝑘 2𝐻 +1 2𝑘+1 𝑘=0
𝑐 𝐻 ∈ (0, 1).
(13) Block Recursion. Combining the single-hit contraction at the block boundary with the intra-block drift 𝑊 𝑗 , we obtain 𝑐 𝐻 = 1 − 2− (𝐻 +1) .
𝐸 𝑗 ≤ 𝑐 𝐻 𝐸 𝑗 −1 + 𝑐 𝐻 |𝑊 𝑗 |,
ISS Baseline. Iterating Equation (14) gives 𝑚 ∑︁ 𝐸𝑚 ≤ 𝑐 𝐻𝑚 𝐸 0 + 𝑐 𝐻 𝑐 𝐻𝑚−𝑟 |𝑊𝑟 |,
(14)
(15)
𝑟 =1
i.e., geometric stability modulo the disturbance sequence {|𝑊𝑟 |}. Why |𝑾𝒋 | → 0. (i) Bottom-up propagation starts at 𝑣 ★. Once the optimal leaf 𝑣 ★ is discovered, its value fixes at 𝑄 𝑣𝐻 = 𝑅(𝑣 ★). When its parent 𝑢 = 𝑣 𝐻 −1 is updated, the max–average backup 𝑄𝑢 ← 12 𝑄𝑢 + max{ 𝑅(𝑢), 𝑄 𝑣★ } (16)
contracts 𝑄𝑢 toward max{𝑅(𝑢), 𝑅(𝑣 ★)} = 𝑅(𝑣 ★). Hence repeated revisits along the optimal child drive 𝑄𝑢 →𝑅(𝑣 ★); once 𝑄𝑢 is close enough to 𝑅(𝑣 ★), UCT at 𝑣 𝐻 −2 increasingly favors 𝑢 as its optimal child, and the same argument repeats upward. (ii) UCT makes shallow weak selections asymptotically negligible. Under deterministic rewards, UCT at any internal node 𝑣𝑑 asymptotically favors its optimal child. Consequently, for each fixed depth 𝑑, the empirical ratio of selecting any strictly suboptimal child tends to zero as visits grow. On the witnessing path (𝑣 0, . . . , 𝑣 𝐻 −1 ), this implies that updates using the optimal child dominate in the limit at every shallow prefix, while weak selections occur only finitely many times or with vanishing frequency. 𝑗) (iii) Vanishing block-end drift. Within block 𝑗, let 𝑊 𝑗 := 𝑄 𝑣end( − 0 start( 𝑗 ) 𝑄 𝑣0 denote the raw root drift accumulated by weak updates before the block-ending strong hit. The subsequent strong hit applies the single-hit contraction to both the inherited error and this accumulated drift, so its contribution to the post-block error is exactly 𝑐 𝐻 |𝑊 𝑗 | in the recursion 𝐸 𝑗 ≤ 𝑐 𝐻 𝐸 𝑗 −1 + 𝑐 𝐻 |𝑊 𝑗 |.
(17)
By (i) and (ii), UCT makes shallow weak selections asymptotically negligible while bottom-up propagation repeatedly pulls ancestors toward 𝑅(𝑣 ★); hence the raw drift |𝑊 𝑗 | → 0. Therefore the contracted disturbance 𝑐 𝐻 |𝑊 𝑗 | also vanishes, yielding 𝐸 𝑗 → 0. Remark that because 𝑝 ★ ignores the children generated by LLM Self-Refine, it is conservative; in practice, convergence is typically much faster.
C Prompt Templates C.1 Initialization Prompt Role: system Content: You are now an expert in data governance, first I’ll give you a definition, a requirement and some examples, and I need you to remember them for the following request. Role: user Content: Definition: Unpivot: Transforming multiple horizontally arranged numeric columns into vertical attribute-value pairs, preserving identifier columns, where original column names become values in a new attribute column and their corresponding data is consolidated into a unified value column. Requirement: Your task is to detect the attributes that can be unpivoted in the source table. A source table and a target table for reference will be provided. Your answer should be in JSON format and no explanation is needed. For example, if the attributes to be unpivoted is [A, B, C, D], your answer should be {“unpivot_columns” : [“A”, “B”, “C”, “D”] }. If no attribute is in the unpivot subset, answer with an empty unpivot_columns array, that is, {“unpivot_columns” : [ ] }. And remember that your JSON string should be pure text, do not put it in a code block. Example: For input attributes [Product, Jan_Sales, Feb_Sales], the corresponding output attribute is [Jan_Sales, Feb_Sales], and the output answer
Yunjun Gao, Chuangyu Ouyang, Congcong Ge, and Yifan Zhu
should be {“unpivot_columns” : [“Jan_Sales”, “Feb_Sales”] }. Example: For input attributes [Trade, Date, Quantity], the corresponding output attribute is [ ], because there is no attribute to be unpivoted, and the output answer should be {“unpivot_columns” : [ ] }. Role: assistant Content: Got it! Please provide the source and target tables so I can determine the unpivot columns and provide the JSON output. Role: user Content: ### Identify the columns that can be unpivoted in a list of column names and with no explanation. ### Source column names: # # . . . source attributes # ### Description: # # . . . attribute descriptions # ### Target column names for reference: # # . . . target attributes
C.2
# ### Sample data from source table: # # . . . sample data from source table # ### Sample data from target table: # # . . . sample data from target table # ### Selected columns for unpivot: # # [. . . attributes]
C.3
Refine Prompt
Role: user Content: ### Refine your selection based on the feedback. If the feedback indicates that the selection is ideal, then you can remain the selection unchanged. Note that the suggested subset provided in the feedback may contain attributes that are not in the source table, you should not totally rely on it, but rather use it as a reference and strictly select from source attributes. ### Feedback: # # . . . feedback
Feedback Prompt
Role: system Content: You are now an expert in data governance and schema matching, and provides feedback on the quality of unpivot detection. Role: user Content: ### Evaluate the columns selected to be unpivoted from the source table. The selection aims to transfer the source table to the target table. You should focus on the transformation between the source and target table structure rather than the meaning of unpivot. The provided sample data may have been anonymised. Analyze this answer strictly and critically, point out every flaw for every possible imperfection about the selection. You only need to evaluate the selection of unpivot subset itself. Note that the selected subset is under loose limits, your task is to reduce the size of the subset if there exists redundant attributes in the subset. Remember the attributes should be selected from the source attributes, do not use names that do not exist. ### Source column names: # # . . . source attributes # ### Description: # # . . . attribute descriptions # ### Target column names for reference: # # . . . target attributes
D More Experiment Details D.1 Details of Baselines We compare PiLLar against the following representative approaches: • COMA 3.0 [45] 2 . COMA 3.0 is a multi-matcher schema matching framework that combines linguistic, structural, and instancebased matchers by an average-based similarity aggregation. It also employs advanced strategies such as fragment matching and filtered context to efficiently handle large-scale tasks. • DisB [66] 2 . DisB automatically clusters attributes into semantically coherent attributes using purely data-driven evidence. It clusters relational attributes into semantically coherent attributes via distribution similarity, and then refines them via intersection-based similarity and witness columns using correlation clustering. • GRAM [39]. GRAM is an LLM-based schema matching framework that integrates retrieval augmentation and prompt compression to accelerate inference while maintaining accuracy. It employs a Named Entity Recognition (NER) [19] filter and a Double-RAG [36] mechanism to dynamically select relevant target attributes and few-shot examples, forming a compact and adaptive prompting process for efficient attribute alignment. • NaiveP. Naive Pipeline (NaiveP) represents a straightforward execution pipeline. It performs unpivot attribute identification and schema matching independently without iterative refinement. In this setting, the LLM first generates an unpivot attribute set, 2We use the implementation available from the Valentine package [34].
PiLLar: Matching for Pivot Table Schema via LLM-guided Monte-Carlo Tree Search
AccE2E w/ desc Accper_attr. w/ desc 1.0
0.9
0.9
0.8 0.7
Details of Implementation
3We use the SentenceTransformers Python package with sentence-transformers/all-
distilroberta-v1 model in code implementation.
Model Size
0.6
30B
235B
235B
32B
Model Size
32B
Model Size
30B
(b) Football
Accuracy
Accuracy
1.0 0.9 0.8 0.7 0.6 0.5 0.4
30B
1.0 0.9 0.8 0.7 0.6 0.5 0.4
235B
32B
Model Size
30B
(d) Gene
Figure 8: Ablation study on description information random AccE2E random Accper_attr.
all AccE2E all Accper_attr.
1.0 0.6 0.4 0.2 0.0
235B
32B
Model Size
0.9 0.8 0.7 0.6
30B
(a) Adult 1.0 0.9 0.8 0.7 0.6 0.5 0.4
query AccE2E query Accper_attr.
1.0
0.8
Accuracy
Description Information. We conduct an ablation study on the use of description information. This information contains descriptions of the attributes of the two input tables which help LLM understand the semantics of these attributes. In practical data governance settings, description information is typically readily available, as it is recommended as a standard component of well-maintained schemas [8, 13, 25]. As shown in Figure 8, for large-scale models with 235B parameters, removing the description information leads to a clear decrease in accuracy. This indicates that description information is a useful supplementary information for LLM in matching for pivot table schema tasks, especially under circumstances that attributes contain abbreviations and terminologies. Yet, this effect is not obvious for small models due to their weaker semantic understanding capacity, which is insufficient to fully exploit the fine-grained information contained in the descriptions. This is especially evident on the large-scale Gene dataset: incorporating description substantially increases the prompt length and instead reduces accuracy. Generation of the Root Node. Figure 9 plots the performance of different generation methods of the unpivot attribute set for the root node of the Monte-Carlo search tree. The method we use in PiLLar is to query LLM and let it give an initial set. We compare it to two other methods: simply selecting all the source attributes and selecting random attributes. For the 235B model, querying LLM shows notable superiority in accuracy on all datasets. This is because using the strong semantic capability of LLM, the initial set is quite close to the correct one, and subsequent refinement can be more focused and effective. Initializing with all attributes
32B
0.7
(c) President
Accuracy
E Additional Experiments E.1 Ablation Study
235B
0.8
(a) Adult
Accuracy
We detail the hyper-parameters used in PiLLar as follows. We adopt Qwen3 provided by the Aliyun Model Studio API as the LLM model. Embeddings of attribute names are generated by the fine-tuned DistillRoBERTa [40, 53] 3 . The probability for the bounded stochastic policy is set to 𝜀 = 0.05. The constant 𝐶 for UCT selection is set to 2, which is a commonly adopted choice in MCTS-based systems [28, 33]. The maximum number of child nodes is set to 3 and the executed iterations count is set to 2. In each iteration, 5 threads are submitted and execute the selection and expansion in parallel. Unless explicitly specified, all hyper-parameters are set to their default values. All experiments are executed on macOS Sequoia 15.6 with 8 physical CPU cores and 16GB of memory. The programs are all implemented in Python.
Accuracy
1.0
0.6
D.2
AccE2E w/o desc Accper_attr. w/o desc
235B
32B
Model Size
30B
(b) Football 1.0
Accuracy
For GRAM, since we are not able to get access to its source code, we implement the competitor according to the design and the prompt provided in the paper. Different from the original implementation, we use the Qwen3 model instead of the original FLAN-T5 model for a fair evaluation of the performance.
Accuracy
and the corresponding tables are directly fed into the schema matching component without further adjustment.
0.8 0.6 0.4 0.2
235B
32B
Model Size
(c) President
30B
0.0
235B
32B
Model Size
30B
(d) Gene
Figure 9: Ablation study on the generation of root node does not remove the implausible attributes for the unpivot attribute set, leading to an unnecessarily large search space for subsequent refinement. Conversely, initializing with a random set often keeps implausible attributes and omits essential ones, which requires the refinement to simultaneously infer missing structure and correct mistakes, and thus significantly increases uncertainty and leads to unsatisfying results. For LLMs with fewer parameters, however, this advantage is not evident, and on some datasets, an initial set by querying LLM may lead to a worse result. This is because the weaker semantic capability of smaller models may generate an initial set with more errors. Considering the weaker Self-Refine capability, these errors may persist and lead to an unsatisfactory result. This limitation is most evident on the Gene dataset, where the scale of the dataset is large; in such cases, the initial set generated by small-scale models is often only marginally better, or even worse,
Yunjun Gao, Chuangyu Ouyang, Congcong Ge, and Yifan Zhu
AccE2E
Accper_attr.
Accper_attr.
1.0
1.0
0.9
0.9
0.9
0.85 0.80
Average LLMso
LLMwo LLMws
0.8 0.7
0.7
0.6
0.6
Average LLMso
LLMwo LLMws
(b) Football
Average LLMso
LLMwo LLMws
0.8 0.7 0.6
Q3L Q3M Q3S DV3 DR1 DRL QM OO3
(a) Adult 1.0 0.9 0.8 0.7 0.6 0.5 0.4
Q3L Q3M Q3S DV3 DR1 DRL QM OO3
Q3L Q3M Q3S DV3 DR1 DRL QM OO3
Model
Model
Accuracy
Accuracy
(a) Adult 1.0 0.9 0.8 0.7 0.6 0.5 0.4
0.8
(b) Football
Accuracy
0.90
Accuracy
1.0
0.95
Accuracy
1.00
Accuracy
Accuracy
AccE2E
1.0 0.9 0.8 0.7 0.6 0.5 0.4
Model
Q3L Q3M Q3S DV3 DR1 DRL QM OO3
Model
(c) President (c) President
(d) Gene
Figure 10: Performance of different similarity metrics
Figure 11: Performance of different models
than random initialization, resulting in substantially degraded accuracy. Moreover, on Gene, initializing with all attributes leads to an excessively long prompt that makes the 30B model unable to return a valid completion, so we cannot obtain meaningful results and thus report an accuracy of 0. In particular, the Adult dataset shows extremely low 𝐴𝑐𝑐 per_attr. with an initial set of all attributes. This is because its ground-truth unpivot attribute set is highly sparse (2 out of 19 attributes), making the starting point far from the correct set. Faced with such a noisy and confusing initial set, the 30B model struggles to refine effectively and tends to treat most attributes as unpivotable, resulting in notably lower accuracy.
of artificial rules. While this hybrid strategy is conceptually appealing, the experimental results suggest that LLM reasoning may interfere with consistent score aggregation rather than enhance it. Therefore, we choose the average method in PiLLar.
E.2
Effect of Similarity Metrics
In this experiment, we evaluate the effect of different similarity metrics. We implement four methods to calculate the similarity score between two attributes, namely average, LLM score only (LLMso ), LLM weight only (LLMwo ) and LLM score and weight (LLMsw ). Specifically, the average method calculates the similarity score by applying a simple average to the similarity scores from different dimensions; LLMso calculates the score by directly asks the LLM for a final score based on table information; LLMwo provides the scores to LLM and asks it to generate a final score by giving these scores different weight accordingly; LLMsw requires LLM to first generate a similarity score between the two attributes according to its own semantic understanding of the tables, and then weight all scores to obtain the final result. Figure 10 shows the accuracy of different similarity metrics on three datasets except the large-scale dataset Gene (issuing an LLM call for each attribute pair for large-scale datasets is unacceptable in terms of cost). Average performs the best on all the datasets, indicating that when it comes to numerical calculation and evaluation, LLM cannot provide a satisfying result. Rule-based similarity calculation is still a simple but useful method. Among the other three methods, LLMso performs the worst. This again demonstrates the limitation of LLM on similarity calculation tasks. LLMwo and LLMsw provide rule-based similarity scores to LLM, trying to make use of the semantic capability of LLM and the similarity capture capability
E.3
Effect of LLM variants
In this section we evaluate the effect of LLM variants. We run the experiment on 8 different LLMs, namely i) Qwen3-235B-A22B (Q3L), ii) Qwen3-32B (Q3M), iii) Qwen3-30B-A3B (Q3S), iv) DeepSeek-V3 (DV3), v) DeepSeek-R1 (DR1), vi) DeepSeek-R1-Distill-Llama-70b (DRL), vii) Qwen-Max-2025-01-25 (QM) and viii) OpenAI o3 (OO3). These models can be divided into 2 groups, the first 6 models are open-source models which we mainly compare considering the data privacy, and the last 2 models are closed-source models which we plot here as a reference and verify the effectiveness of PiLLar. As shown in Figure 11, all the models can generate satisfying results. Although the accuracy drops as the model parameters reduce, the decline is minor and remains within an acceptable range. This allows users to freely select the model according to the usage scenario. In addition, the performance of open-source models is comparable to, and even surpasses, that of closed-source models on some datasets. This indicates that even when choosing open-source models under the constraints of data privacy requirements, the performance of PiLLar will not deteriorate.