Skip to content

docs: add qq-ai-bot integration example#22

Open
happysnaker wants to merge 3 commits into
LLOneBot:mainfrom
happysnaker:docs/add-qq-ai-bot-integration
Open

docs: add qq-ai-bot integration example#22
happysnaker wants to merge 3 commits into
LLOneBot:mainfrom
happysnaker:docs/add-qq-ai-bot-integration

Conversation

@happysnaker

@happysnaker happysnaker commented Jul 2, 2026

Copy link
Copy Markdown

Adds an optional qq-ai-bot integration example to the README.

Why this is useful:

  • shows a concrete LLOneBot + qq-ai-bot deployment path for users who want a self-hosted QQ ↔ AI bot stack
  • includes the matching OneBot11 forward WebSocket config and token note, which is a common integration footgun
  • points to a runnable public image and project page instead of only a conceptual description

This is intentionally optional and does not change the existing Docker / Nix quickstart path for plain LLOneBot users.

由 Sourcery 提供的摘要

为 QQ-to-AI 部署记录 LLOneBot 与 qq-ai-bot 之间的一种可选集成路径。

文档:

  • 添加一个 docker-compose 示例,展示如何在使用前向 WebSocket 模式和共享令牌配置的情况下,将 LLOneBot 与 qq-ai-bot 一起运行。
  • 记录在与 qq-ai-bot 一起使用时,LLOneBot 所需的 OneBot11 前向 WebSocket 配置,并链接到 qq-ai-bot 的相关资源。
Original summary in English

Summary by Sourcery

Document an optional integration path between LLOneBot and qq-ai-bot for QQ-to-AI deployments.

Documentation:

  • Add a docker-compose example showing how to run LLOneBot together with qq-ai-bot using forward WebSocket mode and shared token configuration.
  • Document the required OneBot11 forward WebSocket configuration for LLOneBot when used with qq-ai-bot and link to qq-ai-bot resources.

@sourcery-ai

sourcery-ai Bot commented Jul 2, 2026

Copy link
Copy Markdown

审阅者指南

在 README 中新增一个可选的 qq-ai-bot 集成示例,包括一个通过 OneBot11 转发 WebSocket 配置将 LLOneBot 与 qq-ai-bot 连接起来的 docker-compose 片段,并澄清共享访问令牌的要求。

文件级变更

Change Details Files
记录一个基于 docker-compose 的可选集成,用于在 QQ 与 AI 之间部署 LLOneBot 和 qq-ai-bot。
  • 在 README 中新增一个中文章节,介绍 qq-ai-bot 作为 QQ ↔ AI 用例的可选集成方案
  • 提供一个 docker-compose 示例,其中定义了位于共享桥接网络上的 llonebot 和 qq-ai-bot 服务,并配置好 OneBot 转发模式所需的端口、卷和环境变量
  • 为 qq-ai-bot 添加与 OneBot 相关的环境变量,例如转发 WebSocket URL、访问令牌、群聊/私聊行为以及 ACP agent 选项
  • 定义一个共享的 docker 网络 qq_ai_bot 以支持服务间通信
readme.md
阐明在 LLOneBot 端所需的匹配 OneBot11 转发 WebSocket 配置。
  • 新增一个 JSON5 示例,展示包含 host、port、token 和 message format 字段的 OneBot11 转发 WebSocket 配置
  • 说明 qq-ai-bot 的 ONEBOT_ACCESS_TOKEN 必须与 LLOneBot 的 OneBot11 设置中配置的 token 一致
  • 添加指向 qq-ai-bot GitHub 仓库和项目主页的链接,方便用户获取更多详情和更新
readme.md

提示与命令

与 Sourcery 交互

  • 触发新审阅: 在 pull request 中评论 @sourcery-ai review
  • 继续讨论: 直接回复 Sourcery 的审阅评论。
  • 从审阅评论生成 GitHub issue: 通过回复审阅评论,要求 Sourcery 从该评论创建一个 issue。你也可以在审阅评论下回复 @sourcery-ai issue 来从该评论创建 issue。
  • 生成 pull request 标题: 在 pull request 标题的任意位置写上 @sourcery-ai,即可随时生成标题。你也可以在 pull request 中评论 @sourcery-ai title 以(重新)生成标题。
  • 生成 pull request 摘要: 在 pull request 正文任意位置写上 @sourcery-ai summary,即可在指定位置生成 PR 摘要。你也可以在 pull request 中评论 @sourcery-ai summary 以在任何时间(重新)生成摘要。
  • 生成审阅者指南: 在 pull request 中评论 @sourcery-ai guide,即可在任何时间(重新)生成审阅者指南。
  • 解决所有 Sourcery 评论: 在 pull request 中评论 @sourcery-ai resolve,即可一键解决所有 Sourcery 评论。适用于你已经处理完所有评论且不希望再看到它们的情况。
  • 关闭所有 Sourcery 审阅: 在 pull request 中评论 @sourcery-ai dismiss,即可关闭所有现有的 Sourcery 审阅。尤其适用于你希望从头开始一次新的审阅——别忘了再评论 @sourcery-ai review 来触发新的审阅!

