"use client"; import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card"; import { Badge } from "@/components/ui/badge"; import { getWordEvolution } from "@/lib/game-data"; import { TrendingUp, Plus, Minus, ArrowRight } from "lucide-react"; export function WordEvolutionTracker() { const evolution = getWordEvolution(); return ( Word Evolution & Optimization
Track how words were systematically replaced to maximize semantic distance using hillclimbing optimization.
{evolution.map((change, index) => (
Round {change.round}
Optimization step
{change.changes.filter(c => c.type === 'removed').length > 0 && (
Removed (Lower semantic distance)
{change.changes .filter(c => c.type === 'removed') .map((c) => ( {c.word} ))}
)} {change.changes.filter(c => c.type === 'added').length > 0 && (
Added (Higher semantic distance)
{change.changes .filter(c => c.type === 'added') .map((c) => ( {c.word} ))}
)}
This change increased the overall semantic distance between word pairs.
))} {evolution.length === 0 && (

No word changes detected in the progression.

)}

Hillclimbing Strategy

Each word replacement represents a “hill climbing” step where words with lower semantic distances to other words in the set were systematically replaced with words that had higher distances, improving the overall creativity score.

); }