Browse Source

feat: default close image summary

master
zhayujie 11 months ago
parent
commit
a12507abbd
3 changed files with 3 additions and 5 deletions
  1. +1
    -1
      plugins/linkai/README.md
  2. +1
    -1
      plugins/linkai/config.json.template
  3. +1
    -3
      plugins/linkai/linkai.py

+ 1
- 1
plugins/linkai/README.md View File

@@ -26,7 +26,7 @@
"enabled": true, # 文档总结和对话功能开关
"group_enabled": true, # 是否支持群聊开启
"max_file_size": 5000, # 文件的大小限制,单位KB,默认为5M,超过该大小直接忽略
"type": ["FILE", "SHARING", "IMAGE"] # 支持总结的类型,分别表示 文件、分享链接、图片
"type": ["FILE", "SHARING", "IMAGE"] # 支持总结的类型,分别表示 文件、分享链接、图片,其中文件和链接默认打开,图片默认关闭
}
}
```


+ 1
- 1
plugins/linkai/config.json.template View File

@@ -15,6 +15,6 @@
"enabled": true,
"group_enabled": true,
"max_file_size": 5000,
"type": ["FILE", "SHARING", "IMAGE"]
"type": ["FILE", "SHARING"]
}
}

+ 1
- 3
plugins/linkai/linkai.py View File

@@ -192,9 +192,7 @@ class LinkAI(Plugin):
return False
if context.kwargs.get("isgroup") and not self.sum_config.get("group_enabled"):
return False
support_type = self.sum_config.get("type")
if not support_type:
return True
support_type = self.sum_config.get("type") or ["FILE", "SHARING"]
if context.type.name not in support_type:
return False
return True


Loading…
Cancel
Save