Exception has occurred: AttributeError // module 'pytextrank' has no attribute 'TextRank' #263
-
Hi, there: I am trying to implement the following code, as part of a large class called "Analysis". This class includes several large-texts analysis, as modeling text or key phrase extraction. I get the error "Exception has occurred: AttributeError // module 'pytextrank' has no attribute 'TextRank'". Is there any newer method available?
|
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
The way to use a If I understand your use case correctly, instead a typical use would be more like:
Does that work for what you needed? Note: depending on the language, you may need to adjust the list of |
Beta Was this translation helpful? Give feedback.
-
Great, I'm glad that helped :) We don't have a defined stopwords list in Spanish Usually the stopwords depend on each application in any case. There is another collection of common stopwords, in many languages -- if you want to adapt this? |
Beta Was this translation helpful? Give feedback.
Hi @isabel-martin-pineiro ,
The way to use a
spaCy
pipeline is different. In the code shown above, thetr = pytextrank.TextRank()
kind of pattern is not supported byspaCy
pipelines.If I understand your use case correctly, instead a typical use would be more like: