Datasets:
File size: 9,966 Bytes
c58221a a8aaa61 c1aaa1e a8aaa61 c58221a a8aaa61 |
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 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 |
---
license: apache-2.0
language:
- ca
- es
- en
task_categories:
- text-generation
tags:
- query-parsing
- structured-output
- json-generation
- multilingual
- catalan
- spanish
- R&D
- semantic-search
- AINA
- semantic-parsing
size_categories:
- n<1K
---
# IMPULS Query Parsing Dataset
A multilingual dataset for training and evaluating query parsing models that convert natural language queries into structured JSON for R&D project semantic search.
## Dataset Description
This dataset was created as part of the **IMPULS project** (AINA Challenge 2024), a collaboration between [SIRIS Academic](https://sirisacademic.com/) and [Generalitat de Catalunya](https://web.gencat.cat/) to build a multilingual semantic search system for R&D ecosystems.
The dataset contains natural language queries in **Catalan, Spanish, and English** paired with their structured JSON representations, designed for training models to:
- Extract semantic search terms from natural language
- Identify structured filters (funding programme, year, location, organization type)
- Detect query language and intent
### Supported Tasks
- **Query Parsing / Semantic Parsing**: Convert natural language to structured JSON
- **Information Extraction**: Extract entities and filters from queries
- **Multilingual NLU**: Understanding queries across CA/ES/EN
## Dataset Structure
### Data Splits
| Split | Examples | Description |
|-------|----------|-------------|
| `train` | 682 | Synthetic, template-generated queries |
| `test` | 100 | Real queries from domain experts |
### Schema
Each example contains a structured JSON with the following fields:
```json
{
"doc_type": "projects",
"filters": {
"programme": "Horizon 2020 | FEDER | SIFECAT | null",
"funding_level": "string | null",
"year": ">=2020 | 2015-2020 | null",
"location": "Catalunya | Spain | null",
"location_level": "region | province | country | null"
},
"organisations": [
{
"type": "university | research_center | hospital | company | null",
"name": "UPC | CSIC | null",
"location": "Barcelona | null",
"location_level": "province | region | null"
}
],
"semantic_query": "intel·ligència artificial salut",
"query_rewrite": "Human-readable interpretation of the query",
"meta": {
"id": "TRAIN_001",
"source": "synthetic | expert",
"lang": "CA | ES | EN",
"original_query": "The original natural language query",
"intent": "Discover | Quantify",
"style": "Concise | Verbose | Technical",
"components": ["Content", "Programme", "Year", "Location"],
"resolvability": "Direct | Adapted | Partial",
"notes": "Optional notes about interpretation"
}
}
```
### Field Descriptions
| Field | Description |
|-------|-------------|
| `doc_type` | Document type to search (always "projects") |
| `filters.programme` | Funding programme (H2020, Horizon Europe, FEDER, SIFECAT, etc.) |
| `filters.year` | Year filter (single year, range, or comparison like ">=2020") |
| `filters.location` | Geographic filter |
| `filters.location_level` | Geographic granularity (country, region, province) |
| `organisations` | List of organization filters with type, name, and location |
| `semantic_query` | Core thematic content for vector search |
| `query_rewrite` | Human-readable interpretation |
| `meta.original_query` | The original natural language query |
| `meta.lang` | Query language (CA/ES/EN) |
| `meta.intent` | Query intent (Discover/Quantify) |
| `meta.resolvability` | How well the query maps to the schema |
## Dataset Statistics
### Language Distribution
| Language | Training | Test |
|----------|----------|------|
| Catalan (CA) | ~33% | ~33% |
| Spanish (ES) | ~33% | ~21% |
| English (EN) | ~33% | ~46% |
### Intent Distribution
| Intent | Count | Percentage |
|--------|-------|------------|
| Discover | 600 | 88.0% |
| Quantify | 82 | 12.0% |
### Resolvability Distribution
| Type | Count | Percentage | Description |
|------|-------|------------|-------------|
| Direct | 529 | 77.6% | Fully mappable to schema |
| Adapted | 15 | 2.2% | Requires interpretation |
| Partial | 138 | 20.2% | Cannot fully express (ranking, aggregation) |
### Component Distribution
| Component | Frequency |
|-----------|-----------|
| Thematic content | 92.8% |
| Organization type | 39.9% |
| Organization location | 17.7% |
| Programme (funding) | 17.6% |
| Time expressions | 10.7% |
| Project location | 10.4% |
| Year (specific) | 7.8% |
| Organization name | 7.3% |
## Examples
### Example 1: Catalan Query (Discover)
**Original query:** `"Projectes on la UPC és coordinadora en l'àmbit de la ciberseguretat"`
```json
{
"doc_type": "projects",
"filters": {
"programme": null,
"funding_level": null,
"year": null,
"location": null,
"location_level": null
},
"organisations": [
{
"type": "university",
"name": "UPC",
"location": null,
"location_level": null
}
],
"semantic_query": "ciberseguretat",
"query_rewrite": "Llista de projectes de la UPC sobre ciberseguretat",
"meta": {
"id": "TRAIN_488",
"source": "synthetic",
"lang": "CA",
"original_query": "Projectes on la UPC és coordinadora en l'àmbit de la ciberseguretat",
"intent": "Discover",
"style": "Concise",
"components": ["Scope", "Organisation Name", "Content", "Role Qualifier"],
"resolvability": "Partial",
"notes": "No es pot filtrar pel rol de 'coordinadora'"
}
}
```
### Example 2: Spanish Query with Filters
**Original query:** `"proyectos de inteligencia artificial financiados por H2020 desde 2019"`
```json
{
"doc_type": "projects",
"filters": {
"programme": "Horizon 2020",
"funding_level": null,
"year": ">=2019",
"location": null,
"location_level": null
},
"organisations": [],
"semantic_query": "inteligencia artificial",
"query_rewrite": "Proyectos sobre inteligencia artificial del programa H2020 desde 2019",
"meta": {
"lang": "ES",
"intent": "Discover",
"resolvability": "Direct"
}
}
```
### Example 3: English Quantify Query
**Original query:** `"how many universities participated in quantum computing projects?"`
```json
{
"doc_type": "projects",
"filters": {
"programme": null,
"funding_level": null,
"year": null,
"location": null,
"location_level": null
},
"organisations": [
{
"type": "university",
"name": null,
"location": null,
"location_level": null
}
],
"semantic_query": "quantum computing",
"query_rewrite": "Count of universities participating in quantum computing projects",
"meta": {
"lang": "EN",
"intent": "Quantify",
"resolvability": "Partial",
"notes": "Aggregation (count) cannot be expressed in schema"
}
}
```
## Usage
### Loading the Dataset
```python
from datasets import load_dataset
dataset = load_dataset("SIRIS-Lab/impuls-query-parsing")
# Access splits
train_data = dataset["train"]
test_data = dataset["test"]
# Example
print(train_data[0]["meta"]["original_query"])
print(train_data[0]["semantic_query"])
```
### For Training with Transformers
```python
from datasets import load_dataset
dataset = load_dataset("SIRIS-Lab/impuls-query-parsing")
def format_for_training(example):
# Format as instruction-following
return {
"instruction": "Convert this query to structured JSON for R&D project search.",
"input": example["meta"]["original_query"],
"output": json.dumps(example, ensure_ascii=False, indent=2)
}
formatted = dataset.map(format_for_training)
```
## Data Collection
### Training Data
The training set was **synthetically generated** using:
- Controlled vocabularies (funding programmes, organization names, locations)
- Thematic keywords extracted from real R&D project titles and abstracts
- Domain-specific templates mirroring realistic user queries
- Balanced language distribution across Catalan, Spanish, and English
### Test Data
The test set contains **real queries from domain experts**:
- Collected from researchers and R&I policy analysts
- Elicited through structured questionnaires asking for typical information needs
- Manually annotated with gold-standard JSON structures
## Intended Use
This dataset is designed for:
- Training query parsing models for R&D project search systems
- Evaluating multilingual NLU capabilities for Catalan, Spanish, and English
- Benchmarking structured output generation from natural language
- Research on semantic parsing for specialized domains
## Limitations
- **Domain-specific**: Focused on R&D project search; may not generalize to other domains
- **Schema constraints**: Some query types (ranking, complex aggregations) cannot be fully represented
- **Synthetic training data**: Training examples are template-generated, which may limit diversity
- **Language balance**: Test set has more English queries than training distribution
## Citation
```bibtex
@misc{impuls-query-parsing-2024,
author = {SIRIS Academic},
title = {IMPULS Query Parsing Dataset: Multilingual Queries for R&D Semantic Search},
year = {2024},
publisher = {Hugging Face},
howpublished = {\url{https://huggingface.co/datasets/SIRIS-Lab/impuls-query-parsing}}
}
```
## Acknowledgments
- **[Barcelona Supercomputing Center (BSC)](https://www.bsc.es/)** - AINA project infrastructure
- **[Generalitat de Catalunya](https://web.gencat.cat/)** - Funding and RIS3-MCAT platform
- **[AINA Project](https://projecteaina.cat/)** - AINA Challenge 2024 framework
## License
Apache 2.0
## Links
- **Query Parser Model**: [SIRIS-Lab/impuls-salamandra-7b-query-parser](https://huggingface.co/SIRIS-Lab/impuls-salamandra-7b-query-parser)
- **Project Repository**: [github.com/sirisacademic/aina-impulse](https://github.com/sirisacademic/aina-impulse)
- **SIRIS Academic**: [sirisacademic.com](https://sirisacademic.com/)
|