RepoDaily · 2026-07-22 · Self-hosted app

AstrBot Connects Eight IM Platforms to Multiple LLMs in One Self-Hosted Python Framework

#14 Self-hosted app Python +416 AstrBotDevs/AstrBot Open repository

Version 4.26.7 bundles QQ, Telegram, Discord, WeChat, Slack, Feishu, DingTalk adapters with OpenAI, Claude, Gemini, and MCP tool support. AGPL-3.0, Python 3.12+.

Repo typeSelf-hosted app
Best forDevelopers who want a single Python service bridging multiple chat platforms to multiple LLM providers without writing separate integrations for each.
Risk levelMedium — AGPL-3.0 copyleft, heavy dependency tree, Python 3.12+ requirement
Time to evaluate2–4 hours to Docker-deploy and connect one IM platform plus one LLM provider

Primary question: Does the AGPL-3.0 license and the breadth of bundled dependencies fit your deployment and compliance constraints?

91/100

RepoDaily adoption score

RepoDaily rates this as 91/100 (strong) for adoption: evidence, installation path, production risk, differentiation, license clarity, and AI/agent fit are scored from the article sources and adoption notes.

Directional score from RepoDaily sources and adoption notes, not a benchmark.Risk: Medium
100Evidence quality

6 source(s) across 4 source category/categories, plus a RepoDaily-specific evidence module when available.

100Installability

5 workflow step(s), 5 next-action step(s), and 6 command/install signal(s) were detected.

63Maintenance confidence

Trending momentum is +416 stars, with maintenance/release/issue signals counted when present.

93Production readiness

Risk is marked medium, with 5 security note(s) and 4 explicit skip condition(s).

97Differentiation

2 opportunity lens item(s), 4 alternative(s), and 3 type-specific section(s) support differentiation.

82License clarity

License source or license wording is present.

90Agent / AI fit

7 AI/agent-related signal(s) were detected in the article text and metadata.

Project overview

AstrBot is a Python-based AI agent framework that positions itself as a unified bridge between instant messaging platforms and large language model providers. Rather than writing separate bot code for QQ, Telegram, Discord, and half a dozen other platforms, you configure adapters and route conversations through a shared LLM pipeline. The project describes itself as an 'openclaw alternative' and targets developers who want self-hosted control over their chatbot infrastructure.

At version 4.26.7, the framework's dependency manifest reveals a wide integration surface. For IM connectivity, it pulls in python-telegram-bot, py-cord for Discord, aiocqhttp and qq-botpy for QQ, dingtalk-stream for DingTalk, lark-oapi for Feishu and Lark, slack-sdk for Slack, and wechatpy for WeChat. On the LLM side, it bundles the official SDKs for OpenAI, Anthropic, Google GenAI (Gemini), and Alibaba's DashScope. MCP (Model Context Protocol) support is included via the mcp package pinned to >=1.8.0,<2, enabling tool-use and function-calling patterns.

The project gained 416 stars during this trending period, placing it at rank 14. The repository follows a semantic-commit workflow enforced by commitizen, uses Ruff for code quality, and ships a Vue.js dashboard bundled into the package via a custom Hatch build hook at package-build time.

Problem it solves

  • Connecting a chatbot to multiple IM platforms normally requires separate SDK integrations, separate deployment processes, and separate message-formatting logic for each platform's API.
  • Routing those messages to different LLM providers (OpenAI, Anthropic, Google, local models via Xinference) requires another layer of adapter code that most developers would rather not maintain from scratch.
  • Running AI agents with tool-use capabilities typically requires wiring up MCP or function-calling infrastructure manually, which is non-trivial without prior agent-development experience.
  • Chinese-language RAG pipelines need proper tokenization (jieba) and hybrid retrieval (BM25 plus vector), which are often missing from English-centric LLM frameworks.

