-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add nlp.py and add_sentiment() function #81
Conversation
chatminer/nlp.py
Outdated
sentiment_pipeline = pipeline("sentiment-analysis", model=model_path) | ||
df["sentiment"] = [ | ||
sentiment["label"] for sentiment in sentiment_pipeline(list(df["message"])) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we make this more elegant and potentially improve performance by using pandas' apply?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Of course, see if it's the way you want it, now.
Thanks for the tip.
@bdfsaraiva is this PR in draft state for you or do you feel it should be merged already? |
Hi, @joweich, The package is yours, so the final decision will always be yours. What is missing (as you had suggested) is to add an example in the readme file. |
What are ideas that you have in mind for improvement? We could add these ideas to a new feature issue and merge this PR for now 👍🏼 |
What are you thinking for the documentation website? read the docs? Mkdocs? Other? I can help you with that 🤙🏼 |
@bdfsaraiva welcome to the main branch! Happy to have you as a contributor to this project! 🤗 I plan to go with readthedocs and sphinx as this is what I am used to. Will reach out once I get stuck! |
First blood of #60
Note: need transformers in setup.cfg