AgentSM: Semantic Memory for Agentic Text-to-SQL
On the map: LLM agents and tool use → Web, search, and research agents
Abstract (arXiv)
Recent advances in LLM-based Text-to-SQL have achieved remarkable gains on public benchmarks such as BIRD and Spider. Yet, these systems struggle to scale in realistic enterprise settings with large, complex schemas, diverse SQL dialects, and expensive multi-step reasoning. Emerging agentic approaches show potential for adaptive reasoning but often suffer from inefficiency and instability-repeating interactions with databases, producing inconsistent outputs, and occasionally failing to generate valid answers. To address these challenges, we introduce Agent Semantic Memory (AgentSM), an agentic framework for Text-to-SQL that builds and leverages interpretable semantic memory. Instead of relying on raw scratchpads or vector retrieval, AgentSM captures prior execution traces-or synthesizes curated ones-as structured programs that directly guide future reasoning. This design enables systematic reuse of reasoning paths, which allows agents to scale to larger schemas, more complex questions, and longer trajectories efficiently and reliably. Compared to state-of-the-art systems, AgentSM achieves higher efficiency by reducing average token usage and trajectory length by 25% and 35%, respectively, on the Spider 2.0 benchmark. It also improves execution accuracy, reaching a state-of-the-art accuracy of 44.8% on the Spider 2.0 Lite benchmark.
Key facts. Cited by 14 papers in the map (data through 13 Oct 2026). Placed in Web, search, and research agents, one of 16 directions in LLM agents and tool use. Builds on 19 of its 37 references that are in the map. First posted on arXiv 22 Jan 2026.
Builds on
19 of 37 references.
Closest ancestors · 4
Same direction, newest first
- 2025Supporting Our AI Overlords: Redesigning Data Systems to be Agent-First31 Aug
- 2025AgenticData: An Agentic Data Analytics System for Heterogeneous Data7 Aug
- 2025Agentic AI for Scientific Discovery: A Survey of Progress, Challenges, and Future Directions12 Mar
- 2025ReFoRCE: A Text-to-SQL Agent with Self-Refinement, Consensus Enforcement, and Column Exploration2 Feb
Other references · 15
- 2019Sentence-BERT: Sentence Embeddings using Siamese BERT-Networkscited by 9,107
- 2022ReAct: Synergizing Reasoning and Acting in Language Modelscited by 8,502
- 2023Reflexion: Language Agents with Verbal Reinforcement Learningcited by 4,156
- 2023MemGPT: Towards LLMs as Operating Systemscited by 1,354
- 2018Spider: A Large-Scale Human-Labeled Dataset for Complex and Cross-Domain Semantic Parsing and Text-to-SQL Taskcited by 1,133
- 2025Mem0: Building Production-Ready AI Agents with Scalable Long-Term Memorycited by 760
- 2023Can LLM Already Serve as A Database Interface? A BIg Bench for Large-Scale Database Grounded Text-to-SQLscited by 680
- 2023DIN-SQL: Decomposed In-Context Learning of Text-to-SQL with Self-Correctioncited by 472
- 2024Spider 2.0: Evaluating Language Models on Real-World Enterprise Text-to-SQL Workflowscited by 229
- 2025Agentic Reasoning: A Streamlined Framework for Enhancing LLM Reasoning with Agentic Toolscited by 106
- 2024MCS-SQL: Leveraging Multiple Prompts and Multiple-Choice Selection For Text-to-SQL Generationcited by 105
- 2025Collaborative Memory: Multi-User Memory Sharing in LLM Agents with Dynamic Access Controlcited by 60
Built on by
Citing papers per year: 2026: 14.
14 papers.
Sort:
By area:
- 2026Code as Agent Harnesscited by 44
- 2026Poison Once, Exploit Forever: Environment-Injected Memory Poisoning Attacks on Web Agentscited by 24
- 2026Governing Evolving Memory in LLM Agents: Risks, Mechanisms, and the Stability and Safety Governed Memory (SSGM) Frameworkcited by 18
- 2026Generating Expressive and Customizable Evals for Timeseries Data Analysis Agents with AgentFuelcited by 1
- 2026BAP-SQL: Budget-Aware Observation Planning for Agentic Text-to-SQLcited by 1
- 2026Hypergraph Enterprise Agentic Reasoner over Heterogeneous Business Systemscited by 0
- 2026Sophrosyne: Agentic Exploration of Relational Data Systems Needs Moderationcited by 0
- 2026Data Intelligence Agents: Interpreting, Modeling, and Querying Enterprise Data via Autonomous Coding Agentscited by 0
- 2026Memory-Orchestrated Semantic System (MOSS): An Auditable Agentic Memory Architecturecited by 0
- 2026Agentic Data Environmentscited by 0
- 2026From Test-Time Scaling to Reusable Memory: Measuring Crystallization in Text-to-SQLcited by 0
- 2026Beyond the Harness: End-to-End Optimization of Context Artifacts for Enterprise Text-to-SQLcited by 0
2 more
- 2026DualSQL: Text-to-SQL with Multi-Agent Reinforcement Learning16 Sep 2026
- 2026Beyond Context Windows: Persistent Discovery Context for Data-Centric Agents2 Sep 2026
- 2026Beyond the Harness: End-to-End Optimization of Context Artifacts for Enterprise Text-to-SQL24 Aug 2026
- 2026From Test-Time Scaling to Reusable Memory: Measuring Crystallization in Text-to-SQL7 Aug 2026
- 2026BAP-SQL: Budget-Aware Observation Planning for Agentic Text-to-SQL3 Aug 2026
- 2026Agentic Data Environments8 Jul 2026
- 2026Memory-Orchestrated Semantic System (MOSS): An Auditable Agentic Memory Architecture5 Jul 2026
- 2026Data Intelligence Agents: Interpreting, Modeling, and Querying Enterprise Data via Autonomous Coding Agents17 Jun 2026
- 2026Sophrosyne: Agentic Exploration of Relational Data Systems Needs Moderation29 May 2026
- 2026Code as Agent Harness18 May 2026
- 2026Hypergraph Enterprise Agentic Reasoner over Heterogeneous Business Systems14 May 2026
- 2026Poison Once, Exploit Forever: Environment-Injected Memory Poisoning Attacks on Web Agents3 Apr 2026
- 2026Code as Agent Harnesscited by 44
- 2026Poison Once, Exploit Forever: Environment-Injected Memory Poisoning Attacks on Web Agentscited by 24
- 2026Governing Evolving Memory in LLM Agents: Risks, Mechanisms, and the Stability and Safety Governed Memory (SSGM) Frameworkcited by 18
- 2026BAP-SQL: Budget-Aware Observation Planning for Agentic Text-to-SQLcited by 1
- 2026Sophrosyne: Agentic Exploration of Relational Data Systems Needs Moderationcited by 0
- 2026Data Intelligence Agents: Interpreting, Modeling, and Querying Enterprise Data via Autonomous Coding Agentscited by 0
- 2026Memory-Orchestrated Semantic System (MOSS): An Auditable Agentic Memory Architecturecited by 0
- 2026Agentic Data Environmentscited by 0
- 2026BAP-SQL: Budget-Aware Observation Planning for Agentic Text-to-SQL3 Aug 2026
- 2026Agentic Data Environments8 Jul 2026
- 2026Memory-Orchestrated Semantic System (MOSS): An Auditable Agentic Memory Architecture5 Jul 2026
- 2026Data Intelligence Agents: Interpreting, Modeling, and Querying Enterprise Data via Autonomous Coding Agents17 Jun 2026
- 2026Sophrosyne: Agentic Exploration of Relational Data Systems Needs Moderation29 May 2026
- 2026Code as Agent Harness18 May 2026
- 2026Poison Once, Exploit Forever: Environment-Injected Memory Poisoning Attacks on Web Agents3 Apr 2026
- 2026Governing Evolving Memory in LLM Agents: Risks, Mechanisms, and the Stability and Safety Governed Memory (SSGM) Framework12 Mar 2026
- 2026Generating Expressive and Customizable Evals for Timeseries Data Analysis Agents with AgentFuelcited by 1
- 2026Beyond the Harness: End-to-End Optimization of Context Artifacts for Enterprise Text-to-SQLcited by 0
- 2026Beyond Context Windows: Persistent Discovery Context for Data-Centric Agentscited by 0
- 2026DualSQL: Text-to-SQL with Multi-Agent Reinforcement Learningcited by 0
- 2026DualSQL: Text-to-SQL with Multi-Agent Reinforcement Learning16 Sep 2026
- 2026Beyond Context Windows: Persistent Discovery Context for Data-Centric Agents2 Sep 2026
- 2026Beyond the Harness: End-to-End Optimization of Context Artifacts for Enterprise Text-to-SQL24 Aug 2026
- 2026Generating Expressive and Customizable Evals for Timeseries Data Analysis Agents with AgentFuel12 Mar 2026
Similar, not cited
Close in wording, no citation either way
- 2026APEX-SQL: Talking to the data via Agentic Exploration for Text-to-SQL
- 2025AGENTIQL: An Agent-Inspired Multi-Expert Framework for Text-to-SQL Generation
- 2025BAPPA: Benchmarking Agents, Plans, and Pipelines for Automated Text-to-SQL Generation
- 2025From Queries to Insights: Agentic LLM Pipelines for Spatio-Temporal Text-to-SQL
- 2026Agentic-SQL Revisited: Autonomy-Based Taxonomy and Empirical Benchmark Analysis for LLM Text-to-SQL
- 2025RAISE: Reasoning Agent for Interactive SQL Exploration
- 2023MAC-SQL: A Multi-Agent Collaborative Framework for Text-to-SQL
- 2025MTSQL-R1: Towards Long-Horizon Multi-Turn Text-to-SQL via Agentic Training