Datasets:
Tasks:
Token Classification
Modalities:
Text
Formats:
json
Sub-tasks:
named-entity-recognition
Languages:
English
Size:
10K - 100K
License:
Update README.md
Browse files
README.md
CHANGED
|
@@ -43,7 +43,9 @@ Each example includes: the NLQ, database identifier, a canonical dataset id, the
|
|
| 43 |
- `id` *(int)* — Local entity id (unique within the example)
|
| 44 |
- `type` *("table"|"column"|"value")*
|
| 45 |
- `value` *(str)* — Surface form from the DB schema or literal value
|
| 46 |
-
- `entity_to_token` *(List[Object])* —
|
|
|
|
|
|
|
| 47 |
- `dber_tags` *(List[str])* — **CoNLL-style IOB2** tags over `tokens`
|
| 48 |
|
| 49 |
---
|
|
@@ -70,7 +72,7 @@ Each example includes: the NLQ, database identifier, a canonical dataset id, the
|
|
| 70 |
|
| 71 |
---
|
| 72 |
|
| 73 |
-
## Example
|
| 74 |
```json
|
| 75 |
{
|
| 76 |
"question_id": 13692,
|
|
@@ -80,28 +82,37 @@ Each example includes: the NLQ, database identifier, a canonical dataset id, the
|
|
| 80 |
"SQL": "SELECT T1.first, T1.middle, T1.last FROM client AS T1 INNER JOIN events AS T2 ON T1.client_id = T2.Client_ID WHERE T1.year BETWEEN 1980 AND 2000 AND T1.sex = 'Male' AND T2.`Submitted via` = 'Referral'",
|
| 81 |
"tokens": ["Among","the","clients","born","between","1980","and","2000",",","list","the","name","of","male","clients","who","complained","through","referral","."],
|
| 82 |
"entities": [
|
| 83 |
-
{"id":0,"type":"column","value":"first"},
|
| 84 |
-
{"id":1,"type":"column","value":"middle"},
|
| 85 |
-
{"id":2,"type":"column","value":"last"},
|
| 86 |
-
{"id":3,"type":"table","value":"client"},
|
| 87 |
-
{"id":4,"type":"table","value":"events"},
|
| 88 |
-
{"id":5,"type":"column","value":"client_id"},
|
| 89 |
-
{"id":6,"type":"column","value":"year"},
|
| 90 |
-
{"id":7,"type":"value","value":"1980"},
|
| 91 |
-
{"id":8,"type":"value","value":"2000"},
|
| 92 |
-
{"id":9,"type":"column","value":"sex"}
|
| 93 |
-
{"id":10,"type":"value","value":"Male"},
|
| 94 |
-
{"id":11,"type":"column","value":"Submitted via"},
|
| 95 |
-
{"id":12,"type":"value","value":"Referral"}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 96 |
],
|
| 97 |
-
"entity_to_token": {"3":[2],"7":[5],"8":[7],"10":[13],"5":[14],"12":[18]},
|
| 98 |
"dber_tags": ["O","O","B-TABLE","O","O","B-VALUE","O","B-VALUE","O","O","O","O","O","B-VALUE","B-COLUMN","O","O","O","B-VALUE","O"]
|
| 99 |
}
|
| 100 |
```
|
| 101 |
|
| 102 |
---
|
| 103 |
|
| 104 |
-
##
|
| 105 |
|
| 106 |
### Load JSONL files
|
| 107 |
```python
|
|
@@ -125,7 +136,7 @@ ds = load_dataset("Voice49/dber")
|
|
| 125 |
|
| 126 |
---
|
| 127 |
|
| 128 |
-
## Annotation
|
| 129 |
- **Human**: collaborative web UI with schema and SQL visible during labeling.
|
| 130 |
- **Synthetic**: for each NLQ–SQL pair, generate candidate spans with Jaccard/Levenshtein, then solve a **non-overlapping ILP** to select spans maximizing similarity. Hyperparameters are validated on human data.
|
| 131 |
|
|
@@ -137,9 +148,6 @@ ds = load_dataset("Voice49/dber")
|
|
| 137 |
|
| 138 |
<!-- ---
|
| 139 |
|
| 140 |
-
## Licensing
|
| 141 |
-
- **License:** `other` (see the repository `LICENSE` for terms). Research use only unless otherwise permitted.
|
| 142 |
-
|
| 143 |
---
|
| 144 |
|
| 145 |
## Citation
|
|
@@ -157,5 +165,6 @@ If you use **DB-ER**, please cite:
|
|
| 157 |
|
| 158 |
---
|
| 159 |
|
| 160 |
-
## Release notes
|
|
|
|
| 161 |
- **v1.0:** Initial public release
|
|
|
|
| 43 |
- `id` *(int)* — Local entity id (unique within the example)
|
| 44 |
- `type` *("table"|"column"|"value")*
|
| 45 |
- `value` *(str)* — Surface form from the DB schema or literal value
|
| 46 |
+
- `entity_to_token` *(List[Object])* — Reverse index:
|
| 47 |
+
- `entity_id` *(int)* — Refers to an `entities[*].id`
|
| 48 |
+
- `token_idxs` *(List[int])* — Token indices composing that entity in `tokens`
|
| 49 |
- `dber_tags` *(List[str])* — **CoNLL-style IOB2** tags over `tokens`
|
| 50 |
|
| 51 |
---
|
|
|
|
| 72 |
|
| 73 |
---
|
| 74 |
|
| 75 |
+
## Example
|
| 76 |
```json
|
| 77 |
{
|
| 78 |
"question_id": 13692,
|
|
|
|
| 82 |
"SQL": "SELECT T1.first, T1.middle, T1.last FROM client AS T1 INNER JOIN events AS T2 ON T1.client_id = T2.Client_ID WHERE T1.year BETWEEN 1980 AND 2000 AND T1.sex = 'Male' AND T2.`Submitted via` = 'Referral'",
|
| 83 |
"tokens": ["Among","the","clients","born","between","1980","and","2000",",","list","the","name","of","male","clients","who","complained","through","referral","."],
|
| 84 |
"entities": [
|
| 85 |
+
{"id": 0, "type": "column", "value": "first"},
|
| 86 |
+
{"id": 1, "type": "column", "value": "middle"},
|
| 87 |
+
{"id": 2, "type": "column", "value": "last"},
|
| 88 |
+
{"id": 3, "type": "table", "value": "client"},
|
| 89 |
+
{"id": 4, "type": "table", "value": "events"},
|
| 90 |
+
{"id": 5, "type": "column", "value": "client_id"},
|
| 91 |
+
{"id": 6, "type": "column", "value": "year"},
|
| 92 |
+
{"id": 7, "type": "value", "value": "1980"},
|
| 93 |
+
{"id": 8, "type": "value", "value": "2000"},
|
| 94 |
+
{"id": 9, "type": "column", "value": "sex"},
|
| 95 |
+
{"id": 10, "type": "value", "value": "Male"},
|
| 96 |
+
{"id": 11, "type": "column", "value": "Submitted via"},
|
| 97 |
+
{"id": 12, "type": "value", "value": "Referral"}
|
| 98 |
+
]
|
| 99 |
+
"entity_to_token": [
|
| 100 |
+
...,
|
| 101 |
+
{"entity_id":3,"token_idxs":[2]},
|
| 102 |
+
{"entity_id":5,"token_idxs":[14]},
|
| 103 |
+
{"entity_id":7,"token_idxs":[5]},
|
| 104 |
+
{"entity_id":8,"token_idxs":[7]},
|
| 105 |
+
{"entity_id":10,"token_idxs":[13]},
|
| 106 |
+
{"entity_id":12,"token_idxs":[18]},
|
| 107 |
+
...
|
| 108 |
],
|
|
|
|
| 109 |
"dber_tags": ["O","O","B-TABLE","O","O","B-VALUE","O","B-VALUE","O","O","O","O","O","B-VALUE","B-COLUMN","O","O","O","B-VALUE","O"]
|
| 110 |
}
|
| 111 |
```
|
| 112 |
|
| 113 |
---
|
| 114 |
|
| 115 |
+
## Usage
|
| 116 |
|
| 117 |
### Load JSONL files
|
| 118 |
```python
|
|
|
|
| 136 |
|
| 137 |
---
|
| 138 |
|
| 139 |
+
## Annotation
|
| 140 |
- **Human**: collaborative web UI with schema and SQL visible during labeling.
|
| 141 |
- **Synthetic**: for each NLQ–SQL pair, generate candidate spans with Jaccard/Levenshtein, then solve a **non-overlapping ILP** to select spans maximizing similarity. Hyperparameters are validated on human data.
|
| 142 |
|
|
|
|
| 148 |
|
| 149 |
<!-- ---
|
| 150 |
|
|
|
|
|
|
|
|
|
|
| 151 |
---
|
| 152 |
|
| 153 |
## Citation
|
|
|
|
| 165 |
|
| 166 |
---
|
| 167 |
|
| 168 |
+
## Release notes
|
| 169 |
+
- **v1.1 (2025-08-26):** HF Data Viewer compatibility update
|
| 170 |
- **v1.0:** Initial public release
|