MERC-SQL: Heterogeneous Execution Consensus with a Fixed Number of SQL Candidates
Applied Sciences · 15.11.2026 · 16 (22) · 11316
DOI: 10.3390/app162211316 ↗Kurz gefasst
Fachartikel in der Zeitschrift Applied Sciences, online erschienen am 15.11.2026. Verfasst von Yuanjie Wang und 4 weiteren Autor:innen. Der Volltext ist frei zugänglich (Open Access, CC BY 4.0). Gefördert von: National Natural Science Foundation of China, Yunnan Province Science and Technology Department.
Abstract (Originalsprache)
Large language models (LLMs) can improve text-to-structured query language (text-to-SQL) accuracy by generating several candidate queries and selecting an answer through agreement among their execution results. However, candidates from the same generator can share errors and reinforce the same incorrect result, leaving a correct candidate with insufficient support. We propose MERC-SQL, a heterogeneous execution-consensus method with a fixed pool of five candidates. The method constructs prompts from the question, provided evidence, and database schema; replaces one primary-generator candidate with an auxiliary-generator candidate; groups valid queries via normalized execution results; and selects a query using group support and a fixed candidate order. Using OmniSQL-7B and Qwen2.5-Coder-7B-Instruct, MERC-SQL achieves execution accuracies of 57.95% on 1534 BIRD development questions and 79.04% on 2147 Spider test questions under a unified single database-instance evaluation protocol. These results improve on five-candidate OmniSQL voting by 1.30 and 0.75 percentage points, respectively. On BIRD, correct candidate coverage increases from 67.01% to 70.14%. Under the evaluated five-candidate protocol, four OmniSQL candidates plus one Qwen candidate outperform the baseline of five OmniSQL candidates. Identical-pool comparisons and voting transition analyses characterize the selection behavior and changes in result-group support. The contributions of model replacement and decoding diversity have not been isolated; model heterogeneity is therefore a plausible contributing factor rather than an independently established cause of the improvement.
Förderung
- National Natural Science Foundation of China
- Yunnan Province Science and Technology Department
Zitieren
APA
Wang, Y., Feng, J., Wang, C., Tan, K., & Wang, Z. (2026). MERC-SQL: Heterogeneous Execution Consensus with a Fixed Number of SQL Candidates. Applied Sciences, 16(22), 11316. https://doi.org/10.3390/app162211316
Vancouver
Wang Y, Feng J, Wang C, Tan K, Wang Z. MERC-SQL: Heterogeneous Execution Consensus with a Fixed Number of SQL Candidates. Applied Sciences. 2026;16(22):11316. doi:10.3390/app162211316
BibTeX
@article{Wang2026,
author = {Wang, Yuanjie and Feng, Jie and Wang, Cuilin and Tan, Kaiwen and Wang, Zhenhan},
title = {MERC-SQL: Heterogeneous Execution Consensus with a Fixed Number of SQL Candidates},
journal = {Applied Sciences},
year = {2026},
volume = {16},
number = {22},
pages = {11316},
doi = {10.3390/app162211316}
}
EUVIMED