mena-devs / bosta Goto Github PK
View Code? Open in Web Editor NEWPluggable Slack Bot for MENAdevs Slack community
License: Apache License 2.0
Pluggable Slack Bot for MENAdevs Slack community
License: Apache License 2.0
Enable log timestamps.
The Wolfram|Alpha Webservice API provides a web-based API allowing the computational and presentation capabilities of Wolfram|Alpha to be integrated into web, mobile, desktop, and enterprise applications.
The idea is to create a new Bosta command to tap into WA's offering:
@bosta wa `pi to 1000 digits`
@bosta wa `first 50 prime numbers`
@bosta wa `cos(100) + sin(10)`
Output the results received.
The snippet executor should strip out the \n
from the output before cropping it.
https://github.com/mena-devs/bosta-node/blob/master/plugins/snippets.js#L88
As expected negative karma has proven to be a feature that requires more delicate care beyond the basic implementation. As such, I'm proposing the implementation of the following abuse countermeasures:
-[1-5] @username
command to a certain configurable number per hour-2
such that [-1, -2, -3, -4, -5]
maps to the requester loosing [-2, -3, -4, -5, -6]
.This proposal is to be discussed here for the duration of 1 week
from the posting date, so that we can roll out the feature the soonest possible. After that we will roll out the common denominator.
Scenario 1: A user not caring about his/her own karma dropping below 0 could destroy the karma of another user for whatever reason and in stealth mode by sending karma commands to Bosta in DMs or in a non active channel.
Scenario 2: A user abusing negative karma to resolve a personal vendetta or in the anger spurring in a particular moment / heated debate.
Just so that we don't re-iterate the same ideas over and over again, please just upvote the ones you wish to see in production.
Would be cool if we were able to automate the process related to requesting more info about the invitee's profile from the inviting member through the invite alert message.
This could be triggered by having an additional button that we could call "Request more info". Example:
Suggested workflow:
Admin sees the invite alert on the admin channel and decides to request more info, Request info button is clicked.
Inviting slack member gets sent a template message by Bosta prompting the member to provide more information about the invitee. In the message Bosta mentions which admin requested to know more info about the invitee and asks the member to reach out to that admin with the information.
If we could detect which admin clicked on the request info button, then sending and mentioning who to reach out to would be pretty straightforward. My only concern is in case multiple admins click on that button multiple times, it would result in many DMs to the user. Which means, we will need to do a limit or delay between each message per member to prevent spamming. (Probably could be tracked in an in memmory DB like redis easily)
In all plugins taking commands, replace the white space with \s+
to cater for all white space characters.
The manual greeting command should only be allowed if the user being greeted isn't already in the list of recent_users to avoid sending duplicate greeting messages i.e. spam
I'd like to start an open discussion about a feature I've wanted to implement (the original idea was a standalone bot); karma tracking.
The purpose is to keep track of all those +1/+5 karma points that we "give" whenever someone says something smart, funny, etc. The purpose of that purpose is having fun and not building a well thought out system that cares about correctness or covering every single use case.
Here's what I thought of so far:
The bot can detect when karma is being given (regardless of how it's being detected: it could be message parsing looking for a specific pattern, it could be emoticon).
It will save that info in a format like: oday +5 ali on datetime
. It could be anything really.
An optional parameter can be supplied; message_id. I believe it's important to know why someone got 100 karma. It could be a hilarious pun or an existential statement.
Example scenario:
Oday: Ali is a great guy
Ali: +5 oday
bosta added +5 to oday's karma. I could give bosta more info: @bosta add .
The bot can be queried to know the karma-o-meter for any user.
Let's kickstart the discussion with:
Do we care about this feature at all? I personally want to have it to keep track of karma points that I always give (yeah, it's important. Why? fun thing to do.) I believe some mena-devs would love to have this feature as well (judging by yesterday's response).
List of features (first release and beyond).
Update the remaining plugins with the new message dispatching method 26bed04
Currently the list of users is cached in data/
which doesn't get updated when a new user joins. Either create an event to update the cache upon a user joining the channel or fetch user data from the web api.
As an admin Slack user, I want to flag a link, text or image, using a Twitter custom emoticon, on any Slack channel to be featured on MENAdevs' Twitter account.
Bosta detects the flagged resource and uploads it to Tilde platform via API.
For administrative purposes, retrieve the list of recently joined members
Replace all the calls for findUser() with the new version
Send a private message to the requester to notify them of an error and or success of the invitation
The RTM_EVENTS.CHANNEL_JOINED
isn't firing for some reason...
Idea still rough, but the gist of it is that Bosta stores and sends reminders about upcoming events of interest to the community.
<@bosta> Sunday 1/7/2017 - Code jam
<@bosta> Sunday 5/8/2017 - build night
...
Add the gif to README
An important feature for Bosta is to collect chat statistics that Slack isn't allowing us to access. This list of items to monitor can be expanded here, starting with:
Princess complained about the verbosity of Bosta's W|A answers. In order to fix this issue, there will be 2 commands as follows:
Less Verbose (Default):
@bosta wa `query`
Expanded Output:
@bosta wav `query`
Add an admin
plugin that provides users with the ability to:
Update to the newuser.js
plugin to automate the private message greeting
Add a custom transport to push logs into a slack channel. Use default transports to store logs into a file for debugging purposes
hnews plugin currently retrieves N top stories from the front-page. Upgrade the plugin to retrieve a specific story ID from the list.
In many places we're using these 2 libraries for HTTP(s) requests.
"request": "^2.88.2",
"request-promise": "^4.2.5",
These have been deprecated as per: request/request#3142
We need to switch to an alternative. Some options are: request/request#3143
@omaraboumrad has introduced node-fetch in some of the plugins, so if it suits our needs let's go with it.
I think it will be a cool idea to introduce games to bosta, so he will act as a game moderator.
in the early 2000s I remember on IRC there was a game managed by a bot called "word scrabble (or scramble?)"
the game's concept is simple yet it was really fun, and here's how it can be implemented:
many games can be introduced later (questions/answers, puzzles?,...), and if the idea took off and to avoid 'spamming' #general we can introduce channels for each game.
just a suggestion, and I thought to post it here.
The below fails:
@bosta invite (FirstName Last-Name) (email) (ML Expert / Software Engineer) (UNHCR)
Currently @bosta help
displays all the commands and their usages. However, it's necessary to get the information for a single command, so @bosta help <command>
needs to be implemented.
Add execute
button to the message sent to the #admins channel to execute a user request or deny it
Add sample commands in README as a reference
As a Slack user, I want to flag a link, text or image, using a bookmark custom emoticon, on any Slack channel to save to my profile on menadevs.com.
Bosta detects the bookmarked resource and uploads its content to Tilde platform via API.
Remove the max number of recent users from the plugin and add it to the configuration file.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.