MaskSQL: Safeguarding Privacy for LLM-Based Text-to-SQL via Abstraction
Not on the map. Why?
Abstract (arXiv)
Large language models (LLMs) have shown promising performance on tasks that require reasoning, such as text-to-SQL, code generation, and debugging. However, regulatory frameworks with strict privacy requirements constrain their integration into sensitive systems. State-of-the-art LLMs are also proprietary, costly, and resource-intensive, making local deployment impractical. Consequently, utilizing such LLMs often requires sharing data with third-party providers, raising privacy concerns and risking noncompliance with regulations. Although fine-tuned small language models (SLMs) can outperform LLMs on certain tasks and be deployed locally to mitigate privacy concerns, they underperform on more complex tasks such as text-to-SQL translation. In this work, we introduce MaskSQL, a text-to-SQL framework that utilizes abstraction as a privacy protection mechanism to mask sensitive information in LLM prompts. Unlike redaction, which removes content entirely, or generalization, which broadens tokens, abstraction retains essential information while discarding unnecessary details, striking an effective privacy-utility balance for the text-to-SQL task. Moreover, by providing mechanisms to control the privacy-utility tradeoff, MaskSQL facilitates adoption across a broader range of use cases. Our experimental results show that MaskSQL outperforms leading SLM-based text-to-SQL models and achieves performance approaching state-of-the-art LLM-based models, while preserving privacy.
Key facts. Cited by 3 papers in the map (data through 14 Oct 2026). Builds on 40 of its 60 references that are in the map. First posted on arXiv 27 Sep 2025.
Builds on
40 of 60 references.
References · 40
- 2024The Llama 3 Herd of Modelscited by 14,715
- 2019RoBERTa: A Robustly Optimized BERT Pretraining Approachcited by 13,372
- 2024Qwen2.5 Technical Reportcited by 4,942
- 2022Emergent Abilities of Large Language Modelscited by 2,512
- 2018Spider: A Large-Scale Human-Labeled Dataset for Complex and Cross-Domain Semantic Parsing and Text-to-SQL Taskcited by 1,139
- 2023Can LLM Already Serve as A Database Interface? A BIg Bench for Large-Scale Database Grounded Text-to-SQLscited by 688
- 2017Seq2SQL: Generating Structured Queries from Natural Language using Reinforcement Learningcited by 687
- 2023DIN-SQL: Decomposed In-Context Learning of Text-to-SQL with Self-Correctioncited by 477
- 2019RAT-SQL: Relation-Aware Schema Encoding and Linking for Text-to-SQL Parserscited by 424
- 2023Text-to-SQL Empowered by Large Language Models: A Benchmark Evaluationcited by 385
- 2023Specializing Smaller Language Models towards Multi-Step Reasoningcited by 251
- 2024Spider 2.0: Evaluating Language Models on Real-World Enterprise Text-to-SQL Workflowscited by 232
28 more
- 2023RESDSQL: Decoupling Schema Linking and Skeleton Parsing for Text-to-SQLcited by 195
- 2024CodeS: Towards Building Open-source Language Models for Text-to-SQLcited by 187
- 2017SQLNet: Generating Structured Queries From Natural Language Without Reinforcement Learningcited by 135
- 2018TypeSQL: Knowledge-based Type-Aware Neural Text-to-SQL Generationcited by 81
- 2021Differential Privacy for Text Analytics via Natural Text Sanitizationcited by 77
- 2023DP-Forward: Fine-tuning and Inference on Language Models with Differential Privacy in Forward Passcited by 67
- 2024A Survey on Employing Large Language Models for Text-to-SQL Taskscited by 67
- 2024The Death of Schema Linking? Text-to-SQL in the Age of Well-Reasoned Language Modelscited by 67
- 2022THE-X: Privacy-Preserving Transformer Inference with Homomorphic Encryptioncited by 57
- 2022A Survey on Text-to-SQL Parsing: Concepts, Methods, and Future Directionscited by 52
- 2022Recent Advances in Text-to-SQL: A Survey of What We Have and What We Expectcited by 47
- 2024DTS-SQL: Decomposed Text-to-SQL with Small Large Language Modelscited by 45
- 2023Hide and Seek (HaS): A Lightweight Framework for Prompt Privacy Protectioncited by 38
- 2022Differentially Private Decoding in Large Language Modelscited by 34
- 2023Split-and-Denoise: Protect large language model inference with local differential privacycited by 32
- 2024SQLBench: A Comprehensive Evaluation for Text-to-SQL Capabilities of Large Language Modelscited by 32
- 2024PrE-Text: Training Language Models on Private Federated Data in the Age of LLMscited by 29
- 2023DP-BART for Privatized Text Rewriting under Local Differential Privacycited by 28
- 2023Protecting User Privacy in Remote Conversational Systems: A Privacy-Preserving framework based on text sanitizationcited by 23
- 2024MSc-SQL: Multi-Sample Critiquing Small Language Models For Text-To-SQL Translationcited by 19
- 2022Natural Language Interfaces to Datacited by 14
- 2025Prεεmpt: Sanitizing Sensitive Prompts for LLMscited by 12
- 2025SLM-SQL: An Exploration of Small Language Models for Text-to-SQLcited by 10
- 2020Mention Extraction and Linking for SQL Query Generationcited by 9
- 2020Duoquest: A Dual-Specification System for Expressive SQL Queriescited by 7
- 2024Unmasking Database Vulnerabilities: Zero-Knowledge Schema Inference Attacks in Text-to-SQL Systemscited by 6
- 2025Revisiting Privacy, Utility, and Efficiency Trade-offs when Fine-Tuning Large Language Modelscited by 5
- 2025Exploring the Landscape of Text-to-SQL with Large Language Models: Progresses, Challenges and Opportunitiescited by 4
Built on by
Citing papers per year: 2026: 3.
3 papers.