def create_reference_lookup_df(df):
    """Return a dataframe indexed by task_id for looking up the reference."""
    df = df[df['tag'] == 'reference']
    df.drop_duplicates(subset=['task_id'], inplace=True)
    df.set_index('task_id', verify_integrity=True, inplace=True)
    return df