File size: 2,754 Bytes
a37a1de
 
 
 
 
 
5e149c9
42d827c
01c10f2
73b9b88
5e149c9
 
01c10f2
73b9b88
a37a1de
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
---
tags:
- relbench
- relational-deep-learning
pretty_name: RelBench dbinfer datasets
configs:
- config_name: databases
  data_files:
  - split: eval
    path: STATS/databases.parquet
- config_name: tasks
  data_files:
  - split: eval
    path: STATS/tasks.parquet
---

# RelBench dbinfer datasets

This repository hosts the **dbinfer** family of relational datasets in the RelBench 3.0
manifest format, one subdirectory per dataset. The datasets originate from the
[4DBInfer benchmark](https://github.com/awslabs/multi-table-benchmark) (data version
`20240304`) and are exposed to RelBench via the `dbinfer-relbench-adapter` package. Their
labels are built externally and served as-is (every task has `kind: external`).

Each subdirectory is a self-describing RelBench dataset (`manifest.yaml` + plain `db/*.parquet`
+ `tasks/<task>/`); open its `schema.svg` for a zoomable entity-relationship diagram.

## Datasets

| dataset | domain | tasks |
|---|---|---|
| [`dbinfer-avs`](dbinfer-avs) | Acquire Valued Shoppers retail transactions | `repeater` |
| [`dbinfer-diginetica`](dbinfer-diginetica) | E-commerce browsing/purchase sessions (CIKM Cup 2016) | `ctr`, `purchase` |
| [`dbinfer-retailrocket`](dbinfer-retailrocket) | E-commerce visitor events | `cvr` |
| [`dbinfer-seznam`](dbinfer-seznam) | Seznam.cz advertising account charges | `charge`, `prepay` |
| [`dbinfer-amazon`](dbinfer-amazon) | Amazon product reviews | `rating`, `purchase`, `churn` |
| [`dbinfer-stackexchange`](dbinfer-stackexchange) | StackExchange community Q&A | `churn`, `upvote` |
| [`dbinfer-outbrain-small`](dbinfer-outbrain-small) | Outbrain content recommendation | `ctr` |

(Only datasets actually present as subdirectories are available; see each subdirectory's card
for details.)

## Loading

```python
import relbench
ds = relbench.load_dataset("dbinfer-diginetica")     # or any dataset above
task = relbench.load_task("dbinfer-diginetica", "ctr")
db = ds.get_db()
train = task.get_table("train")
```

See the RelBench
[CONTRIBUTING guide](https://github.com/snap-stanford/relbench/blob/main/CONTRIBUTING.md)
for the manifest layout.

## Citation

These datasets are from the 4DBInfer benchmark. If you use them, please cite:

```bibtex
@article{dbinfer,
  title={4DBInfer: A 4D Benchmarking Toolbox for Graph-Centric Predictive Modeling on Relational DBs},
  author={Wang, Minjie and Gan, Quan and Wipf, David and Cai, Zhenkun and Li, Ning and Tang, Jianheng and Zhang, Yanlin and Zhang, Zizhao and Mao, Zunyao and Song, Yakun and Wang, Yanbo and Li, Jiahang and Zhang, Han and Yang, Guang and Qin, Xiao and Lei, Chuan and Zhang, Muhan and Zhang, Weinan and Faloutsos, Christos and Zhang, Zheng},
  journal={arXiv preprint arXiv:2404.18209},
  year={2024}
}
```