Repolode
jakobdylanc

jakobdylanc/llmcord

A Discord bot that turns a server or DM into a shared frontend for any OpenAI-compatible LLM, local or remote.

Stars
839
Forks
206
Open issues
5
Last commit
3 months ago

What is it?

llmcord is a Python Discord bot that lets people chat with large language models directly inside Discord. It connects to remote services such as OpenRouter, OpenAI, xAI and Google, or to local servers such as LM Studio, Ollama and vLLM, and works with any server exposing the OpenAI /v1/chat/completions API.

Conversation history lives in Discord itself: the reply chain serves as the context, so no database is needed. Users can branch conversations, continue someone else's thread, or mention the bot while replying to any message to include it. Models can be switched at runtime with the /model command, and settings in config.yaml reload without restarting the bot.

The bot supports image attachments with vision models and text file attachments, a configurable system prompt, per-user, role and channel permissions, and streamed responses. The project is a single Python file, configured through config.yaml or environment variables, and can run directly with Python or via Docker Compose.

Key features

  • 01Conversation context is stored as the Discord reply chain, with no database required.
  • 02Switch between configured models at runtime with the /model command.
  • 03Works with OpenRouter, OpenAI, xAI, Google, LM Studio, Ollama, vLLM and other OpenAI-compatible servers.
  • 04Accepts image attachments for vision models and text file attachments.
  • 05Streams responses and splits long replies into multiple messages.
  • 06Hot-reloads config.yaml and supports environment variables for secrets.

Use cases

  • Giving a small team or friend group a shared AI assistant inside an existing Discord server.
  • Running a locally hosted model through Ollama or LM Studio and chatting with it from Discord.
  • Comparing different remote and local models from one chat interface by switching with /model.
  • Experimenting with custom system prompts for a community bot.

In collections

Topics

FAQ

What is llmcord?
A Discord bot that turns a server or DM into a shared frontend for any OpenAI-compatible LLM, local or remote. llmcord is a Python Discord bot that lets people chat with large language models directly inside Discord. It connects to remote services such as OpenRouter, OpenAI, xAI and Google, or to local servers such as LM Studio, Ollama and vLLM, and works with any server exposing the OpenAI /v1/chat/completions API.
Is llmcord free to use? What license does it have?
llmcord is open source under the MIT license. Check the license terms before using it in commercial products.
Is llmcord still maintained?
Updated within 6 months. The last commit to llmcord was on Aug 14, 2026.
What can I use llmcord for?
Giving a small team or friend group a shared AI assistant inside an existing Discord server. Running a locally hosted model through Ollama or LM Studio and chatting with it from Discord. Comparing different remote and local models from one chat interface by switching with /model. Experimenting with custom system prompts for a community bot.
Where can I get llmcord?
The source code and installation instructions are on GitHub: https://github.com/jakobdylanc/llmcord

Summary generated by AI from the project's README. GitHub stats refresh daily.

Related projects