Datasets:
Upload folder using huggingface_hub
Browse files- .gitattributes +2 -0
- README.md +121 -0
- datasys_trace.py +127 -0
- qwen3-32b-buckets.jsonl +3 -0
- trace.jsonl +3 -0
.gitattributes
CHANGED
|
@@ -58,3 +58,5 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 58 |
*.mp4 filter=lfs diff=lfs merge=lfs -text
|
| 59 |
*.webm filter=lfs diff=lfs merge=lfs -text
|
| 60 |
data.jsonl filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
|
|
|
| 58 |
*.mp4 filter=lfs diff=lfs merge=lfs -text
|
| 59 |
*.webm filter=lfs diff=lfs merge=lfs -text
|
| 60 |
data.jsonl filter=lfs diff=lfs merge=lfs -text
|
| 61 |
+
qwen3-32b-buckets.jsonl filter=lfs diff=lfs merge=lfs -text
|
| 62 |
+
trace.jsonl filter=lfs diff=lfs merge=lfs -text
|
README.md
ADDED
|
@@ -0,0 +1,121 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
pretty_name: DataSys LLM Serving Trace
|
| 3 |
+
license: other
|
| 4 |
+
language:
|
| 5 |
+
- en
|
| 6 |
+
tags:
|
| 7 |
+
- llm-serving
|
| 8 |
+
- inference
|
| 9 |
+
- request-trace
|
| 10 |
+
- token-reuse
|
| 11 |
+
- qwen3
|
| 12 |
+
size_categories:
|
| 13 |
+
- 10M<n<100M
|
| 14 |
+
configs:
|
| 15 |
+
- config_name: trace
|
| 16 |
+
data_files:
|
| 17 |
+
- split: train
|
| 18 |
+
path: trace.jsonl
|
| 19 |
+
- config_name: qwen3-32b-buckets
|
| 20 |
+
data_files:
|
| 21 |
+
- split: train
|
| 22 |
+
path: qwen3-32b-buckets.jsonl
|
| 23 |
+
---
|
| 24 |
+
|
| 25 |
+
# LLM Serving Trace
|
| 26 |
+
|
| 27 |
+
This dataset contains anonymized LLM serving request metadata prepared for
|
| 28 |
+
systems research on request patterns, token accounting, latency, and reusable
|
| 29 |
+
input-token buckets. It is packaged as newline-delimited JSON.
|
| 30 |
+
|
| 31 |
+
## Dataset Files
|
| 32 |
+
|
| 33 |
+
| File | Rows | Size | Description |
|
| 34 |
+
| --- | ---: | ---: | --- |
|
| 35 |
+
| `trace.jsonl` | 16,329,237 | 6.98 GB | Request-level trace records with timestamps, status, model name, reported token counts, and generation parameters. |
|
| 36 |
+
| `qwen3-32b-buckets.jsonl` | 3,994,435 | 4.62 GB | Qwen/Qwen3-32B subset augmented with token-bucket information for token reuse analysis. |
|
| 37 |
+
|
| 38 |
+
## Loading
|
| 39 |
+
|
| 40 |
+
```python
|
| 41 |
+
from datasets import load_dataset
|
| 42 |
+
|
| 43 |
+
trace = load_dataset("eth-easl/swissai-serving-trace", "trace", split="train")
|
| 44 |
+
qwen_buckets = load_dataset(
|
| 45 |
+
"eth-easl/swissai-serving-trace",
|
| 46 |
+
"qwen3-32b-buckets",
|
| 47 |
+
split="train",
|
| 48 |
+
)
|
| 49 |
+
```
|
| 50 |
+
|
| 51 |
+
For low-memory iteration, use streaming:
|
| 52 |
+
|
| 53 |
+
```python
|
| 54 |
+
from datasets import load_dataset
|
| 55 |
+
|
| 56 |
+
rows = load_dataset(
|
| 57 |
+
"eth-easl/swissai-serving-trace",
|
| 58 |
+
"qwen3-32b-buckets",
|
| 59 |
+
split="train",
|
| 60 |
+
streaming=True,
|
| 61 |
+
)
|
| 62 |
+
|
| 63 |
+
first_row = next(iter(rows))
|
| 64 |
+
```
|
| 65 |
+
|
| 66 |
+
## Schema
|
| 67 |
+
|
| 68 |
+
### `trace`
|
| 69 |
+
|
| 70 |
+
Each row contains:
|
| 71 |
+
|
| 72 |
+
| Field | Type | Description |
|
| 73 |
+
| --- | --- | --- |
|
| 74 |
+
| `id` | string | Request identifier. |
|
| 75 |
+
| `status` | string | Request status, for example `DEFAULT` or `ERROR`. |
|
| 76 |
+
| `created_at` | string | Request creation timestamp in ISO-8601 format. |
|
| 77 |
+
| `finished_at` | string | Request completion timestamp in ISO-8601 format. |
|
| 78 |
+
| `model` | string | Model identifier used for the request. |
|
| 79 |
+
| `model_parameters` | object | Generation parameters supplied with the request. |
|
| 80 |
+
| `reported_token_input` | int64 | Reported input-token count, or `-1` when unavailable. |
|
| 81 |
+
| `reported_token_output` | int64 | Reported output-token count, or `-1` when unavailable. |
|
| 82 |
+
|
| 83 |
+
`model_parameters` contains:
|
| 84 |
+
|
| 85 |
+
| Field | Type |
|
| 86 |
+
| --- | --- |
|
| 87 |
+
| `temperature` | float64 |
|
| 88 |
+
| `max_tokens` | string |
|
| 89 |
+
| `top_p` | float64 |
|
| 90 |
+
| `frequency_penalty` | float64 |
|
| 91 |
+
| `presence_penalty` | float64 |
|
| 92 |
+
| `seed` | int64 |
|
| 93 |
+
|
| 94 |
+
### `qwen3-32b-buckets`
|
| 95 |
+
|
| 96 |
+
This config contains the same request metadata fields as `trace`, plus:
|
| 97 |
+
|
| 98 |
+
| Field | Type | Description |
|
| 99 |
+
| --- | --- | --- |
|
| 100 |
+
| `token_count` | int64 | Number of Qwen/Qwen3-32B input tokens retained for the request. |
|
| 101 |
+
| `bucket_ids` | list[int64] | Deterministic token-bucket identifiers for the request input. Buckets were generated with 16-token buckets and right padding. |
|
| 102 |
+
|
| 103 |
+
## Intended Uses
|
| 104 |
+
|
| 105 |
+
This dataset is intended for research on LLM serving workloads, including:
|
| 106 |
+
|
| 107 |
+
- request arrival and completion patterns;
|
| 108 |
+
- latency and status analysis;
|
| 109 |
+
- input/output token accounting;
|
| 110 |
+
- cache locality and token reuse over bucketized input-token sequences.
|
| 111 |
+
|
| 112 |
+
The bucketized Qwen subset is useful when the raw token IDs should not be
|
| 113 |
+
distributed or when experiments only need stable identifiers for repeated token
|
| 114 |
+
chunks.
|
| 115 |
+
|
| 116 |
+
## Limitations
|
| 117 |
+
|
| 118 |
+
The trace records contain serving metadata rather than original prompts or model
|
| 119 |
+
outputs. Reported token counts may be unavailable for failed or incomplete
|
| 120 |
+
requests, represented as `-1`. The `bucket_ids` are model- and preprocessing-
|
| 121 |
+
specific and should not be interpreted as vocabulary token IDs.
|
datasys_trace.py
ADDED
|
@@ -0,0 +1,127 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"""Hugging Face Datasets loader for the DataSys LLM serving trace."""
|
| 2 |
+
|
| 3 |
+
from __future__ import annotations
|
| 4 |
+
|
| 5 |
+
import json
|
| 6 |
+
from pathlib import Path
|
| 7 |
+
|
| 8 |
+
import datasets
|
| 9 |
+
|
| 10 |
+
|
| 11 |
+
_DESCRIPTION = """\
|
| 12 |
+
An anonymized LLM serving request trace for systems research on request
|
| 13 |
+
patterns, token accounting, latency, and token-bucket reuse.
|
| 14 |
+
"""
|
| 15 |
+
|
| 16 |
+
_HOMEPAGE = ""
|
| 17 |
+
_LICENSE = "other"
|
| 18 |
+
|
| 19 |
+
|
| 20 |
+
class DataSysTraceConfig(datasets.BuilderConfig):
|
| 21 |
+
"""Builder config for one JSONL file in the trace package."""
|
| 22 |
+
|
| 23 |
+
def __init__(self, *, filename: str, features: datasets.Features, **kwargs):
|
| 24 |
+
super().__init__(**kwargs)
|
| 25 |
+
self.filename = filename
|
| 26 |
+
self.features = features
|
| 27 |
+
|
| 28 |
+
|
| 29 |
+
_MODEL_PARAMETERS = {
|
| 30 |
+
"temperature": datasets.Value("float64"),
|
| 31 |
+
"max_tokens": datasets.Value("string"),
|
| 32 |
+
"top_p": datasets.Value("float64"),
|
| 33 |
+
"frequency_penalty": datasets.Value("float64"),
|
| 34 |
+
"presence_penalty": datasets.Value("float64"),
|
| 35 |
+
"seed": datasets.Value("int64"),
|
| 36 |
+
}
|
| 37 |
+
|
| 38 |
+
_TRACE_FEATURES = datasets.Features(
|
| 39 |
+
{
|
| 40 |
+
"id": datasets.Value("string"),
|
| 41 |
+
"status": datasets.Value("string"),
|
| 42 |
+
"created_at": datasets.Value("string"),
|
| 43 |
+
"finished_at": datasets.Value("string"),
|
| 44 |
+
"model": datasets.Value("string"),
|
| 45 |
+
"model_parameters": _MODEL_PARAMETERS,
|
| 46 |
+
"reported_token_input": datasets.Value("int64"),
|
| 47 |
+
"reported_token_output": datasets.Value("int64"),
|
| 48 |
+
}
|
| 49 |
+
)
|
| 50 |
+
|
| 51 |
+
_QWEN_BUCKET_FEATURES = datasets.Features(
|
| 52 |
+
{
|
| 53 |
+
**_TRACE_FEATURES,
|
| 54 |
+
"token_count": datasets.Value("int64"),
|
| 55 |
+
"bucket_ids": datasets.Sequence(datasets.Value("int64")),
|
| 56 |
+
}
|
| 57 |
+
)
|
| 58 |
+
|
| 59 |
+
|
| 60 |
+
def _coerce_record(record: dict, include_buckets: bool) -> dict:
|
| 61 |
+
"""Fill optional nested keys so strict feature schemas stay stable."""
|
| 62 |
+
model_parameters = record.get("model_parameters") or {}
|
| 63 |
+
record["model_parameters"] = {
|
| 64 |
+
"temperature": model_parameters.get("temperature"),
|
| 65 |
+
"max_tokens": (
|
| 66 |
+
None
|
| 67 |
+
if model_parameters.get("max_tokens") is None
|
| 68 |
+
else str(model_parameters.get("max_tokens"))
|
| 69 |
+
),
|
| 70 |
+
"top_p": model_parameters.get("top_p"),
|
| 71 |
+
"frequency_penalty": model_parameters.get("frequency_penalty"),
|
| 72 |
+
"presence_penalty": model_parameters.get("presence_penalty"),
|
| 73 |
+
"seed": model_parameters.get("seed"),
|
| 74 |
+
}
|
| 75 |
+
if include_buckets:
|
| 76 |
+
record["bucket_ids"] = record.get("bucket_ids") or []
|
| 77 |
+
return record
|
| 78 |
+
|
| 79 |
+
|
| 80 |
+
class DataSysTrace(datasets.GeneratorBasedBuilder):
|
| 81 |
+
"""DataSys trace dataset builder."""
|
| 82 |
+
|
| 83 |
+
VERSION = datasets.Version("1.0.0")
|
| 84 |
+
DEFAULT_CONFIG_NAME = "trace"
|
| 85 |
+
|
| 86 |
+
BUILDER_CONFIGS = [
|
| 87 |
+
DataSysTraceConfig(
|
| 88 |
+
name="trace",
|
| 89 |
+
version=VERSION,
|
| 90 |
+
description="Full request-level trace metadata.",
|
| 91 |
+
filename="trace.jsonl",
|
| 92 |
+
features=_TRACE_FEATURES,
|
| 93 |
+
),
|
| 94 |
+
DataSysTraceConfig(
|
| 95 |
+
name="qwen3-32b-buckets",
|
| 96 |
+
version=VERSION,
|
| 97 |
+
description="Qwen/Qwen3-32B subset with token-bucket IDs.",
|
| 98 |
+
filename="qwen3-32b-buckets.jsonl",
|
| 99 |
+
features=_QWEN_BUCKET_FEATURES,
|
| 100 |
+
),
|
| 101 |
+
]
|
| 102 |
+
|
| 103 |
+
def _info(self) -> datasets.DatasetInfo:
|
| 104 |
+
return datasets.DatasetInfo(
|
| 105 |
+
description=_DESCRIPTION,
|
| 106 |
+
features=self.config.features,
|
| 107 |
+
homepage=_HOMEPAGE,
|
| 108 |
+
license=_LICENSE,
|
| 109 |
+
)
|
| 110 |
+
|
| 111 |
+
def _split_generators(self, dl_manager: datasets.DownloadManager):
|
| 112 |
+
data_file = dl_manager.download_and_extract(self.config.filename)
|
| 113 |
+
return [
|
| 114 |
+
datasets.SplitGenerator(
|
| 115 |
+
name=datasets.Split.TRAIN,
|
| 116 |
+
gen_kwargs={"filepath": data_file},
|
| 117 |
+
)
|
| 118 |
+
]
|
| 119 |
+
|
| 120 |
+
def _generate_examples(self, filepath: str):
|
| 121 |
+
include_buckets = "bucket_ids" in self.config.features
|
| 122 |
+
with Path(filepath).open("r", encoding="utf-8") as handle:
|
| 123 |
+
for idx, line in enumerate(handle):
|
| 124 |
+
line = line.strip()
|
| 125 |
+
if not line:
|
| 126 |
+
continue
|
| 127 |
+
yield idx, _coerce_record(json.loads(line), include_buckets)
|
qwen3-32b-buckets.jsonl
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:58b2265b98a10ec3bb2a0b455c520731c1296967906c7adc7b6d3710a013e402
|
| 3 |
+
size 4617817342
|
trace.jsonl
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:79c92fd40752e40a6cac1fc897491ea2f54f37939dc4dcc48c96ea06383c81b7
|
| 3 |
+
size 6981478609
|