feat: 多AI角色支持、Bug修复、文档更新

This commit is contained in:
sunny-335
2026-06-15 12:05:46 +08:00
parent ef3cdf4bdc
commit 6f1cb4b037
27 changed files with 2400 additions and 755 deletions
@@ -12,6 +12,11 @@ spec:
label: 启用AI回评
value: true
help: 开启后,该文章收到评论时将自动触发AI回复
- $formkit: text
name: comment-ai-autopilot.nxxy335.top/ai-persona
label: AI角色
help: 选择该文章使用的AI回复角色名称,留空使用默认角色
value: ""
---
apiVersion: v1alpha1
kind: AnnotationSetting
@@ -27,3 +32,8 @@ spec:
label: 启用AI回评
value: false
help: 开启后,该页面收到评论时将自动触发AI回复
- $formkit: text
name: comment-ai-autopilot.nxxy335.top/ai-persona
label: AI角色
help: 选择该页面使用的AI回复角色名称,留空使用默认角色
value: ""
@@ -13,6 +13,9 @@ rules:
- apiGroups: ["comment-ai-autopilot.nxxy335.top"]
resources: ["comment-ai-autopilot/aicommentreplies"]
verbs: ["*"]
- apiGroups: ["comment-ai-autopilot.nxxy335.top"]
resources: ["comment-ai-autopilot/aipersonas"]
verbs: ["*"]
- apiGroups: ["console.api.comment-ai-autopilot.nxxy335.top"]
resources: ["*"]
verbs: ["*"]
+30 -17
View File
@@ -21,26 +21,24 @@ spec:
value: 3
min: 1
max: 10
- $formkit: number
name: maxConversationRounds
label: 最大对话轮次
help: 同一评论线程中AI最多自动回复的轮次,超过后不再回复
value: 8
min: 1
max: 100
- $formkit: number
name: rateLimitPerMinute
label: 速率限制
help: 每分钟最大AI回复数量,防止批量评论消耗过多额度
value: 10
min: 1
max: 100
- $formkit: textarea
name: blockedCommenters
label: 评论者黑名单
help: 输入评论者显示名称或邮箱,多个用逗号分隔。这些评论者的评论不会触发AI回复
value: ""
- group: persona
label: AI角色设置
formSchema:
- $formkit: text
name: personaName
label: AI角色昵称
value: "小回"
- $formkit: textarea
name: personaPrompt
label: AI角色人格提示词
value: "你是「小回」,一个友善的评论者。你的回复简洁自然,像朋友聊天一样。简短的评论就简短回复,有深度的讨论才展开回应。不要长篇大论,不要复述文章内容。"
- $formkit: email
name: personaEmail
label: AI角色邮箱
help: 用于Gravatar头像服务展示头像
help: "输入评论者显示名称或邮箱,多个用逗号分隔。支持正则表达式,以 regex: 开头,如 regex:^spam.*"
value: ""
- group: model
label: 模型设置
@@ -57,6 +55,21 @@ spec:
name: customPromptTemplate
label: 自定义Prompt模板
value: "{{persona_prompt}}\n\n{{safety_prompt}}\n\n【语言要求】请用评论所使用的语言回复。如果评论是英文,请用英文回复;如果是中文,请用中文回复;如果是日文,请用日文回复;以此类推。\n\n请回复以下评论。注意:\n- 回复长度应与评论长度匹配,简短问候简短回复\n- 不要复述或总结文章内容\n- 自然对话,不要写小作文\n- 只有评论涉及具体内容时才针对性回应\n\n文章(仅供理解上下文,不要复述):\n{{article}}\n\n评论:\n{{comment}}"
- $formkit: select
name: enabledPresets
label: 启用预设
help: 选择要启用的Prompt预设风格
value: []
multiple: true
options:
- label: 友好型
value: friendly
- label: 专业型
value: professional
- label: 幽默型
value: humorous
- label: 简洁型
value: concise
- group: cleanup
label: 数据清理
formSchema:
+6 -6
View File
@@ -10,18 +10,18 @@ spec:
requires: ">=2.23.0"
author:
name: 暖心向阳335
website: https://github.com/暖心向阳335
website: https://nxxy335.top
logo: logo.png
homepage: https://github.com/暖心向阳335/comment-ai-autopilot#readme
repo: https://github.com/暖心向阳335/comment-ai-autopilot
issues: https://github.com/暖心向阳335/comment-ai-autopilot/issues
homepage: https://nxxy335.top/comment-ai-autopilot
repo: https://github.com/sunny-335/plugin-comment-ai-autopilot.git
issues: https://github.com/sunny-335/plugin-comment-ai-autopilot/issues
displayName: "AI回评"
description: "基于 AI 的 Halo 博客评论自动回复插件,支持 AI 虚拟角色回复、自审核、自动发布和对话式连续回复"
license:
- name: "GPL-3.0"
url: "https://github.com/暖心向阳335/comment-ai-autopilot/blob/main/LICENSE"
url: "https://github.com/sunny-335/plugin-comment-ai-autopilot/blob/main/LICENSE"
settingName: "comment-ai-autopilot-settings"
configMapName: "comment-ai-autopilot-configmap"
version: "0.0.1-w5s2t7"
version: "0.0.1-t5w8r3"
pluginDependencies:
ai-foundation: "*"