-
-
Notifications
You must be signed in to change notification settings - Fork 110
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
Response to #100daysofcode tweets with random gifs from Giphy #9
Comments
To tweet randomly or when someone mentions the bot? |
@Oxyrus I think it can be both. (e.g. if a user tweet day 1 of #100daysofcode - the bot can response with a gif with the keyword "thumbs up" or "applause") |
I'll happily take a look at this, I'm not sure if there will be any overlap with #5 |
I had a play around with this, I'm guessing there's a better way to serve the gif. I managed it with pulling the gif to ./src then attaching to the tweet.
|
@stephanie56 you need any help with this? |
If someone's till interested in this feature, than I am okay with it, otherwise I will be closing this issue in 1 week's time from today. |
@stephanie56, @amandeepmittal this is pretty long-standing now, is there any interest from anyone tagged in or can we share on Twitter for interest? the twitter-bot-playground is a good reference for anyone wishing to take it on... |
Let's share on Twitter. |
Hey @spences10 @amandeepmittal sorry I missed this notification. I haven't checked out the twitter bot code for a while and will look into it. At the same time I agree it's a good idea to share it on twitter anyway. |
If still need I would be happy to jump on this feature :). |
Mr @EQuimper it would be awesome if you could step in for this. I loved the super heros bot and it would be a great learning experience for us all if you could do this. Out of curiosity, do you know how you would go about doing it? |
@stephanie56 do you think you could come up with some more scenarios of the bot responding with a gif? So, there's:
It would be helpful for whoever is going to take this on to know the parameters of the feature. |
@spences10 I'm not quite sure yet, gonna take the time Sunday to check this out. |
@spences10 Can we also have a set of different gifs picked randomly for each tweet-back? This is an enhancement of the feature we are discussing but it will be prove to be interactive IMO. |
@amandeepmittal there needs to be some context for the gif IMO. Can't have the bot replying with random gifs to every reply, say it is replying to someone having a hard time and the sentiment bot tweets back with encouragement but also a gif of people laughing? |
I meant in the context of these three:
Not every reply. I am sorry if I was not clear before. |
Gotcha 👍 |
Hey folks! I was overthinking about it... I thought we will need to upload the gif first then tweet it - but it seems like we can display the gif on twitter timeline simply by sharing the gif link https://giphy.com/posts/how-to-share-giphy-gifs-on-twitter So my idea is: What do you think about this approach? I'm going to have some extra time this month to work on it. Let me know! |
Example:
Then we can append the gifUrl to a tweet that needs a gif. |
@stephanie56 I was checking the docs and the example you show that will work, but I think the best should be to have some gif url save somewhere inside an object who go with the type of message we want to sent. This way we know than this gif are those we want and also they don't do show bad stuff. When I use the giphy api sometime you get gif who are kind of offending etc. I think if we save url of those who we know are ok + they gonna be easier to filter if they are already below an object who match the message we want to send. This is just my opinion :) |
I agree! @EQuimper - it's easier to control the content if we pre-select those gifs. I'm imagining the object can structure like this: const gifReactions = {
thumbUp: ['https://gph.is/1R12OUI', 'https://gph.is/2tzoYc9', 'something else...'],
clap: ['https://gph.is/1R12OUI', 'https://gph.is/2tzoYc9', 'something else...'],
motivation: ['https://gph.is/1R12OUI', 'https://gph.is/2tzoYc9', 'something else...'],
} And we can write a helper function that is similar to the current random emoji module. Use it in the reply.js? What do you think @spences10 @amandeepmittal? |
yes, I can do it this weekend, I got some time :) @stephanie56 if everyone is ok with that. |
Ok, so we're going to have a predefined list of 'approved/curated' gifs to use, right? |
@spences10 yes this is ok for you ? I can do the logic, but I would like someone else to handle the choice of the gif :) |
@spences10 I see some code who can be delete and some structure improvement. I can do this in a pull request. You want it or you want to keep it like it ? I was thinking also about adding eslint. You have prettier who is really nice but prettier can help the dx :) |
Sure, put it in a PR @EQuimper, same with ESLint 👍 w/ regard to the curated list of gifs shall we have them in a For now maybe go with @stephanie56 suggestions? thumbUp: ['https://gph.is/1R12OUI', 'https://gph.is/2tzoYc9', 'something else...'],
clap: ['https://gph.is/1R12OUI', 'https://gph.is/2tzoYc9', 'something else...'],
motivation: ['https://gph.is/1R12OUI', 'https://gph.is/2tzoYc9', 'something else...'], ☝️ not sure on how the sentiment is going to work with the three categories... |
Thinking about it actually, it may be a better idea to have the images object somewhere other users can access and load new images to. If we add the files to |
@spences10 perfect I change some logic for the promote and add test. I mock also the bot so we can run test without pushing to twitter. Hope you gonna like it |
Json file would be better |
Maybe this will lead us in the right direction. const tweet = (keyword) => { |
The idea is to use giphy translate endpoint to tweet relevant gifs.
The text was updated successfully, but these errors were encountered: