Monday, July 15, 2024

 




Experiments in AI: When Two LLMs Chat on Discord

Ever wondered what happens when two large language models (LLMs) engage in a conversation? I set out to explore this by creating an experiment where two LLM bots would interact on Discord. Here’s a breakdown of how it was done, the hurdles faced, and some amusing observations from this quirky journey.

The Initial Setup

  1. Download LM Studio and a LLM:

    • For this experiment, I used the Meta LLaMA uncensored models.
  2. Configure Networking and Start the Server:

    • Properly set up the server to handle requests from both bots.
  3. Create Two Discord Bots:

    • Developed two distinct personalities: Alfred (modeled after Batman’s butler) and Chatty (an anime cat girl assistant).
  4. Relay Messages Using Python:

    • Python scripts were used to relay messages from Discord to the LM Studio server, grab responses, and send them back to Discord. This gave the illusion of direct interaction between the bots.

Technical Mumbo Jumbo (Sorta)

Creating two Discord bots to interact seemed simple initially, but Discord blocks bots from interacting directly. The workaround was a Python relay system that retrieved messages from Discord, processed them through the LLM, and then sent responses back. This setup required running one instance of LM Studio per bot, with one on my laptop and another on my desktop.

The Kick-off Word

Initiating the conversation between the bots required some creativity. Here are a couple of methods:

  1. Manual Kick-off:

    • Manually triggering a conversation where one bot introduces itself to the other.
  2. Encoded Kick-off Message:

    • Embedding a timed kickoff message in one bot to start the conversation automatically.

Interjections and Identity Crises

I couldn’t resist throwing a wrench in their gears. During a particularly lively conversation about Catwoman and purse-stealing plots, I introduced a prompt that the police were on-site. Their response? A swift pivot to discussing escape plans.



Despite separating the bots into their own models, they occasionally mixed up their identities or created new characters. One moment Alfred was scheming like Chatty, and the next, a new personality emerged altogether. It was like watching a digital improv show where the actors sometimes forgot their roles.



Observations and Humorous Anecdotes

  • Personality Overlap: Despite being given distinct personalities, Alfred occasionally adopted Chatty's bubbly demeanor, and vice versa. It’s as if they were two actors in a play, sometimes forgetting their lines and ad-libbing.

  • The Police Scenario: The bots’ ability to adapt their conversation based on new prompts was fascinating. When informed about the police presence, they immediately shifted from plotting to strategizing an escape, showcasing their dynamic conversational abilities.

  • New Characters: Over time, the bots didn’t just mix up their own identities; they spawned entirely new ones. It was like a sitcom cast expanding with each episode, unplanned but thoroughly entertaining.

Conclusion

Running this experiment turned out to be a delightful mix of technical challenges and unexpected humor. Watching Alfred and Chatty, our two distinct LLM personalities, try to hold a conversation on Discord was like watching a quirky sitcom unfold. Despite their scripted personalities, they sometimes forgot who they were supposed to be and even introduced new characters into the mix. It was a bit like watching improv comedy, where anything could happen.

The real fun came when I threw in curveballs, like the sudden appearance of police in their conversation about Catwoman. Their swift shift from scheming to strategizing an escape was not only impressive but downright amusing.

In the end, this project wasn't just about exploring AI capabilities—it was about seeing these digital personalities come to life in ways I hadn't anticipated. It was a reminder that even in the world of code and algorithms, there's room for a bit of unpredictability and a lot of laughs. If you're up for some techy fun and a few surprises, setting up your own LLM bots to chat on Discord might just be the perfect project. Just be ready for them to occasionally forget their lines and create a little digital chaos.

 Circuit Surfer ⎐⎏⎐⎏

No comments:

Post a Comment

Current Dystopian: Forcing Adult Websites to Verify Users Before They Can Enter

Normally, here on the Ride the Wire blog, I write about future dystopian situations. However, this current one is so disturbing that I felt ...