Favicon of AstrBot

AstrBot

Open-source Python framework for building LLM-powered chatbots across IM platforms with plugins, agents, and a WebUI.

AstrBot website screenshot
AstrBot GitHub repository preview

AstrBot is an open-source Python platform for running an AI chatbot across instant messaging apps. It's built for developers and self-hosters who want to connect an LLM (OpenAI, Anthropic, Gemini, DeepSeek, Ollama, and others) to platforms like QQ, Telegram, Slack, Discord, Feishu, DingTalk, or WeChat, and then extend the bot with plugins, agents, and knowledge bases instead of writing a separate integration for each platform.

Key features

  • Multi-platform messaging: official adapters for QQ, Telegram, Slack, Discord, WeChat Work, Feishu, DingTalk, LINE, KOOK, Mattermost, and more, with community adapters for Matrix and Rocket.Chat.
  • Broad model support: works with OpenAI-compatible APIs, Anthropic, Google Gemini, Moonshot AI, Zhipu AI, DeepSeek, and self-hosted options like Ollama and LM Studio, plus API gateways such as AIHubMix and SiliconFlow.
  • Agent capabilities: MCP support, skills, knowledge base retrieval, persona settings, and automatic context compression for longer conversations.
  • Agent Sandbox: isolated execution for code and shell calls, with session-level resource reuse for safer automation tasks.
  • LLMOps integrations: connects to Dify, Alibaba Cloud Bailian, and Coze for teams already using those agent platforms.
  • Plugin ecosystem: over 1000 community plugins installable with one click, covering everything from TTS/STT services to custom skills.
  • WebUI and ChatUI: a browser-based admin panel plus a chat interface with built-in sandbox and web search.
  • Speech services: integrates STT engines like Whisper and SenseVoice, and TTS engines including Edge TTS, Azure TTS, FishAudio, and GPT-Sovits.
  • Internationalization: interface and docs available in multiple languages including Chinese, Japanese, French, Spanish, and Russian.

Ideal use cases

AstrBot fits well if you want a personal AI companion or assistant living inside an existing chat app, rather than a standalone web chatbot. It also works for building internal customer-service bots on platforms like Feishu, DingTalk, or WeChat Work, where a team already communicates, or for wiring an LLM into a Discord/Telegram community for moderation, Q&A, or entertainment bots backed by a knowledge base.

Teams that already run Dify, Coze, or Bailian agents can use AstrBot as the messaging front-end without rebuilding their agent logic. Developers who want to extend behavior via plugins, rather than forking a monolith, benefit from the 1000+ plugin marketplace.

It's not the right choice if you need a pure API-only backend with no chat-platform integration, or if you want a minimal single-file bot script with no plugin system, WebUI, or agent framework overhead. If your use case is a simple slash-command bot for one platform, a lighter framework built for that specific platform may be less to maintain.

Installation

AstrBot requires Python 3.12+ and, for the recommended path, the uv tool.

Quick start with uv:

uv tool install astrbot --python 3.12
astrbot init # only run this once, to initialize the environment
astrbot run

To update later:

uv tool upgrade astrbot --python 3.12

Docker deployment (recommended for production): follow the official Docker/Docker Compose guide in the AstrBot documentation.

Desktop app: for ChatUI-focused desktop use, install AstrBot-desktop or AstrBot Launcher from their respective repositories; these are not meant for server deployment.

Arch Linux (AUR):

yay -S astrbot-git

Other options: one-click cloud deployment via RainYun, panel-based installs through BT Panel, 1Panel, or CasaOS, and community-maintained Replit deployment for demos.

Development setup:

git clone https://github.com/AstrBotDevs/AstrBot
pip install pre-commit
pre-commit install

The project uses ruff for formatting and linting.

Frequently asked questions

Share:

Stars
38.1K
Forks
2.7K
Last commit
1 day ago
Repository age
4 years
License
AGPL-3.0
Self-hosted
Yes
Activity score
84/100
View Repository
Ad
Favicon

 

  
 

Similar to AstrBot

Favicon

 

  
 
Favicon

 

  
 
Favicon