def create_terms_index(es, index_name: str):
with open(mappings_terms_fn, "<STR_LIT:r>") as f:<EOL><INDENT>mappings_terms = yaml.load(f, Loader=yaml.SafeLoader)<EOL><DEDENT>try:<EOL><INDENT>es.indices.create(index=index_name, body=mappings_terms)<EOL><DEDENT>except Exception as e:<EOL><INDENT>log.error(f"<STR_LIT>")<EOL><DEDENT>
Create terms index