code: def generate_process(pid: int) -> Process:
      return Process(
          pid=pid,
          command=f"Process {pid}",
          cpu_percent=random.random() * 20,
          memory=random.randint(10, 200) ** 3,
          start_time=datetime.datetime.now()
          - datetime.timedelta(seconds=random.randint(0, 500) ** 2),
          thread_count=random.randint(1, 32),
          state="running" if random.randint(0, 10) < 8 else "sleeping",
      )
  
file_path: rich/examples/top_lite_simulator.py
imports: import datetime
  import random
  import sys
  import time
  from dataclasses import dataclass
  from rich import box
  from rich.console import Console
  from rich.live import Live
  from rich.table import Table
label_desc: Use image node_id 1 for calling a global function with example usage: generate_process(pid) and returns: Process