andikrueger / TweetDeckSPFxFilter

Please do not hesitate to suggest changes to the filter for tweets related to SharePoint Framework. #SPFx
3 stars 2 forks source link

Filter updates and the 500 character limit #4

Open andikrueger opened 5 years ago

andikrueger commented 5 years ago

Twitter has a limit of 500 characters for the filters. How do we deal with the limit?

I just updated the filter file and with the latest great additions from the PR (#2 and #3) we would get a filter length of 594 characters.

#Office365Dev OR @OfficeDev OR from:OfficeDev OR #SPFx -#alien -#aliens -#art -#artist   -#artistreborn -#behindthescenes -#blood -#Elementary -#faceoff -#fake -#fx   -#fxmakeup -#gore -#gross -#halloween -#hollywood -#horror -#LED -#makeup -#makeupartist -#makeupeffects -#makeupfx -#movie -#moviemagic -#mua -#mufx   -#puppets -#pyro -#pyrotechnics -#sculpture -#sfx -#sfxmakeup -#SharpFX   -#specialeffects -#specialfx -#specialfxmakeup -#specialmakeupfx -#spfmakeup   -#spfxmakeup -#spfxmakeupartist -#spfxmua -#teeth -#thrillerthursday   -#tolinfx -#twd -#vfx -#werewolf -#wounds -from:webpart_o_matic

How should we evaluate additions to the filter and according to which criteria should we remove filter values?

@sebastienlevert and @estruyf I would appreciate your input very much.

sebastienlevert commented 5 years ago

I've been looking into it and nothing seems to help us, except the Premium APIs which are not used in Tweetdeck...

I was thinking the following... What about this would be automatically generated everyday based on a huge set of keywords. If a keyword has no result in the last 7 days (what is available through the API), we remove it... If it has a hit, we add it... That way it becomes a dynamic filter based on the current content of Twitter...

Now... That also means that we might have to update our TweetDeck query everyday... Are there any ways we could automate that?

andikrueger commented 5 years ago

Thank you so much for your feedback!

Today, I invested some time and thought about how we can solve the dilemma with the filter. Updating the filter on a daily basis would be great, but is not really user-friendly - although this might even work with Google Chrome extensions. Another option would be to automatically create a Twitter collection. This collection is public and anybody interested in SPFx could add this collection to their TweetDeck.

What do you think?

sebastienlevert commented 5 years ago

Can this be done dynamically? I think this is even a better way of doing it!

andikrueger commented 5 years ago

There is an API available to add tweets to the collection.

estruyf commented 5 years ago

A Twitter collection sounds like a great idea, but we need to have a way to make this dynamic. Otherwise it would be a lot of work.

andikrueger commented 5 years ago

I was thinking about about an azure function that pulls tweets with a minimal set of filters and filters these results according to our filter and pushes these these tweets to the collection... makes this any sense?

sebastienlevert commented 5 years ago

It makes sense... Maybe even Flow could be our winner... There is definitely something to do there!

andikrueger commented 5 years ago

Today, I did some research and I started to create a flow to filter tweets based on our rule set.

image

Currently I'm stuck with authenticating against twitter. The twitter connector only allows us to create a new tweet. There is no option to add a tweet to a collection. This means we will have to use the HTTP post action. Currently I'm having a hard time figuring out, how to authenticating my request.

andikrueger commented 5 years ago

Well, I now created a Twitter developer account, so that I can access the Twitter API through Microsoft Flow. During all these steps I stumbled over this restriction:

https://help.twitter.com/en/rules-and-policies/twitter-automation Automated adding to lists or collections: You may not add Twitter users to lists or add Tweets to collections in a bulk or indiscriminate manner. Adding a large number of unrelated users to lists is a violation of the Twitter Rules.

Looks like Twitter does not approve, what we are planning. What do you think and do you see any violation?

sebastienlevert commented 5 years ago

It seems okay to me. Those are not "random" tweets, but rather known and "hand-picked" tweets... That's why we are picking the right hashtags... Bending the boundaries but I think it's a faire use.