Skip to content
This repository has been archived by the owner on Jun 24, 2024. It is now read-only.

Latest commit

 

History

History
47 lines (30 loc) · 1.45 KB

README.md

File metadata and controls

47 lines (30 loc) · 1.45 KB

llmcord

llmcord logo: a vaguely Discord Clyde-looking llama

A Discord bot, written in Rust, that generates responses using any language model supported by llm.

Built on top of llm.

Setup

Model

See llm's README.

Bot

Discord

  • Create a Discord application and fill it out with your own details.
  • Go to Bot and create a new Bot.
    • Hit Reset Token, and copy the token it gives you somewhere.
  • Go to OAuth2 > URL Generator, select bot, then select Send Messages and Use Slash Commands.
    • Go to the URL it generates, and then invite it to a server of your choice.

Application

  • Install Rust 1.68 or above using rustup.
  • Run cargo run --release to start llmcord. This will auto-generate a configuration file, and then quit.
  • Fill in the configuration file with the required details, including the path to the model.
  • You can then run llmcord to your heart's content.

Note that you can define your own commands in the configuration, like so:

[commands.makecaption]
enabled = true
description = "Attempts to make an image description for the given prompt."
prompt = """Below is an instruction that describes a task. Write a response that appropriately completes the request.

### Instruction:

Create an evocative image description for "{{PROMPT}}".

### Response:

"""