I have python list like below.
lst = ['paragraph 1','paragraph 2','paragraph 3']
I'm trying to make corpus of them with Pattern library - http://www.clips.ua.ac.be/pages/pattern-vector
As their example it should be like this ..
d1 = Document('paragraph 1')
d2 = Document('paragraph 2')
d3 = Document('paragraph 3')
corpus = Corpus(documents=[d1,d2,d3])
How can i make corpus liks this with my python list ?
lst = ['paragraph 1','paragraph 2','paragraph 3']
corpus = Corpus(documents=[Document(x) for x in lst])
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With