from __future__ import annotations

import time


def _timestamp_ms() -> str:
    return str(int(time.time() * 1000))


def generate_experiment_key() -> str:
    """Generate a system-managed experiment key, e.g. EX1742601234567."""
    return f"EX{_timestamp_ms()}"


def generate_variant_key() -> str:
    """Generate a system-managed variant key, e.g. VA1742601234567."""
    return f"VA{_timestamp_ms()}"
