def METHOD_NAME(app, base_case_type, hashtag='#case/', source=None):
    builder = ParentCasePropertyBuilder.for_app(app, ['case_name'], include_parent_properties=False)
    related = builder.get_parent_type_map(None)
    map = builder.get_properties_by_case_type()
    if domain_has_privilege(app.domain, DATA_DICTIONARY):
        descriptions_dict = get_case_property_description_dict(app.domain)
    else:
        descriptions_dict = {}
    # Generate hierarchy of case types, represented as a list of lists of strings:
    # [[base_case_type], [parent_type1, parent_type2...], [grandparent_type1, grandparent_type2...]]
    # Vellum case management only supports three levels
    generation_names = ['case', 'parent', 'grandparent']
    generations = [[] for g in generation_names]
    def _add_ancestors(ctype, generation):
        if generation < len(generation_names):
            generations[generation].append(ctype)
            for parent in related.get(ctype, {}).get('parent', []):
                _add_ancestors(parent, generation + 1)
    _add_ancestors(base_case_type, 0)
    # Remove any duplicate types or empty generations
    generations = [set(g) for g in generations if len(g)]
    name_source = f" - {source}" if source else ""
    id_source = f":{slugify(source)}" if source else ""
    hashtag = f"{hashtag}{id_source}"
    def _name(i, ctypes):
        if i > 0:
            return "{} ({}){}".format(generation_names[i], " or ".join(ctypes), name_source)
        return f"{base_case_type}{name_source}"
    return [{
        "id": f"{generation_names[i]}{id_source}",
        "name": _name(i, ctypes),
        "structure": {
            p: {"description": descriptions_dict.get(t, {}).get(p, '')}
            for t in ctypes for p in map[t]},
        "related": {"parent": {
            "hashtag": hashtag + generation_names[i + 1],
            "subset": f"{generation_names[i + 1]}{id_source}",
            "key": "@case_id",
        }} if i < len(generations) - 1 else None,
    } for i, ctypes in enumerate(generations)]