Anonymous asks:
What is your favorite memory of Bot-Depot?
Oh, that's a name I haven't heard in a long time! I have many fond memories of Bot-Depot but one immediately jumped to mind which I'll write about below.
For some context for others: Bot-Depot was a forum site about chatbots that was most active somewhere in the range of the year 2002-08 or so, during what (I call) the "first wave of chatbots" (it was the first wave I lived through, anyway) - there was an active community of botmasters writing chatbots for the likes of AOL Instant Messenger, MSN Messenger, Yahoo! Messenger, and similar apps around that time (also ICQ, IRC, and anything else we could connect a bot to). The "second wave" was when Facebook Messenger, Microsoft Bot Platform, and so on came and left around the year 2016 or so.
My favorite memory about Bot-Depot was in how collaborative and innovative everyone was there: several of us had our own open source chatbot projects, which we'd release on the forum for others to download and use, and we'd learn from each other's code and make better and bigger chatbot programs. Some of my old chatbots have their code available at https://github.com/aichaos/graveyard, with the Juggernaut and Leviathan bots being some of my biggest that were written at the height of the Bot-Depot craze. Many of those programs aren't very useful anymore, since all the instant messengers they connected to no longer exist, and hence I put them up on a git repo named "graveyard" for "where chatbots from 2004 go to die" to archive their code but not forget these projects.
Most of the bots on Bot-Depot were written in Perl, and one particular chatbot I found interesting (and learned a "mind blowing" trick I could apply to my own bots) was a program called Andromeda written by Eric256, because it laid down a really cool pattern for how we could better collaborate on "plugins" or "commands" for our bots.
Many of the Bot-Depot bots would use some kind of general reply engine (like my RiveScript), and they'd also have "commands" like you could type /weather
or /jokes
in a message and it would run some custom bit of Perl code to do something useful separately from the regular reply engine. Before Andromeda gave us a better idea how to manage these, commands were a little tedious to manage: we'd often put a /help
or /menu
command in our bots, where we'd manually write a list of commands to let the users know what's available, and if we added a new command we'd have to update our /help
command to mention it there.
Perl is a dynamic language that can import new Perl code at runtime, so we'd usually have a "commands" folder on disk, and the bot would look in that folder and require()
everything in there when it starts up, so adding a new command was as easy as dropping a new .pl
file in that folder; but if we forgot to update the /help
command, users wouldn't know about the new command. Most of the time, when you write a Perl module that you expect to be imported, you would end the module with a line of code like this:
1;
And that's because: in Perl when you write a statement like require "./commands/help.pl";
Perl would load that code and expect the final statement of that code to be something truthy; if you forgot the "1;" at the end, Perl would throw an error saying it couldn't import the module because it didn't end in a truthy statement. So me and many others thought of the "1;" as just standard required boilerplate that you always needed when you want to import Perl modules into your program.
What the Andromeda bot showed us, though, is that you can use other 'truthy' objects in place of the "1;" and the calling program can get the value out of require(). So, Andromeda set down a pattern of having "self-documenting commands" where your command script might look something like:
# The command function itself, e.g. for a "/random 100" command that would
# generate a random number between 0 and 100.
sub random {
my ($bot, $username, $message) = @_;
my $result = int(rand($message));
return "Your random number is: $result";
}
# Normally, the "1;" would go here so the script can be imported, but instead
# of the "1;" you could return a hash map that describes this command:
{
command => "/random",
usage => "/random [number]",
example => "/random 100",
description => "Pick a random number between 0 and the number you provide.",
author => "Kirsle",
};
The chatbot program, then, when it imports your folder full of commands, it would collect these self-documenting objects from the require statements, like
# A hash map of commands to their descriptions
my %commands = ();
# Load all the command scripts from disk
foreach my $filename (<./commands/*.pl>) {
my $info = require $filename;
# Store their descriptions related to the command itself
$commands{ $info->{'command'} } = $info;
}
And: now your /help
or /menu
command could be written to be dynamic, having it loop over all the loaded commands and automatically come up with the list of commands (with examples and descriptions) for the user. Then: to add a new command to your bot, all you do is drop the .pl file into the right folder and restart your bot and your /help
command automatically tells a user about the new command!
For an example: in my Leviathan bot I had a "guess my number" game in the commands folder: https://github.com/aichaos/graveyard/blob/master/Leviathan/commands/games/guess.pl
Or a fortune cookie command: https://github.com/aichaos/graveyard/blob/master/Leviathan/commands/funstuff/fortune.pl
After we saw Andromeda set the pattern for self-documenting commands like this, I applied it to my own bots; members on Bot-Depot would pick one bot program or another that they liked, and then the community around that program would write their own commands and put them up for download and users could easily download and drop the .pl file into the right folder and easily add the command to their own bots!
I think there was some effort to make a common interface for commands so they could be shared between types of chatbot programs, too; but this level of collaboration and innovation on Bot-Depot is something I've rarely seen anywhere else since then.
We had also gone on to apply that pattern to instant messenger interfaces and chatbot brains, as well - so, Leviathan had a "brains" folder which followed a similar pattern: it came with a lot of options for A.I. engine to power your bot's general responses with, including Chatbot::Alpha (the precursor to my RiveScript), Chatbot::Eliza (an implementation of the classic 1970s ELIZA bot), and a handful of other odds and ends - designed in a "pluggable", self-documenting way where somebody could contribute a new type of brain for Leviathan and users could just drop a .pl file into the right folder and use it immediately. Some of our bots had similar interfaces for the instant messengers (AIM, MSN, YMSG, etc.) - so if somebody wanted to add something new and esoteric, like a CyanChat client, they could do so in a way that it was easily shareable with other botmasters.
For more nostalgic reading, a long time ago I wrote a blog post about SmarterChild and other AOL chatbots from around this time. I was meaning to follow up with an article about MSN Messenger but had never gotten around to it!
Cardell asks:
So this is related to The Breath of the Wild save hacking. I play on the Yuzu emulator now. I just want the Mster Cycle earlyish and fresh vanilla game. Have found a save file editor but it doesn't let you add runes so I can't get the cycle. How did you add it to your save files on the blog? I'm sorry to bother you with something so insignificant but what I'm trying to do is so niche I can't find anything lol
I'm not sure about the Switch version but may have some ideas to get you started.
The savegame editor I used may be for the WiiU only and it provided a simple "Motorcycle" checkbox that adds the rune. If the Switch save editor doesn't do that, but does give you 'advanced' access to the various game flags, maybe setting the flag IsGet_Obj_Motorcycle
may do it - the flag is set in my WiiU save files. Or otherwise browse and search around in the flags - there are a lot of them that control all sorts of features in the game, and sometimes they have uintuitive names (IsGet_Obj_RemoteBomb does the bomb rune, IsGet_Obj_StopTimer is the stasis rune, IsGet_Obj_Magnetglove is the magnesis rune, IsGet_Obj_IceMaker for cryonis).
There is also a caveat around runes at all when you're talking very early game: you can hack all these runes in to your profile, but you can't use them in-game until you have picked up a rune yourself. The D-pad shortcut doesn't work otherwise. What I did for my WiiU save files was to:
With the Camera rune added, the D-pad shortcut unlocks and I can now use all of the runes, including the motorcycle, despite never entering one of the Plateau tutorial shrines. (Doing those tutorial shrines would also unlock your rune ability - you just need a rune added "normally" for the tutorial to advance enough to let you use them!)
Good luck!
Is Zenmsg a virus? asks:
It only opened a command box, and nothing else happened. Is this a virus?
No, it's not. 😊 ZenMsg is a command-line program (so it opens your DOS prompt if double-clicked on), but it requires command-line options to tell it what to do. When run without any options, it prints its usage information to the terminal and then exits; so when double-clicked on, your DOS prompt appeared and then closed because ZenMsg exited.
You'll want to run it from a PowerShell or Command Prompt window first (so that the console sticks around after the program exits), and you can see it just prints its usage information:
C:\Users\Noah\Downloads> ZenMsg.exe
Usage:
ZenMsg [--error --alert --info --question]
[--title] [--text] [--button label]
[--icon name_or_file]
[--default label] [--cancel label]
[--disabled n]
[--version] [--help]
Use the "--help" option for more help.
(and it goes into detail on all the options)
If you call it with ZenMsg --help
it goes into full detail (the same documentation that's in the ZenMsg.html page the program ships with), including all the names of built-in icons. Every icon available on the Error Message Generator is built in to ZenMsg, and you can point it to a custom image on disk to use your own icon:
BUILT-IN ICONS
Here is a list of all the built-in icons that you can use by name:
aim_guy - Blue AIM guy icon
aol_icon - Blue AOL icon
attention - Yellow triangle around an exclamation mark
bomb - Round black bomb icon
bomb_dynamite - Icon of a bundle of dynamite and a trigger
bomb_grenade - Icon of a grenade
bulb - White light bulb
butterfly - MSN Butterfly icon
cake - Slice of pink cake on a blue plate
circularsaw - Icon of a handheld circular saw
control_panel - Generic control panel icon
cow - Icon of a cow and a computer tower
defrag - Disk Defragmenter icon
disk_blue - Generic blue floppy disk icon
disk_blue_label - Blue floppy disk with a label
disk_orange - Generic orange floppy disk
disk_red - Generic red floppy disk
disk_red_label - Red floppy disk with a label
disk_skull - Gray floppy disk with skull and crossbones
disk_yellow - Generic yellow floppy disk
error - Old-school X in a red circle error dialog icon
error2 - Modern, shiny incarnation of an error dialog icon
error3 - Beveled error dialog icon (like Windows XP)
error4 - A red X icon
file_cabinet - File cabinet icon
find - Find Files icon
floppy_drive - Generic floppy drive icon
fortunecookie - Icon of a fortune cookie
garbage_empty - Empty garbage can
garbage_full - Bloated garabage can
gun - Icon of a revolver pistol
hammer - Icon of a hammer
heart - Icon of a shiny red heart
help - Old-school Windows Help icon
hub - Icon of a hardware hub of sorts (networking?)
hwinfo - Icon of a PCI device with blue "i" bubble above it
ie5 - Icon of old-school Internet Explorer
info - Speech bubble with an "i" inside
keys - Generic icon of keys
keys2 - Old Windows key icon
keys3 - Generic key and padlock icon
labtec - Icon of a server or something?
mac - Striped colorful Apple logo
mail - Generic icon of an envelope
mail_deleted - Same envelope with a red X emblem in the corner.
mailbox - Mailbox with the flag down
mouth - Smiling mouth icon
msdos - MS-DOS icon
mycomputer - A "My Computer" icon
mycomputer2 - A "My Computer" icon
mycomputer3 - A "My Computer" icon
newspaper - Generic newspaper icon
peripheral - Generic computer peripheral icon
plant_leaf - A certain green leafy plant
pocketknife - A swiss army pocket knife
question - Icon of a speech bubble with a "?" inside
radiation - Yellow and black radiation symbol
ram - Icon of a couple sticks of RAM
recycle - Green recycle arrows logo
recycle2 - Recycle arrows enveloping a globe of Earth
scanner - Generic scanner icon
screw - Golden screw icon
screw2 - Gray screw icon
setup - Generic icon for "setup.exe" type programs
skull - Black skull and crossbones
skull2 - Picture of a skull
skull3 - White skull and crossbones
tux - Icon of our favorite Linux mascot
tux_config - Tux dressed up like a repairman
ups - Icon of an uninterruptible power supply
zipdisk - Icon of a single zip disk
zipdisks - Icon of numerous zipdisks
You can call ZenMsg from a batch file or any other program (e.g. a Python or Perl script could call ZenMsg.exe and send it parameters). For example, open Notepad and save the following as "example.bat" (with quotes, ensuring that it gets a .bat extension and not .bat.txt) and place it in the same folder next to ZenMsg.exe:
@echo off
ZenMsg --alert --title "Critical Error" --text "Now you've done it." ^
--button "Ok" --button "Cancel" --button "Accept blame" ^
--disabled 1 --disabled 2 > zenmsg-answer.txt
echo The user had selected:
type zenmsg-answer.txt
del zenmsg-answer.txt
Double-clicking your example.bat file would then pop up that alert box. ZenMsg prints the user's selected button to its standard output, which we captured above by piping it into zenmsg-answer.txt (it's possible to get output from commands in e.g. Perl scripts too, so your program can ask the user a question and then have branching behavior depending on which button the user clicked on).
NNN asks:
What kind of music do you listen to?
I listen to all sorts of things but most frequently are the following:
I generally like a lot of indie & electronic music in recent years. I have a Spotify playlist of several artists I like. Depending on my mood, some of my top go-to artists are Plantrae or Dirtwire if I just want some cool music with no/minimal vocals. Plantrae is also a great one to put on as some ambient music at the background of a party. Otherwise ZHU is often the one I click on and let Spotify have its way with me. Bob Moses is another favorite if I want something a little more bass-ey to jam out to.
I listen to a fair amount of pop music too, my top exposure to it being my car radio when I'm driving around, so whatever's on the Top 40 at a given time. Sometimes those songs will get stuck in my head and I'll play one on Spotify and let it wander and play similar songs for me. I also have a number of country artists/songs I like when I'm in the right mood and I have a short playlist on YouTube of sad songs when I need to get some emotions out.
And probably my #1 most favorite song in the world (which I don't let myself listen to very often, so that I don't ruin it for myself) is Canon in D.
Ax Wilson asks:
For some reason it is not opening the ZenMsg file how do i make it work.
ZenMsg is a command-line program designed to be invoked by batch scripts or similar apps when you want to show a customized alert box pop-up. When you run the program without any command-line parameters (including if you just double-clicked on ZenMsg.exe from your file browser), the program just prints out its usage instructions to your command prompt and then exits; if you double-clicked to run it, exiting means you saw a cmd window for a brief second which then closed immediately.
To run it properly, open Command Prompt (or Powershell) first, navigate into the directory you placed ZenMsg.exe in, and run "ZenMsg" at the command prompt to see its usage instructions. For an "easy" way to get a Command Prompt opened to the right directory, you can open Windows Notepad and type this text into it:
@echo off
cmd
And save it as "terminal.bat" (with quotations on it! so that it saves with a ".bat" extension, and not "terminal.bat.txt") in the same folder as ZenMsg.exe; then double-clicking on the terminal.bat will open a Command Prompt already pointed at the current directory, so you can just type "ZenMsg" to run the other program. For more info about the Command Prompt, see the DOS tutorial on ComputerHope.com which is where I myself learned how to use the Command Prompt, way back in the day!
Anonymous asks:
Why is ZenMsg a command line program?
My Error Message Generator program is a GUI where you can build your custom alert box message visually, and ZenMsg is a command-line version that can pop up your alert box without the ErrorGen GUI being needed.
The reason that ZenMsg is a CLI tool is so that you can invoke it from other programs easily, including from batch files or scripts written in Perl, Python or anything else. Actually, it's name, "ZenMsg" is based on the GNU/Linux program, Zenity from the GNOME project.
You should also be able to create a Windows shortcut file that runs ZenMsg with parameters so you can have a desktop icon that, when double-clicked, pops up a ZenMsg alert box with custom icon, message and buttons if you want to prank your friends or something.
Anonymous asks:
What does your sites name kirsle come from/ what’s the meaning?
The short answer is that Kirsle is just an AOL screen name I came up with back in middle school and doesn't mean anything; and it turned out to be such a unique name (that most all Google results for it were about me), that I decided to keep it around forever.
The longer answer is that it was originally inspired by a videogame character on the game NiGHTS: Into Dreams for the Sega Saturn. One of the baddies in the game was named Kircle, with a C, but when I read it I thought the C should've been pronounced like an S but anyway my screen name was based on Kircle for a time. But after multiple people (including text-to-speech programs) were "mispronouncing" it, I swapped the C out for an S and in doing so found a very unique username for myself.
Also, fun trivia: kirsle.net was the first ever domain name I registered, back in 2005 when I was in high school (my mom had to buy the domain for me!) I took the ".net" extension instead of ".com" because I thought "kirsle.com" didn't roll off the tongue very well; and because I didn't have a bank account to just buy my own domain names, but I already had several different websites, I thought a ".net" suffix would go well to put a bunch of subdomains beneath ".kirsle.net" to host all my various sites on one domain name! (Before kirsle.net, my other sites were hosted on random free subdomains I could find online, also had a few free .tk domains back in the day!) I do now have kirsle.com and kirsle.org and they just redirect to kirsle.net because that name still sounds the best to me!
Oliver asks:
Hello,
I'm looking for a way to solve the following scenario using Rivescript and Python. The chatbot has no answer to a question, in this case it asks the user for the correct answer and records it in the rivescript file.
Do you have an idea? Does it even work in Rivescript?
Thanks
Best wishes Oliver
Hey Oliver
This can be done with a little bit of creativity. Self-learning bots aren't an officially supported feature in RiveScript, but you can get something to work using object macros that write new replies out to .rive
files to grow the bot's brain over time.
There's an example for this in the JavaScript edition of RiveScript, but its logic could be ported over to Python easily enough: https://github.com/aichaos/rivescript-js/tree/master/eg/learning
RiveScript Playground example you can test in your web browser: https://play.rivescript.com/s/0r4ZYvklR9
The basic ideas are:
+ when i say * you say *
allows the user to teach the bot a new reply.
rs.set_uservar(username, "origMessage", message)
when i say * you say *
trigger re-parses the user's message to get the original punctuation and formatting they used.learned.rive
file and also calls stream()
to load the new reply for immediate use by the bot "right now."The JavaScript example linked above works whether or not the program set the origMessage
variable: if the program did not set the variable, the learned reply is just somewhat limited to only include simple text with very few punctuation symbols preserved.
0.0017s
.