BEN KONYI: Good afternoon, everyone.
So my name is Ben Konyi.
I'm an engineer on the Dart VM, and I also
do some work with the Flutter engine.
And I'm here to talk to you a little bit
about my 20% project, which is the Dart Reddit API Wrapper,
and how you can use it to moderate Reddit comments.
So basically, how the Dart Reddit API Wrapper
came to be was I was really looking for an excuse
to be on Reddit at work So here we are.
So this is my first Dart package and really my first--
[APPLAUSE]
So this is my first Dart package and really
my first major project written in Dart.
So DRAW is an open-source API wrapper for Reddit,
and it's written completely in Dart,
unlike some of the other Reddit wrappers for other languages.
And it's very similar to PRAW, if anyone here
has used PRAW with Python.
So it's a relatively simple interface
and makes it really easy to query Reddit and perform
actions.
And of course, it's open source on GitHub.
So as I'm sure many of you know, comments on the internet
are absolutely awful.
It's the main reason I don't go and look at YouTube comments.
So these are just some comments that I scraped from Reddit
today.
And these are the tame ones.
So as you can see, moderating is difficult,
and this is how I feel on a day-to-day basis moderating
a moderate-sized subreddit.
You're trying to plug holes constantly,
and you can never get them all.
So what I've done is, using my Reddit API DRAW,
I've also combined it with another Google
API called Perspective.
So for those of you who haven't heard of the Perspective API,
basically, you can take a comment, send it to this API,
and it will rate it on various criteria--
so how toxic a comment is, if it's coherent
or not, how inflammatory it is, if it's
an attack on the author, or if it's
an attack on the commenter.
So without further ado, I have a quick demo of how this works.
So we take a look here.
So first of all, as you can see, there's
really not much code to this--
maybe a combined total of 25 lines of code.
But if we give it a quick run here,
hopefully we'll see some comments coming in that--
come on.
There we go.
As you can see here, we just had a comment
that came in that was labeled as spam.
And here's another one, attack on commenter,
attack on commenter.
So these are all comments that exceeded a threshold
for these criteria.
And I've redacted the actual comments out of fear
that some of them might be a little bit not safe for work,
and I do value my job.
So this is all built using DRAW, my API,
and just hitting up the Perspective API endpoint.
And yeah, this will continue to go indefinitely
until, of course, stop it.
And basically, what I have here, what
I'm going to be using this for, for
my daily moderating activities, is to make active reports.
So I've commented out the line that actually sends reports
to the moderators because I don't want to spam moderators
on the funny subreddit.
But as you can see, it doesn't take
much to write a simple Reddit bot.
Yeah.
So thank you.
That's all I have.
[APPLAUSE]
So you can find me here on GitHub,
and I'm always looking for contributors.
So if anyone wants to help, I'd be more than
happy to take your help.
Thank you.
[APPLAUSE]