Datasets:
"Lemmatized" column could be transformed to word-ordered VW
#5
by
Alvant
- opened
Could be useful for intra-text coherence computation, for example.
def f(x):
words = x.strip('[]').split(', ')
words = [w.strip("'") for w in words]
return ' '.join(words)
dataset._data['vw_text'] = (
dataset._data['id']
+ ' |@lemmatized '
+ dataset._data['lemmatized'].apply(f)
)