improved sentence embed col name generation for pretrained pipes
@@ -317,7 +317,8 @@ def substitute_sent_embed_cols(c, cols, nlu_identifier=True):
Substitute col name for Word Embeddings. For Word_Embeddings, some name will be infered, and word_embedding_<name> will become the base name schema
"""
new_cols = {}
- new_base_name = f'sentence_embedding_{nlu_identifier}' # if nlu_identifier else f'document_{nlu_identifier}'
+ # new_base_name = f'sentence_embedding_{nlu_identifier}' # if nlu_identifier else f'document_{nlu_identifier}'
+ new_base_name = f'sentence_embedding_{nlu_identifier}' if 'sentence_embedding' not in nlu_identifier else nlu_identifier # if nlu_identifier else f'document_{nlu_identifier}'
for col in cols:
if '_results' in col:
continue # new_cols[col] = new_base_name can be omitted for word_embeddings, maps to the origin token, which will be in the tokenizer col anyways
