from typing import List
from typing import Tuple


def percent_edges_in_other_edges(edge_list: List[Tuple[str, str]], edge_list2: List[Tuple[str, str]]) -> float:
    """Calculate what proportion of the first list of edges can be found in the second list.

    checks edges in both node orders to account for directed edges

    Parameters
    ----------
    edge_list:  List[Tuple[str, str]]
        list of query edges
    edge_list2:  List[Tuple[str, str]]
        list of edges to search in

    Returns
    -------
        proportion of first list that is in second list, accounting for order differences
    """
    count = 0
    for edge in edge_list:
        if (edge in edge_list2) or (edge[::-1] in edge_list2):
            count += 1
    return count / len(edge_list)