---
title: cdg-grocery-store-conversation-900
canonical_url: "https://www.modelscope.cn/datasets/cahlen/cdg-grocery-store-conversation-900"
md_url: "https://www.modelscope.cn/datasets/cahlen/cdg-grocery-store-conversation-900.md"
repository: cahlen/cdg-grocery-store-conversation-900
last_updated: 2026-02-07
license: unknown
storage_size: "521 KB"
downloads: 36
stars: 0
---

# cdg-grocery-store-conversation-900

> cdg-grocery-store-conversation-900 - cahlen 在 ModelScope 开源的数据集。Customer Carol & Employee Eddie: The best ways to reuse plastic containers from household items - Generated by Conversation Dataset Generator

cahlen/cdg-grocery-store-conversation-900 是 ModelScope 魔搭社区上的数据集，存储大小 521 KB，采用 unknown 许可。

- **Repository**: cahlen/cdg-grocery-store-conversation-900
- **License**: unknown
- **Storage size**: 521 KB
- **Downloads**: 36
- **Stars**: 0
- **Last updated**: 2026-02-07

Source: https://www.modelscope.cn/datasets/cahlen/cdg-grocery-store-conversation-900

---

# Customer Carol & Employee Eddie: The best ways to reuse plastic containers from household items - Generated by Conversation Dataset Generator

This dataset was generated using the Conversation Dataset Generator script available at [https://cahlen.github.io/conversation-dataset-generator/](https://cahlen.github.io/conversation-dataset-generator/).

## Generation Parameters

*   **Number of Conversations Requested:** 900
*   **Number of Conversations Successfully Generated:** 900
*   **Total Turns:** 4804
*   **Model ID:** `meta-llama/Meta-Llama-3-8B-Instruct`
*   **Generation Mode:** **Mode:** Fixed Persona with Variation (`--enable-variation`)
*   **Note:** Personas were fixed. Topic/Scenario/Style were varied for each example based on the initial context provided. Parameters below reflect the *last* successful example.
*   **Topic:** `The best ways to reuse plastic containers from household items`
*   **Scenario:** `At the grocery store checkout lane, Carol and Eddie strike up a conversation about repurposing containers while waiting in line`
*   **Style:** `Casual, humorous, spontaneous small talk`
*   **Included Points:** `None`

## Personas

**Customer Carol**
![Customer Carol](https://us.123rf.com/450wm/artinspiring/artinspiring1904/artinspiring190400939/122878387-woman-shopping-grocery-store-customer-with-shopping-cart-girl-on-the-big-sale-bying-food-in.jpg)
*Description:* `A friendly and curious shopper who often chats with strangers in the store. Loves comparing brands and asking for opinions. Can sometimes become upset, but is usually happy.` -> maps to `role: human`

**Employee Eddie**
![Employee Eddie](https://static.vecteezy.com/system/resources/previews/026/096/974/non_2x/male-employee-in-uniform-working-in-building-hypermarket-smiling-man-consultant-standing-near-shelf-in-supermarket-occupation-concept-illustration-vector.jpg)
*Description:* `A helpful but slightly sarcastic grocery store worker who's seen it all. Enjoys giving unexpected advice.` -> maps to `role: gpt`

## Usage

To use this dataset:

**1. Clone the repository:**
```bash
git lfs install
git clone https://huggingface.co/datasets/cahlen/cdg-grocery-store-conversation-900
```

**2. Load in Python:**
```python
from datasets import load_dataset

dataset = load_dataset("cahlen/cdg-grocery-store-conversation-900")

# Access the data (e.g., the training split)
print(dataset['train'][0])
```

## LoRA Training Example (Basic)

Below is a basic example of how you might use this dataset to fine-tune a small model like `google/gemma-2b-it` using LoRA with the PEFT and TRL libraries.

**Note:** This requires installing additional libraries: `pip install -U transformers datasets accelerate peft trl bitsandbytes torch`

```python
import torch
from datasets import load_dataset
from peft import LoraConfig, get_peft_model, prepare_model_for_kbit_training
from transformers import AutoModelForCausalLM, AutoTokenizer, TrainingArguments, BitsAndBytesConfig
from trl import SFTTrainer

# 1. Load the dataset
dataset_id = "cahlen/cdg-grocery-store-conversation-900"
dataset = load_dataset(dataset_id)

# 2. Load Base Model & Tokenizer (using a small model like Gemma 2B)
model_id = "google/gemma-2b-it"

# Quantization Config (optional, for efficiency)
quantization_config = BitsAndBytesConfig(
    load_in_4bit=True,
    bnb_4bit_quant_type="nf4",
    bnb_4bit_compute_dtype=torch.bfloat16 # or torch.float16
)

# Tokenizer
tokenizer = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
# Set padding token if necessary (Gemma's is <pad>)
if tokenizer.pad_token is None:
    tokenizer.pad_token = tokenizer.eos_token
    tokenizer.pad_token_id = tokenizer.eos_token_id

# Model
model = AutoModelForCausalLM.from_pretrained(
    model_id,
    quantization_config=quantization_config,
    device_map="auto", # Automatically place model shards
    trust_remote_code=True
)

# Prepare model for k-bit training if using quantization
model = prepare_model_for_kbit_training(model)

# 3. LoRA Configuration
lora_config = LoraConfig(
    r=8, # Rank
    lora_alpha=16,
    target_modules=["q_proj", "k_proj", "v_proj", "o_proj"], # Adjust based on model architecture
    lora_dropout=0.05,
    bias="none",
    task_type="CAUSAL_LM"
)

model = get_peft_model(model, lora_config)
model.print_trainable_parameters()

# 4. Training Arguments (minimal example)
training_args = TrainingArguments(
    output_dir="./lora-adapter-Customer Carol-Employee Eddie", # Choose a directory
    per_device_train_batch_size=1,
    gradient_accumulation_steps=4,
    learning_rate=2e-4,
    num_train_epochs=1, # Use 1 epoch for a quick demo
    logging_steps=10,
    save_steps=50, # Save adapter periodically
    fp16=False, # Use bf16 if available, otherwise fp16
    bf16=torch.cuda.is_bf16_supported(),
    optim="paged_adamw_8bit", # Use paged optimizer for efficiency
    report_to="none" # Disable wandb/tensorboard for simple example
)

# 5. Create SFTTrainer
trainer = SFTTrainer(
    model=model,
    train_dataset=dataset['train'], # Assumes 'train' split exists
    peft_config=lora_config,
    tokenizer=tokenizer,
    args=training_args,
    max_seq_length=512, # Adjust as needed
    dataset_text_field="content", # Use content field directly 
    packing=True, # Pack sequences for efficiency
)

# 6. Train
print("Starting LoRA training...")
trainer.train()

### 7. Save the LoRA adapter
# Use a fixed string for the example output directory
trainer.save_model("./lora-adapter-output-directory") 
print(f"LoRA adapter saved to ./lora-adapter-output-directory")
```

## Dataset Format (JSON Lines source)

Each row in the dataset contains the following keys:
- conversation_id: Unique identifier for the conversation
- turn_number: The sequential number of the turn within a conversation
- role: Either 'human' or 'gpt' indicating who is speaking
- speaker_name: The actual name of the speaker (e.g., '{final_persona1}' or '{final_persona2}')
- topic: The conversation topic
- scenario: The scenario in which the conversation takes place
- style: The stylistic direction for the conversation
- include_points: Specific points to include in the conversation
- content: The actual text content of the turn