How it works

  1. Deploy the framework via Docker (python:3.12-slim base image) or directly from source using uv as the package manager. The Docker container exposes port 6185 and launches via `python main.py`.
  2. Configure IM platform adapters through the dashboard or configuration files — each platform (QQ, Telegram, Discord, etc.) has its own SDK dependency already installed in the dependency tree.
  3. Configure one or more LLM providers using their respective API keys — the project bundles openai, anthropic, google-genai, and dashscope SDKs.
  4. Messages from IM platforms flow through the pipeline, which can apply RAG (using faiss-cpu and rank-bm25), MCP tool calls, and plugin logic before returning responses to the originating platform.
  5. The bundled Vue dashboard (built via a custom Hatch hook and served from astrbot/dashboard/dist/) provides a web management UI at port 6185.

Integration Surface: What Platforms and LLMs Are Bundled

  • IM platforms: aiocqhttp (QQ via OneBot), qq-botpy 1.2.1 (official QQ bot API), python-telegram-bot>=22.6 (Telegram), py-cord>=2.6.1 (Discord), dingtalk-stream>=0.22.1 (DingTalk), lark-oapi>=1.4.15 (Feishu/Lark), slack-sdk>=3.35.0 (Slack), wechatpy>=1.8.18 (WeChat).
  • LLM providers: openai>=1.78.0, anthropic>=0.51.0, google-genai>=1.56.0 (Gemini), dashscope>=1.23.2 (Alibaba Cloud), xinference-client (local and self-hosted models).
  • MCP: mcp>=1.8.0,<2 for Model Context Protocol tool integration.
  • RAG: faiss-cpu>=1.14.3 (vector search), rank-bm25>=0.2.2 (BM25 lexical retrieval), jieba>=0.42.1 (Chinese tokenization), pypdf>=6.1.1 and markitdown-no-magika for document parsing.
  • Audio processing: pydub>=0.25.1, silk-python>=0.2.6, audioop-lts (Python 3.13+), and ffmpeg installed via the Dockerfile.
  • CLI entry point defined in pyproject.toml: `astrbot = astrbot.cli.__main__:cli`.

