from typing import Tuple
from typing import Dict
from typing import Union
import uuid
import random


def generate_record_info() -> Tuple[
    str,
    Dict[str, str],
    Dict[str, Union[int, float, str, list, dict]]
]:
    """ Generates unstructure information for testing general database 
        operations.

    Args:
        include_key (bool): Toggles if generated info should include a key
    Returns:
        Test key (str)
        Test Composite ID (dict)
        Test information (dict)
    """
    test_key = f"KEY-{uuid.uuid4()}"
    test_ids = {
        f'TEST_ID{i}-{uuid.uuid4()}': f"ID{i}-{uuid.uuid4()}"
        for i in range(random.randint(1, 5))
    }
    test_info = {
        'int_field': random.randint(-1000, 1000),
        'float_field': random.random(),
        'str_field': str(uuid.uuid4()),
        'list_field': [i for i in range(random.randint(1, 10))],
        'dict_field': {f'key_{i}':i for i in range(random.randint(1, 10))}
    }

    return test_key, test_ids, test_info