I am trying to find the longest common sequence of words in a list of sentences (more than two sentences).
Example:
list = ['commercial van for movers', 'partial van for movers', 'commercial van for moving' ]
sents = pd.Series(list)
In this answer, the solution works fine but it captures part words and it returns the follow:
'ial van for mov'
The output should be
'van for'
I couldn't find a way to modify it to return the desired output