def subterps(so_far, reg_part):
    """Logic to build subterps, collections of interpretations for subparts,
    the empty subpart, or appendices"""
    elements = []
    found_subpart = False
    found_appendix = False
    for el in so_far:
        if el.get('is_subpart'):
            found_subpart = True
            index = el['index'] + ['Interp']
            elements.append({'label': el['label'], 'sub_label': el[
                'sub_label'], 'index': index, 'is_subterp': True,
                'section_id': '-'.join(index)})
        elif el.get('is_appendix') and not found_appendix:
            found_appendix = True
            index = el['index'][:1] + ['Appendices', 'Interp']
            elements.append({'label': 'Appendices', 'index': index,
                'is_subterp': True, 'section_id': '-'.join(index)})
    if not found_subpart:
        index = [reg_part, 'Subpart', 'Interp']
        elements.insert(0, {'label': 'Regulation Text', 'index': index,
            'is_subterp': True, 'section_id': '-'.join(index)})
    return elements
