zephyrtronium / robot Goto Github PK
View Code? Open in Web Editor NEWRobot is a Twitch bot that learns from people and responds to them with things that it has learned.
License: GNU General Public License v3.0
Robot is a Twitch bot that learns from people and responds to them with things that it has learned.
License: GNU General Public License v3.0
Robot should thank people who gift her subs. Look for USERNOTICE with msg-id either "subgift" or "anonsubgift" and with msg-param-recipient-user-name equal to the bot's lowercase username or msg-param-recipient-id equal to the bot's userid if we get that at some point. Additional relevant docs: https://dev.twitch.tv/docs/irc/tags#usernotice-twitch-tags
Thank with a chat message, possibly a special set of emote options for doing so, maybe a big chunk of affection.
rexBlind
Extend respond
to make the bot generate messages starting with a given chain. E.g. have AYAYA AYAYA @RobotIsBroken
take (assuming prefix length 3) \x01 AYAYA AYAYA
as the working chain to generate the rest of a message, or AYAYA AYAYA AYAYA AYAYA AYAYA @RobotIsBroken
use AYAYA AYAYA AYAYA
with AYAYA AYAYA
as a fixed prefix. May require slightly reworking Walk.
Instead of splitting around spaces and having to reconstruct them, include the spaces in the tokens. That also allows us to do things like splitting around punctuation without introducing extra spaces.
Also, we probably don't need to keep the article rule anymore. Users very often try to generate with prompts ending with a/an/the and are surprised that it doesn't work.
Channels should each record how to send to them. Add a field containing a closure that implements it, including with global rate limiting.
Could not make it work, does this bot still work?
Optionally follow raids issued by the broadcaster and allow copypasta detection to trigger to join in with the raid message, then leave after a few minutes.
I've trying for a few days by now to install the bot on my computer but as for now i've been unsuccesful, i downloaded the master file and installed go (version: 1.15.2) and gcc (tdm64-1 10.3.0) but as soon as i get to the ''go get github.com/zephyrtronium/robot/'' step i have an issue, it gives a prompt that the ''go get'' function is depreciated and i should use the ''go install'' function instead, so i tried that and after numerous tries and even visiting their site to see what could've been going wrong i simply can't install it because it says it need the version of the repository and nothing that i tried works, i even tried to download an older version of go to see if i could use the go get command (hence why i'm using 1.15.2 rn), so having said that i would like to ask for some kind of help on how to properly install robot, sorry if this sounds awkwardly amateur but i would really appreciate if you could give me an answer.
Thanks for your attention, Diogo.
Random chance is ok, but a better approach would be a minimum time between messages followed by random chance.
The stdin loop never sees the recv channel close, so main blocks on the waitgroup forever.
The bot produced a slur by combining inputs typed out like t h i s
that were individually fine. Passing fully generated messages through a bad word filter would be a good step to prevent things like this. A straightforward place to add it would be in func badmatch
.
Add a command to describe the bot's mechanism in chat. Should respond to:
if generate a short then genreate another
TMI uses UUIDs for message IDs, but Discord doesn't. We don't depend on any of the semantics of UUIDs, so just use strings instead. This blocks #44.
Use USERSTATE tags to find the bot's own badges in a channel and determine whether it can send 20 or 100 PRIVMSGs per thirty seconds.
I am attempting to install this bot on my own personal server but I'm a bit lost on the instructions. I did some searching and saw that I needed to run go install github.com/zephyrtronium/robot/...@latest
instead of the existing command in the readme - that all works fine as it appears that the installation goes well (no errors in the logs). My issue happens when I try to execute robot -help
. For some reason
I'm only able to execute said function if I go deep into the go/bin
directory and run ./robot -help
that way - the problem here is that my config file is in the cloned robot repo - am I going to have to run things from inside the pkg directory every time? That seems like it's a bit counterintuitive, am I just missing something or are the instructions out of date?
I did a bit of research on my own and couldn't find an answer that seemed to make sense to my brain - is there a way a person could run the bot as a background process at all? I have it set up on a VPS and I would like to simply turn it on and let it run, is this at all possible via a flag or something similar?
Make web interfaces for bot management, separate for admin and owner. Both will eventually require Twitch OIDC, implying a redirect URI, but can be implemented without auth for LAN for now.
Owner dashboard: An owner connects to e.g. /o
. Webpage displays:
On mobile breakpoints, SQL and commands are also tabs.
Admin dashboard: An admin in #channel
connects to e.g. /m/channel
. Webpage displays a menu of options corresponding to admin commands which modify the database: forget, silence, set-prob, &c. when others are added. Selecting one displays a page appropriate to the command.
Robot should be able to connect to Discord servers and channels within them. This might involve making fake IRC messages out of Discord messages and vice-versa, or making an interface to capture both kinds. It might be possible to add Discord info directly into the chans table, or it might be necessary to add a new table.
After a couple refreshes:
couldn't obtain access token for TMI login: couldn't retrieve current token: couldn't load saved token: chacha20poly1305: message authentication failed
We need to be able to effectively forget a message before we actually record tuples from that message. #41 lays out that we should do this by recording deletes in bbolt. Don't forget to actually implement that.
This probably doesn't need to go into a database, as long as it's possible to update configs and particularly the list of channels while the bot is running.
Also be careful to avoid making this IRC-centric. What do we need for e.g. Discord?
Instead of deleting arbitrary tuples, record a trace of which message IDs actually produced a result, then delete all the messages in such a trace when needed.
The caller is the one who needs to arrange the "since" part because message times are encoded in user hashes. The time parameter doesn't add anything except possibly limiting result sets on the SQL brain, which we almost certainly aren't going to use anyway.
I think the autopurge happens quickly enough that Robot tries to unlearn the message before learning it. x/sync/singleflight might help to fix.
Some additional info about tuples will not only improve the suitability of Robot's data for research if that direction is pursued, but will also improve maintainability and consistency of the data.
While trying to reproduce #39, it came to light that the new SQL approach is overwhelmingly slow. We could revert to the old algorithm, but we switched off it for many reasons, especially that it's way too memory-hungry. I want to try a NoSQL/KV solution anyway, so let's just go for it.
The design is roughly as follows:
Based on past investigation into this idea, we probably want Badger for knowledge and bbolt for message deletes and lexicography.
Channels need to be able to enable and disable learning while retaining their config primarily for the purpose of not learning while broadcasters are offline.
may be an issue with https://gitlab.com/zephyrtronium/tmi
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.