@nestim/koishi-plugin-qq-group-manager 1.0.2 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.d.ts +2 -0
- package/lib/index.js +3 -0
- package/lib/service.js +4414 -4356
- package/package.json +1 -1
- package/readme.md +6 -7
package/lib/index.d.ts
CHANGED
|
@@ -51,6 +51,7 @@ export interface Config {
|
|
|
51
51
|
joinRequestReviewTtlMinutes: number;
|
|
52
52
|
pendingJoinFileName: string;
|
|
53
53
|
bannedWords: string[];
|
|
54
|
+
strongKeywords: string[];
|
|
54
55
|
blockCardMessage: boolean;
|
|
55
56
|
blockForwardMessage: boolean;
|
|
56
57
|
autoDeleteViolation: boolean;
|
|
@@ -82,6 +83,7 @@ export interface GroupRule {
|
|
|
82
83
|
guildId: string;
|
|
83
84
|
enableAiReply?: boolean;
|
|
84
85
|
bannedWords: string[];
|
|
86
|
+
strongKeywords?: string[];
|
|
85
87
|
blockCardMessage: boolean;
|
|
86
88
|
blockForwardMessage: boolean;
|
|
87
89
|
autoDeleteViolation: boolean;
|
package/lib/index.js
CHANGED
|
@@ -20,6 +20,7 @@ exports.Config = koishi_1.Schema.intersect([
|
|
|
20
20
|
cmdUnban: koishi_1.Schema.string().default('[unban]').description('解除拉黑指令前缀,用法:[unban] qq|@某人 [reason]。'),
|
|
21
21
|
cmdBanList: koishi_1.Schema.string().default('[banlist]').description('黑名单查询指令前缀,单独发送即列出本群黑名单。'),
|
|
22
22
|
cmdCustom: koishi_1.Schema.string().default('[custom]').description('自定义指令集前缀,用法:[custom]。未配置自定义指令时提示「目前还没有指令」。'),
|
|
23
|
+
cmdVersion: koishi_1.Schema.string().default('[Version]').description('插件信息指令前缀,用法:[Version]。返回当前版本、作者、GitHub 与 npm 地址。'),
|
|
23
24
|
platformFilter: koishi_1.Schema.array(String).default(['onebot']).description('允许启用管理功能的平台列表。'),
|
|
24
25
|
responseStyle: koishi_1.Schema.union([
|
|
25
26
|
koishi_1.Schema.const('plain').description('普通输出'),
|
|
@@ -30,6 +31,7 @@ exports.Config = koishi_1.Schema.intersect([
|
|
|
30
31
|
koishi_1.Schema.object({
|
|
31
32
|
bannedWords: koishi_1.Schema.array(String).role('table').default([]).description('违禁词列表。支持顺序模糊匹配(如“领红包”可命中“领xxx元红包”)。可用“关键词|分值”自定义权重,分值越高越容易单独触发。'),
|
|
32
33
|
bannedWordScoreThreshold: koishi_1.Schema.natural().min(1).max(100).default(70).description('违禁词评分触发阈值:整条消息累计得分达到该值才触发管控(默认 70)。'),
|
|
34
|
+
strongKeywords: koishi_1.Schema.array(String).role('table').default([]).description('强关键词列表:命中即可触发管控,且【无视白名单豁免】。用于「有没有美女」这类与招新无关的骚扰/找对象话术——即使消息里带了「宣传部」等白名单词也照样命中,堵住「附一个白名单词即可绕过管控」的漏洞。支持“关键词|分值”语法,与违禁词共用同一评分阈值。'),
|
|
33
35
|
blockCardMessage: koishi_1.Schema.boolean().default(true).description('是否禁止卡片消息(json/xml)。'),
|
|
34
36
|
blockForwardMessage: koishi_1.Schema.boolean().default(true).description('是否禁止合并转发消息(forward)。'),
|
|
35
37
|
autoDeleteViolation: koishi_1.Schema.boolean().default(true).description('违规消息是否自动撤回。'),
|
|
@@ -39,6 +41,7 @@ exports.Config = koishi_1.Schema.intersect([
|
|
|
39
41
|
enableAiReply: koishi_1.Schema.boolean().description('该群是否启用 AI 回复(留空则跟随全局设置)。'),
|
|
40
42
|
bannedWords: koishi_1.Schema.array(String).role('table').default([]).description('该群专属违禁词列表(同样支持“关键词|分值”与顺序模糊匹配)。'),
|
|
41
43
|
whitelistKeywords: koishi_1.Schema.array(String).role('table').default([]).description('该群违禁词白名单:消息只要命中其中任意一个关键词,就整条跳过违禁词评分(用于校学生会招新等允许的宣传场景)。'),
|
|
44
|
+
strongKeywords: koishi_1.Schema.array(String).role('table').description('该群强关键词(留空则跟随全局设置)。命中后无视白名单豁免,用于堵住「附一个白名单词即可绕过管控」的漏洞。'),
|
|
42
45
|
whitelistOnlyOwners: koishi_1.Schema.boolean().default(false).description('白名单是否仅对群主/管理员生效。关闭时所有群成员命中白名单均可豁免。'),
|
|
43
46
|
blockCardMessage: koishi_1.Schema.boolean().default(true).description('该群是否禁止卡片消息(json/xml)。'),
|
|
44
47
|
blockForwardMessage: koishi_1.Schema.boolean().default(true).description('该群是否禁止合并转发消息(forward)。'),
|