
Security News
TypeScript is Porting Its Compiler to Go for 10x Faster Builds
TypeScript is porting its compiler to Go, delivering 10x faster builds, lower memory usage, and improved editor performance for a smoother developer experience.
nonebot-plugin-dialectlist
Advanced tools
通过pip
或nb
安装:
pip install nonebot-plugin-dialectlist
nb plugin install nonebot-plugin-dialectlist
⚠注意 若先前没有安装过nonebot-plugin-chatrecorder
或者nonebot-plugin-orm
,则会在启动时报错,请按报错的提示安装数据库!
需要提前配置本插件所依赖的插件!
在 .env 中,可以添加以下配置项
dialectlist__get_num: int = 5 # 获取人数数量
dialectlist__font: str = "SimHei" # 字体格式
dialectlist__suffix: bool = True # 是否显示后缀
dialectlist__excluded_self: bool = True # 是否排除自己
dialectlist__visualization: bool = True # 是否可视化
dialectlist__show_text_rank: bool = True # 是否显示文本排名
dialectlist__counting_cache: bool = False # 计数缓存(能够提高回复速度)
dialectlist__excluded_people: List[str] = [] # 排除的人的QQ号
dialectlist__use_user_info_cache: bool = False # 是否使用用户信息缓存
dialectlist__aggregate_transmission: bool = False # 是否聚合转发消息
dialectlist__timezone: Optional[str] = "Asia/Shanghai" # 时区,影响统计时间
dialectlist__string_suffix: str = "统计花费时间:{timecost}秒" # 消息格式后缀
dialectlist__template_path: str = "./template/rank_template.j2" # 模板路径
dialectlist__string_format: str = "第{index}名:\n{nickname},{chatdatanum}条消息\n" # 消息格式
💭也可以不进行配置,这将会使插件按照默认配置运行
在旧版插件(2.0.0 以下)中,dialectlist 与后面的配置项只隔了一个下划线,若更新到新版本以后需要俩个下划线。
由于插件依赖chatrecord多次引入爆炸性修改,建议在遇到问题后优先尝试降级chatrecord插件
!!注意!!
新版本指令调用方式改变,改为更易理解也更好打的 B 话榜。
同时也可以用类似 /今日废话榜
的方式(只要改前面的就好了)(算是给 盘古之白 风格爱好者的福利吧?)
-/B话榜
————看看有史以来(机器人存在以来)群友们发了多少消息! (好像没写)
-/今日B话榜
————看看今天的群友发了多少消息!
-/昨日B话榜
————看看昨天的群友发了多少消息!
-/前日B话榜
————看看前天的群友发了多少消息!
-/本周B话榜
————看看本周的群友发了多少消息!
-/上周B话榜
————看看上周的群友发了多少消息!
-/本月B话榜
————看看这个月的群友发了多少消息!
-/年度B话榜
————看看今年的群友发了多少消息!
-/历史B话榜
————看看历史上(机器人存在以来)的群友发了多少消息!
-/看看B话 [@某人|QQ号]
————看看这个b人在这个b群发了多少b话!
/{时间类型(今日|年度)?}{B话榜|废话榜} {时间类型?} {ISO8601 格式时间 ?} {群号} {关键词}
如:/B话榜 历史 2024-01-01~2024-01-02 12345678 女装
也可以 /{时间类型(今日|年度)?}{B话榜|废话榜} {时间类型?} {ISO8601 格式时间 ?} -g {群号} -k {关键词}
以下调用方法均合法:
/今日B话榜 -g 12345678 -k 女装
/昨日B话榜 -k 女装
/本周B话榜 -g 12345678
/看看B话 {@|QQ号} {群号?} {关键词?}
以下调用方法均合法:
/kkb 114514 1919810 ♂
/kkb @man -k ♂
[!IMPORTANT] 关键词支持正则表达式!
平台 | 是否经过测试 | 是否能够正常工作 | 测试环境 |
---|---|---|---|
Onebot | ✅ | ✅ | NapCat + Window11 |
飞书 | ❌ | ❓ | 🤔 |
Red | ❌ | ❓ | 🤔 |
DoDo | ❌ | ❓ | 🤔 |
Mirai | ❌ | ❓ | 🤔 |
开黑啦 | ❌ | ❓ | 🤔 |
Kritor | ❌ | ❓ | 🤔 |
Ntchat | ❌ | ❓ | 🤔 |
Satori | ❌ | ❓ | 🤔 |
Telegram | ❌ | ❓ | 🤔 |
Discord | ❌ | ❓ | 🤔 |
Tailchat | ❌ | ❓ | 🤔 |
QQ 官方接口 | ❌ | ❓ | 🤔 |
Rocket.Chat | ❌ | ❓ | 🤔 |
本插件的__init__.py 中的处理函数参考了词云中的方法 (其实大部分都是 Ctrl+C Ctr+V)
感谢以下开发者作出的贡献:
适配全平台
更好看的图片渲染
添加一些全新的可配置项
尝试利用 jinja2 模板引擎制作可视化图片
私聊的查询(超级用户可以任意查询群聊的信息)一半完成
特殊的储存方案优化消息统计
查询带某关键词的消息量
合并转发
待补充。.....
整个项目快被我写成屎山了
FAQs
We found that nonebot-plugin-dialectlist demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
TypeScript is porting its compiler to Go, delivering 10x faster builds, lower memory usage, and improved editor performance for a smoother developer experience.
Research
Security News
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
Security News
Socket CEO Feross Aboukhadijeh discusses the open web, open source security, and how Socket tackles software supply chain attacks on The Pair Program podcast.