自定义你的体验

访问你的 dashboard 以:

  • 启用或禁用审阅功能,例如 Sourcery 自动生成的 pull request 摘要、审阅者指南等。
  • 更改审阅语言。
  • 添加、移除或编辑自定义审阅指令。
  • 调整其他审阅设置。

获取帮助

Original review guide in English

Reviewer's Guide

Adds an optional qq-ai-bot integration example to the README, including a docker-compose snippet wiring LLOneBot to qq-ai-bot via a forward WebSocket OneBot11 config and clarifying the shared access token requirement.

File-Level Changes

Change Details Files
Document an optional docker-compose-based integration between LLOneBot and qq-ai-bot for QQ ↔ AI deployments.
  • Add a new README section in Chinese describing qq-ai-bot as an optional integration for QQ ↔ AI use cases
  • Provide a docker-compose example defining llonebot and qq-ai-bot services on a shared bridge network with ports, volumes, and environment variables configured for OneBot forward mode
  • Include OneBot-related environment variables for qq-ai-bot such as forward WebSocket URL, access token, group/private behavior, and ACP agent options
  • Define a shared docker network qq_ai_bot for inter-service communication
readme.md
Clarify the matching OneBot11 forward WebSocket configuration required on the LLOneBot side.
  • Add a JSON5 example showing a OneBot11 forward WebSocket configuration with host, port, token, and message format fields
  • Document that the qq-ai-bot ONEBOT_ACCESS_TOKEN must match the token configured in LLOneBot's OneBot11 settings
  • Link to qq-ai-bot GitHub repository and project page for users to get more details and updates
readme.md

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey - 我发现了 1 个安全问题

安全问题

  • 检测到不安全的 WebSocket。所有 WebSocket 连接都应使用加密的 WebSocket(wss)。(link)
给 AI Agent 的提示
Please address the comments from this code review:

## Individual Comments

### Comment 1
<location path="readme.md" line_range="74" />
<code_context>
      - ONEBOT_FORWARD_WS_URL=ws://llonebot:3001
</code_context>
<issue_to_address>
**security (javascript.lang.security.detect-insecure-websocket):** Insecure WebSocket Detected. WebSocket Secure (wss) should be used for all WebSocket connections.

*Source: opengrep*
</issue_to_address>

Sourcery 对开源项目免费——如果你觉得我们的代码审查有帮助,欢迎分享 ✨
帮我变得更有用!请对每条评论点 👍 或 👎,我会根据你的反馈改进后续的代码审查。
Original comment in English

Hey - I've found 1 security issue

Security issues:

  • Insecure WebSocket Detected. WebSocket Secure (wss) should be used for all WebSocket connections. (link)
Prompt for AI Agents
Please address the comments from this code review:

## Individual Comments

### Comment 1
<location path="readme.md" line_range="74" />
<code_context>
      - ONEBOT_FORWARD_WS_URL=ws://llonebot:3001
</code_context>
<issue_to_address>
**security (javascript.lang.security.detect-insecure-websocket):** Insecure WebSocket Detected. WebSocket Secure (wss) should be used for all WebSocket connections.

*Source: opengrep*
</issue_to_address>

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

Comment thread readme.md Outdated
@happysnaker

Copy link
Copy Markdown
Author

补充了一版更具体的处理:

  1. README 里的 ONEBOT_FORWARD_WS_URL 改成可替换变量,避免把容器内私网 ws:// 地址误导成公网默认值
  2. 新增 examples/qq-ai-bot-compose.yml,把这条集成路线从 README 片段升级成可复用示例文件
  3. 明确写了:Docker 私有桥接网络内可直接用 ws://...;跨主机 / 公网 / 反向代理场景应改成 wss://...

这样既保留了本地最常见的 compose 场景,也把 TLS 边界说明清楚了。

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

New security issues found

Comment thread examples/qq-ai-bot-compose.yml Outdated
@happysnaker

Copy link
Copy Markdown
Author

继续补了一刀:把示例文件里仅剩的 ws://... 注释字面量也去掉了,避免静态审查把“Docker 内网示例”继续误报成默认公网配置。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant