import random
import string


def gen_id(k=4):
    """
    Generates a random temporary id. Note that this is alpha-numeric.
    Alpha character ids are used to indicate that this ontology is not
    stored.

    :return:
    """
    return ''.join(random.sample(string.ascii_lowercase, k))