File size: 3,103 Bytes
ae7441b
54a699d
 
 
 
 
 
 
 
 
 
 
 
 
 
ae7441b
54a699d
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
---
license: other
license_name: academic-non-commercial
task_categories:
  - text-classification
  - tabular-regression
language:
  - en
tags:
  - sample-product-reviews
  - price-prediction
  - llm-engineering
  - e-commerce
size_categories:
  - 10K<n<100K
---

# Dataset Card for `items_raw_lite`

A curated, balanced subset of product metadata derived from the **Amazon Reviews 2023** dataset. This dataset is prepared for training and evaluating Large Language Models (LLMs) on price prediction and value estimation tasks.

---

## Dataset Summary

- **Total Datapoints:** 22,000 products
- **Splits:**
  - `train`: 20,000 items
  - `validation`: 1,000 items
  - `test`: 1,000 items
- **Price Range:** $0.50 – $999.49
- **Minimum Text Length:** 600 characters

---

## Dataset Structure

Each datapoint represents a product with cleaned metadata:

| Feature | Type | Description |
| :--- | :--- | :--- |
| `title` | `string` | The product title |
| `category` | `string` | Product category (e.g., `Appliances`, `Tools_and_Home_Improvement`, `Automotive`) |
| `price` | `float` | Price in USD (ground-truth target) |
| `full` | `string` | Cleansed concatenation of title, description, features, and specs (model input prompt) |
| `weight` | `float` | Item shipping weight normalized to pounds (if available, otherwise `0.0`) |

---

## Preprocessing & Curation

The raw metadata was scrubbed and balanced to produce high-signal inputs for LLM fine-tuning:

1. **Noise Removal:**
   - Uninformative metadata keys (such as `Part Number`, `Best Sellers Rank`, `Item model number`, `Batteries Required?`) were eliminated.
   - Long alphanumeric serial codes and model IDs were stripped with regex to prevent the model from memorizing product codes.
   - Excessive whitespace and formatting artifacts were normalized.

2. **Quality Filtering:**
   - Products without valid prices or outside the `$0.50 – $999.49` range were dropped.
   - Products with fewer than 600 characters of total descriptive text were excluded to ensure sufficient context for price estimation.

3. **Weighted Rebalancing:**
   - Real-world e-commerce data is heavily skewed toward cheap products ($5–$20).
   - Quadratic price weighting ($w \propto \text{normalized\_price}^2$) with category dampening was applied during sampling to ensure strong representation of higher-priced items.

---

## Quickstart Usage

```python
from datasets import load_dataset

# Load dataset from Hugging Face Hub
dataset = load_dataset("I4031/items_raw_lite")

# View a single example
print("Input Prompt:")
print(dataset["train"][0]["full"])
print(f"Target Price: ${dataset['train'][0]['price']}")
```

---

## Source & Attribution

Derived from the [Amazon-Reviews-2023 dataset](https://huggingface.co/datasets/McAuley-Lab/Amazon-Reviews-2023) curated by the McAuley Lab at UC San Diego.

---

## License & Terms of Use

- **Usage:** Strictly for **non-commercial academic research and educational purposes**.
- **Governing Policies:** Subject to Amazon's Conditions of Use and customer reviews guidelines. Commercial use is not permitted.