from typing import List


def _sampling_from_alias_wiki(
    alias: List[int],
    probs: List[float],
    random_val: float,
) -> int:
    """
    Draw sample from a non-uniform discrete distribution using Alias sampling.
    This implementation is aligned with the wiki description using 1 random number.

    :param alias: the alias list in range [0, n)
    :param probs: the pseudo-probability table
    :param random_val: a random floating point number in the range [0.0, 1.0)

    Return the picked index in the neighbor list as next node in the random walk path.
    """
    n = len(alias)
    pick = int(n * random_val)
    y = n * random_val - pick
    if y < probs[pick]:
        return pick
    else:
        return alias[pick]