Name | nonebot-plugin-text-ban JSON |
Version |
0.1.4
JSON |
| download |
home_page | None |
Summary | Default template for PDM package |
upload_time | 2024-12-22 04:40:29 |
maintainer | None |
docs_url | None |
author | None |
requires_python | >=3.10.0 |
license | MIT |
keywords |
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
<div align="center">
<a href="https://v2.nonebot.dev/store"><img src="https://github.com/A-kirami/nonebot-plugin-template/blob/resources/nbp_logo.png" width="180" height="180" alt="NoneBotPluginLogo"></a>
<br>
<p><img src="https://github.com/A-kirami/nonebot-plugin-template/blob/resources/NoneBotPlugin.svg" width="240" alt="NoneBotPluginText"></p>
</div>
<div align="center">
# nonebot-plugin-text-ban
_✨ 违禁词撤回 ✨_
</div>
什么?又有司马仔发tx的广告触发词了?快用它ban掉吧~
## 📖 介绍
一个基于Lagrange.OneBot和NoneBot的违禁词撤回插件
> [!WARNING]
> 该插件只能用Lagrange.OneBot作为协议端,其他协议端暂不支持
### 已实现的功能
- 违禁词撤回
- 误判申诉
- 图片检测
- 谐音检测
- 自动踢出
## 💿 安装
<details open>
<summary>使用 nb-cli 安装</summary>
在 nonebot2 项目的根目录下打开命令行, 输入以下指令即可安装
nb plugin install nonebot-plugin-text-ban
</details>
<details>
<summary>使用包管理器安装</summary>
在 nonebot2 项目的插件目录下, 打开命令行, 根据你使用的包管理器, 输入相应的安装命令
<details>
<summary>pip</summary>
pip install nonebot-plugin-text-ban
</details>
<details>
<summary>pdm</summary>
pdm add nonebot-plugin-text-ban
</details>
<details>
<summary>poetry</summary>
poetry add nonebot-plugin-text-ban
</details>
<details>
<summary>conda</summary>
conda install nonebot-plugin-txt_ban
</details>
打开 nonebot2 项目根目录下的 `pyproject.toml` 文件, 在 `[tool.nonebot]` 部分追加写入
plugins = ["nonebot_plugin_text_ban"]
</details>
## ⚙️ 配置
| 配置项 | 必填 | 默认值 | 说明 | 数据类型 |
|:-----:|:----:|:----:|:----:|:----:|
| strict | 否 | False | 严格模式(一个一个字检测,例如你的违禁词是 "你好",如果开了这项,那么只要消息中包含“你”和“好”,那么就会撤回) | bool |
| ocr | 否 | False | 检测图片中的违禁词(精度稍低) | bool |
| pinyin | 否 | False | 检测谐音字 | bool |
| kick | 否 | False | 是否自动踢出(群员触发3次违禁词后自动踢出 | bool |
## 🎉 使用
### 指令表
| 指令 | 权限 | 需要@ | 范围 | 说明 |
|:-----:|:----:|:----:|:----:|:----:|
| help | 管理/群主/主人 | 否 | all | 插件帮助(需要加上命令头) |
| add [text] [type] | 管理/群主/主人 | 是 | all | 添加违禁词,text代表违禁词,type代表模式,目前可选1(精确),2(模糊) |
| del [text] [type] | 管理/群主/主人 | 是 | all | 删除违禁词,text代表违禁词,type代表模式,目前可选1(精确),2(模糊) |
| add_group [group_id?] | 管理/群主/主人 | 否 | all | 开启本插件,group_id代表群号,不填则默认为当前群(如果是私聊的话得加上group_id) |
| del_group [group_id?] | 管理/群主/主人 | 否 | all | 关闭本插件,group_id代表群号,不填则默认为当前群(如果是私聊的话得加上group_id) |
| appeal | all | 否 | 私聊 | 当机器人误判违禁词时,可发送此指令以申诉 |
| operate [同意/拒绝] [user_id] [ban?] | 管理/群主/主人 | 是 | 私聊 | 同意/拒绝申诉,ban代表是否踢出,目前可选t(踢出),tm(踢出且不接受此人申请)不填则不踢出|
Raw data
{
"_id": null,
"home_page": null,
"name": "nonebot-plugin-text-ban",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.10.0",
"maintainer_email": null,
"keywords": null,
"author": null,
"author_email": "zhongwen-4 <2401128923@qq.com>",
"download_url": "https://files.pythonhosted.org/packages/e9/39/0789ce4d4cb81e035022e4eb97dce956a0c9510fd09074a76ff9ee20ad18/nonebot_plugin_text_ban-0.1.4.tar.gz",
"platform": null,
"description": "<div align=\"center\">\n <a href=\"https://v2.nonebot.dev/store\"><img src=\"https://github.com/A-kirami/nonebot-plugin-template/blob/resources/nbp_logo.png\" width=\"180\" height=\"180\" alt=\"NoneBotPluginLogo\"></a>\n <br>\n <p><img src=\"https://github.com/A-kirami/nonebot-plugin-template/blob/resources/NoneBotPlugin.svg\" width=\"240\" alt=\"NoneBotPluginText\"></p>\n</div>\n\n<div align=\"center\">\n\n# nonebot-plugin-text-ban\n\n_\u2728 \u8fdd\u7981\u8bcd\u64a4\u56de \u2728_\n\n</div>\n\n\u4ec0\u4e48\uff1f\u53c8\u6709\u53f8\u9a6c\u4ed4\u53d1tx\u7684\u5e7f\u544a\u89e6\u53d1\u8bcd\u4e86\uff1f\u5feb\u7528\u5b83ban\u6389\u5427~\n\n## \ud83d\udcd6 \u4ecb\u7ecd\n\n\u4e00\u4e2a\u57fa\u4e8eLagrange.OneBot\u548cNoneBot\u7684\u8fdd\u7981\u8bcd\u64a4\u56de\u63d2\u4ef6\n\n> [!WARNING]\n> \u8be5\u63d2\u4ef6\u53ea\u80fd\u7528Lagrange.OneBot\u4f5c\u4e3a\u534f\u8bae\u7aef\uff0c\u5176\u4ed6\u534f\u8bae\u7aef\u6682\u4e0d\u652f\u6301\n\n### \u5df2\u5b9e\u73b0\u7684\u529f\u80fd\n\n- \u8fdd\u7981\u8bcd\u64a4\u56de\n- \u8bef\u5224\u7533\u8bc9\n- \u56fe\u7247\u68c0\u6d4b\n- \u8c10\u97f3\u68c0\u6d4b\n- \u81ea\u52a8\u8e22\u51fa\n\n## \ud83d\udcbf \u5b89\u88c5\n\n<details open>\n<summary>\u4f7f\u7528 nb-cli \u5b89\u88c5</summary>\n\u5728 nonebot2 \u9879\u76ee\u7684\u6839\u76ee\u5f55\u4e0b\u6253\u5f00\u547d\u4ee4\u884c, \u8f93\u5165\u4ee5\u4e0b\u6307\u4ee4\u5373\u53ef\u5b89\u88c5\n\n nb plugin install nonebot-plugin-text-ban\n\n</details>\n\n<details>\n<summary>\u4f7f\u7528\u5305\u7ba1\u7406\u5668\u5b89\u88c5</summary>\n\u5728 nonebot2 \u9879\u76ee\u7684\u63d2\u4ef6\u76ee\u5f55\u4e0b, \u6253\u5f00\u547d\u4ee4\u884c, \u6839\u636e\u4f60\u4f7f\u7528\u7684\u5305\u7ba1\u7406\u5668, \u8f93\u5165\u76f8\u5e94\u7684\u5b89\u88c5\u547d\u4ee4\n\n<details>\n<summary>pip</summary>\n\n pip install nonebot-plugin-text-ban\n</details>\n<details>\n<summary>pdm</summary>\n\n pdm add nonebot-plugin-text-ban\n</details>\n<details>\n<summary>poetry</summary>\n\n poetry add nonebot-plugin-text-ban\n</details>\n<details>\n<summary>conda</summary>\n\n conda install nonebot-plugin-txt_ban\n</details>\n\n\u6253\u5f00 nonebot2 \u9879\u76ee\u6839\u76ee\u5f55\u4e0b\u7684 `pyproject.toml` \u6587\u4ef6, \u5728 `[tool.nonebot]` \u90e8\u5206\u8ffd\u52a0\u5199\u5165\n\n plugins = [\"nonebot_plugin_text_ban\"]\n\n</details>\n\n## \u2699\ufe0f \u914d\u7f6e\n\n| \u914d\u7f6e\u9879 | \u5fc5\u586b | \u9ed8\u8ba4\u503c | \u8bf4\u660e | \u6570\u636e\u7c7b\u578b |\n|:-----:|:----:|:----:|:----:|:----:|\n| strict | \u5426 | False | \u4e25\u683c\u6a21\u5f0f\uff08\u4e00\u4e2a\u4e00\u4e2a\u5b57\u68c0\u6d4b\uff0c\u4f8b\u5982\u4f60\u7684\u8fdd\u7981\u8bcd\u662f \"\u4f60\u597d\"\uff0c\u5982\u679c\u5f00\u4e86\u8fd9\u9879\uff0c\u90a3\u4e48\u53ea\u8981\u6d88\u606f\u4e2d\u5305\u542b\u201c\u4f60\u201d\u548c\u201c\u597d\u201d\uff0c\u90a3\u4e48\u5c31\u4f1a\u64a4\u56de\uff09 | bool |\n| ocr | \u5426 | False | \u68c0\u6d4b\u56fe\u7247\u4e2d\u7684\u8fdd\u7981\u8bcd\uff08\u7cbe\u5ea6\u7a0d\u4f4e\uff09 | bool |\n| pinyin | \u5426 | False | \u68c0\u6d4b\u8c10\u97f3\u5b57 | bool |\n| kick | \u5426 | False | \u662f\u5426\u81ea\u52a8\u8e22\u51fa\uff08\u7fa4\u5458\u89e6\u53d13\u6b21\u8fdd\u7981\u8bcd\u540e\u81ea\u52a8\u8e22\u51fa | bool |\n\n## \ud83c\udf89 \u4f7f\u7528\n### \u6307\u4ee4\u8868\n| \u6307\u4ee4 | \u6743\u9650 | \u9700\u8981@ | \u8303\u56f4 | \u8bf4\u660e |\n|:-----:|:----:|:----:|:----:|:----:|\n| help | \u7ba1\u7406/\u7fa4\u4e3b/\u4e3b\u4eba | \u5426 | all | \u63d2\u4ef6\u5e2e\u52a9\uff08\u9700\u8981\u52a0\u4e0a\u547d\u4ee4\u5934\uff09 |\n| add [text] [type] | \u7ba1\u7406/\u7fa4\u4e3b/\u4e3b\u4eba | \u662f | all | \u6dfb\u52a0\u8fdd\u7981\u8bcd\uff0ctext\u4ee3\u8868\u8fdd\u7981\u8bcd\uff0ctype\u4ee3\u8868\u6a21\u5f0f\uff0c\u76ee\u524d\u53ef\u90091\uff08\u7cbe\u786e\uff09\uff0c2\uff08\u6a21\u7cca\uff09 |\n| del [text] [type] | \u7ba1\u7406/\u7fa4\u4e3b/\u4e3b\u4eba | \u662f | all | \u5220\u9664\u8fdd\u7981\u8bcd\uff0ctext\u4ee3\u8868\u8fdd\u7981\u8bcd\uff0ctype\u4ee3\u8868\u6a21\u5f0f\uff0c\u76ee\u524d\u53ef\u90091\uff08\u7cbe\u786e\uff09\uff0c2\uff08\u6a21\u7cca\uff09 |\n| add_group [group_id?] | \u7ba1\u7406/\u7fa4\u4e3b/\u4e3b\u4eba | \u5426 | all | \u5f00\u542f\u672c\u63d2\u4ef6\uff0cgroup_id\u4ee3\u8868\u7fa4\u53f7\uff0c\u4e0d\u586b\u5219\u9ed8\u8ba4\u4e3a\u5f53\u524d\u7fa4\uff08\u5982\u679c\u662f\u79c1\u804a\u7684\u8bdd\u5f97\u52a0\u4e0agroup_id\uff09 |\n| del_group [group_id?] | \u7ba1\u7406/\u7fa4\u4e3b/\u4e3b\u4eba | \u5426 | all | \u5173\u95ed\u672c\u63d2\u4ef6\uff0cgroup_id\u4ee3\u8868\u7fa4\u53f7\uff0c\u4e0d\u586b\u5219\u9ed8\u8ba4\u4e3a\u5f53\u524d\u7fa4\uff08\u5982\u679c\u662f\u79c1\u804a\u7684\u8bdd\u5f97\u52a0\u4e0agroup_id\uff09 |\n| appeal | all | \u5426 | \u79c1\u804a | \u5f53\u673a\u5668\u4eba\u8bef\u5224\u8fdd\u7981\u8bcd\u65f6\uff0c\u53ef\u53d1\u9001\u6b64\u6307\u4ee4\u4ee5\u7533\u8bc9 |\n| operate [\u540c\u610f/\u62d2\u7edd] [user_id] [ban?] | \u7ba1\u7406/\u7fa4\u4e3b/\u4e3b\u4eba | \u662f | \u79c1\u804a | \u540c\u610f/\u62d2\u7edd\u7533\u8bc9\uff0cban\u4ee3\u8868\u662f\u5426\u8e22\u51fa\uff0c\u76ee\u524d\u53ef\u9009t\uff08\u8e22\u51fa\uff09\uff0ctm\uff08\u8e22\u51fa\u4e14\u4e0d\u63a5\u53d7\u6b64\u4eba\u7533\u8bf7\uff09\u4e0d\u586b\u5219\u4e0d\u8e22\u51fa|\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Default template for PDM package",
"version": "0.1.4",
"project_urls": null,
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "1c855945d32d3a597d1d62da460e5cbd45a679cd8615f1d5e1f662138fa278c9",
"md5": "1532c39c12e80cc6ba30727ea1f9fdad",
"sha256": "2c5b982f0a93937af72c4070cfcc4059ca397de023490ce99f957fc11bcfb495"
},
"downloads": -1,
"filename": "nonebot_plugin_text_ban-0.1.4-py3-none-any.whl",
"has_sig": false,
"md5_digest": "1532c39c12e80cc6ba30727ea1f9fdad",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.10.0",
"size": 7219,
"upload_time": "2024-12-22T04:40:27",
"upload_time_iso_8601": "2024-12-22T04:40:27.807729Z",
"url": "https://files.pythonhosted.org/packages/1c/85/5945d32d3a597d1d62da460e5cbd45a679cd8615f1d5e1f662138fa278c9/nonebot_plugin_text_ban-0.1.4-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "e9390789ce4d4cb81e035022e4eb97dce956a0c9510fd09074a76ff9ee20ad18",
"md5": "eee054f12aa92adb4c1626611762fdf6",
"sha256": "bab82831ede3cf7742e1605ca1a135b89d1b6925248f1ea55c0e5555d80cc274"
},
"downloads": -1,
"filename": "nonebot_plugin_text_ban-0.1.4.tar.gz",
"has_sig": false,
"md5_digest": "eee054f12aa92adb4c1626611762fdf6",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.10.0",
"size": 7884,
"upload_time": "2024-12-22T04:40:29",
"upload_time_iso_8601": "2024-12-22T04:40:29.921652Z",
"url": "https://files.pythonhosted.org/packages/e9/39/0789ce4d4cb81e035022e4eb97dce956a0c9510fd09074a76ff9ee20ad18/nonebot_plugin_text_ban-0.1.4.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-12-22 04:40:29",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "nonebot-plugin-text-ban"
}