Deployment Notes: Docker, Requirements, and Runtime

  • Docker base image: python:3.12-slim with apt packages including gcc, build-essential, ffmpeg, libavcodec-extra, ripgrep, and Node.js LTS (for dashboard builds).
  • Port 6185 is exposed and the startup command is `python main.py`. A smoke test in the CI flow checks connectivity to http://localhost:6185.
  • Package management uses uv — the Dockerfile runs `uv lock`, `uv export --format requirements.txt --frozen`, and `uv pip install --system`.
  • Python version requirement: >=3.12 per pyproject.toml, with .python-version set to 3.12 in the Docker image.
  • Additional Docker-installed packages beyond pyproject.toml: socksio, uv, pilk.
  • The Vue dashboard is not tracked by VCS but is built at package-build time via a custom Hatch hook (scripts/hatch_build.py) and bundled as a build artifact at astrbot/dashboard/dist/**.

Command Surface: Dev and CI Commands

  • Code quality: `ruff format .` and `ruff check .` before every PR submission.
  • Local CI-equivalent: `make pr-test-neo` runs uv sync (dev group), ruff format check, ruff check, Neo-related critical tests, and a main.py startup smoke test against localhost:6185.
  • Full validation: `make pr-test-full` for the complete test suite including dashboard build.
  • Fast repeat runs: `make pr-test-full-fast` skips dependency sync and dashboard build for iterative testing.
  • Commit style enforced by commitizen>=4.9.1 with prefixes: fix:, feat:, docs:, style:, refactor:, test:, chore:.

Who should pay attention?

Good fit if

  • You need to deploy a chatbot across QQ plus at least one other IM platform (Telegram, Discord, etc.) and want a single codebase for all of them.
  • Your use case involves Chinese-language document Q&A requiring jieba tokenization and BM25 plus vector hybrid retrieval.
  • You want to experiment with MCP tool-use patterns across different LLM providers without writing provider-specific tool-calling code.
  • You are comfortable with AGPL-3.0 licensing and have Python 3.12+ available in your deployment environment.

Skip for now if

  • You need a proprietary or closed-source product — AGPL-3.0-or-later requires sharing source code of modified versions deployed as network services.
  • You only need a single-platform bot (e.g., Discord only) — the framework's value comes from multi-platform consolidation.
  • Your infrastructure runs Python 3.11 or earlier — the minimum requirement is Python 3.12 per pyproject.toml.
  • You need a turnkey hosted SaaS without any self-hosting effort.

Risks and cautions

Medium

AGPL-3.0 copyleft, Python 3.12+ hard requirement, and a dependency tree of 60+ packages create moderate adoption friction for commercial or restricted environments.

  • AGPL-3.0-or-later license requires operators of network-accessible modified versions to release source code to their users — more restrictive than MIT or Apache-2.0.
  • Python >=3.12 is required per pyproject.toml, which may conflict with existing infrastructure running older Python versions.
  • The dependency list includes 60+ packages across IM SDKs, LLM SDKs, and infrastructure libraries, increasing the surface area for supply-chain and compatibility issues.
  • The project bundles platform-specific binaries (silk-python, audioop-lts, faiss-cpu) that may need compilation or specific OS support.
  • The dashboard is built at package time via a custom Hatch hook requiring Node.js LTS, adding build complexity for non-Docker deployments.
  • License is GNU AGPL v3 (AGPL-3.0-or-later) — network-use copyleft applies; review compatibility with your distribution model before deployment.
  • The Dockerfile installs Node.js LTS from deb.nodesource.com for dashboard builds, adding a second runtime to the container image.
  • API keys for LLM providers and IM platforms are stored in configuration; review how secrets are managed in your specific deployment.
  • The framework includes cryptography>=44.0.3, pyjwt>=2.10.1, and pyotp>=2.9.0, indicating built-in support for encryption, JWT, and TOTP authentication.
  • The Docker image runs as root (no USER directive in the Dockerfile) — consider adding a non-root user for production.

Alternatives to compare

ApproachWhen to useTrade-off
LangChain
You need a general-purpose LLM application framework without built-in IM platform adapters.MIT licensed
NoneBot2
You primarily target QQ and want a mature Python bot framework without LLM-specific features bundled.MIT licensed
Dify
You want a visual drag-and-drop builder for AI applications with a web UI rather than a code-first framework.Apache-2.0 with additional enterprise terms
Commercial chatbot platforms (provider-hosted bots)
You want zero infrastructure management and are willing to pay per-message or per-seat fees.Subscription or usage-based pricing

What this trend reveals

MCP Tools for Chinese Enterprise Messaging

AstrBot's MCP support (mcp>=1.8.0,<2) combined with Feishu and DingTalk adapters creates a specific niche: MCP-powered agents accessible through Chinese enterprise messaging platforms, where most MCP tooling currently targets English-speaking developer audiences.

Build a plugin that exposes a Chinese enterprise API (e.g., Feishu document search) as an MCP tool and measure adoption within the AstrBot plugin community.

Self-Hosted RAG for Regulated Chinese-Language Deployments

The bundled jieba plus BM25 plus faiss-cpu retrieval stack supports Chinese-language document Q&A without sending documents to foreign LLM APIs, which matters for organizations in regulated industries that cannot transmit data across borders.

Deploy AstrBot with a local Xinference model and test retrieval quality against a Chinese-language document corpus of at least 500 documents.

Best next action

Deploy via Docker and Connect One IM Platform

The fastest path is the Docker image, which bundles all system dependencies including ffmpeg, Node.js, and ripgrep. Pick one IM platform you already have credentials for and one LLM provider API key to test end-to-end message flow.

  1. Pull or build the Docker image from the repository's Dockerfile (python:3.12-slim base, port 6185).
  2. Start the container and access the dashboard at http://localhost:6185.
  3. Configure one IM platform adapter (e.g., Telegram bot token via BotFather) in the dashboard.
  4. Add one LLM provider API key (e.g., OpenAI or DashScope) to test message-to-LLM routing.
  5. Send a test message from your IM client and verify the response round-trips through the framework.

RepoDaily verdict

AstrBot fills a genuine gap: no other open-source Python framework bundles eight IM platform adapters, five LLM provider SDKs, MCP tool support, and Chinese-language RAG in a single self-hosted package. The AGPL-3.0 license and Python 3.12+ requirement are the main friction points. For developers building cross-platform AI assistants — especially in Chinese-language markets — it deserves a focused hands-on trial.

Sources