Go to file
2025-10-02 17:01:07 +00:00
local initial commit 2023-04-04 18:58:35 +00:00
__init__.py Move configuration to supybot config registry; improve logging and docs 2025-10-02 17:01:07 +00:00
.gitignore Move configuration to supybot config registry; improve logging and docs 2025-10-02 17:01:07 +00:00
config.py Move configuration to supybot config registry; improve logging and docs 2025-10-02 17:01:07 +00:00
plugin.py Move configuration to supybot config registry; improve logging and docs 2025-10-02 17:01:07 +00:00
README.md Move configuration to supybot config registry; improve logging and docs 2025-10-02 17:01:07 +00:00
test.py Move configuration to supybot config registry; improve logging and docs 2025-10-02 17:01:07 +00:00

Chat

A Limnoria plugin that brings ChatGPT into your IRC channel

Installation

  1. Install the plugin
  2. Put your API key in the plugin configuration registry like so:
/msg BotName config plugins.Chat.api_key YOUR_API_KEY
  1. Load the plugin:
load Chat

Configuration

The Chat plugin supports the following configuration parameters:

  • api_key: The API key for accessing OpenAI's API. This must be set for the plugin to work.
  • model: The OpenAI model to use for generating responses. Default: gpt-4.
  • max_tokens: The maximum number of tokens to include in the response. Default: 256.
  • system_prompt: The system prompt to guide the assistant's behavior. Default: You are a helpful assistant..
  • scrollback_lines: The number of recent lines from the channel to include as context. Default: 10.
  • join_string: The string used to join multi-line responses into a single line. Default: /.

Example Configuration

To set the API key:

/msg BotName config plugins.Chat.api_key YOUR_API_KEY

To change the model:

/msg BotName config plugins.Chat.model gpt-3.5-turbo

To adjust the maximum tokens:

/msg BotName config plugins.Chat.max_tokens 512

Usage

Once configured, you can use the chat command to interact with the bot. For example:

@BotName chat What is the capital of France?

The bot will respond with the answer based on the configured model and context.

Defaults

The plugin is designed to work out of the box with minimal configuration. Simply set the api_key, and the plugin will use sensible defaults for all other parameters.