import csv
import random

def read_seeds(filename):
    seeds = {}
    with open(filename, newline='') as csvfile:
        reader = csv.DictReader(csvfile)
        for row in reader:
            category = row['Category']
            seed = row['Seed']
            if category not in seeds:
                seeds[category] = []
            seeds[category].append(seed)
    return seeds

def generate_prompt(seeds):
    prompt_parts = [random.choice(seeds[category]) for category in seeds]
    return f"A wallpaper with a {' '.join(prompt_parts)}."

# Reading seeds from a CSV file and generating a prompt
seeds = read_seeds('seeds.csv')
print(generate_prompt(seeds))
