feat(vectordb): 添加向量数据库支持及集成功能

新增向量数据库管理器模块,支持文本的存储、检索和相似度查询
添加知识库插件和AI聊天插件,利用向量数据库实现记忆功能
优化跨平台翻译模块,集成向量数据库存储历史翻译记录
改进消息处理逻辑,优先使用用户显示名称
This commit is contained in:
2026-03-24 14:32:36 +08:00
committed by 镀铬酸钾
parent fc8a258033
commit e300708cbe
6 changed files with 178 additions and 3 deletions

View File

@@ -356,7 +356,8 @@ class DiscordToOneBotConverter:
# 注入 Discord 特定信息(用于跨平台插件识别)
discord_channel_id = discord_message.channel.id if not isinstance(discord_message.channel, discord.DMChannel) else None
discord_username = discord_message.author.name
# 使用 global_name (显示名称/昵称) 如果存在,否则使用 name (用户名)
discord_username = getattr(discord_message.author, 'global_name', None) or discord_message.author.name
discord_discriminator = f"#{discord_message.author.discriminator}" if discord_message.author.discriminator != "0" else ""
if is_private: