File size: 2,084 Bytes
5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb 10d6f82 5280ebb |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 |
---
license: mit
language:
- en
base_model:
- Qwen/Qwen3-4B-Instruct-2507
tags:
- text-to-sql
- ambiguity
- reinforcement-learning
- grpo
---
# IntentRL-Ambig-Text2SQL-4B
This model is trained to handle **ambiguous text-to-SQL requests** by explicitly reasoning about user intent and producing multiple interpretation–answer pairs rather than silently committing to a single interpretation.
It is based on [Qwen/Qwen3-4B-Instruct-2507](https://huggingface.co/Qwen/Qwen3-4B-Instruct-2507), fine-tuned with **RL (DAPO/GRPO)** using a custom reward that encourages recall (covering more valid interpretations) for ambiguous questions and precision for unambiguous ones.
## Example
Given a schema and an ambiguous question:
> **Schema:** `CREATE TABLE Jobs (JobID INTEGER PRIMARY KEY, Min_Years INTEGER, Pref_Years INTEGER, Position TEXT, Salary REAL);`
>
> **Question:** Show the required experience for the best-paid role.
The model produces multiple interpretation–answer pairs:
1. **Minimum years of experience required** → `SELECT Min_Years ...`
2. **Preferred years of experience** → `SELECT Pref_Years ...`
3. **Both minimum and preferred years** → `SELECT Min_Years, Pref_Years ...`
## Paper
[Reasoning about Intent for Ambiguous Requests](https://arxiv.org/abs/2511.10453)
**Authors:** Irina Saparina, Mirella Lapata
## Training Details
- **Base model:** Qwen3-4B-Instruct-2507
- **Method:** RL with DAPO/GRPO and a custom recall/precision reward
- **Training data:** [Ambrosia](https://ambrosia-benchmark.github.io/) text-to-SQL benchmark
- **Ambiguous examples** are upsampled to balance training
## Code
Training and evaluation code: [https://github.com/saparina/intentRL](https://github.com/saparina/intentRL)
## Citation
```bibtex
@misc{saparina2025reasoningintentambiguousrequests,
title={Reasoning about Intent for Ambiguous Requests},
author={Irina Saparina and Mirella Lapata},
year={2025},
eprint={2511.10453},
archivePrefix={arXiv},
primaryClass={cs.CL},
url={https://arxiv.org/abs/2511.10453},
}
``` |