Skip to main content

NoneBot 复读行为统计插件

Project description

nonebot-plugin-repeater-count

✨ 群聊复读行为统计插件 ✨

功能说明

自动记录规则

  • 连续两条相同消息且由不同用户发送时,视为有效复读行为
  • 自动记录以下三类数据:
    • 📊 复读用户(触发复读行为的用户)
    • 😇 被复读用户(原始消息发送者)
    • 🔠 复读词汇(被复读的原始消息内容)

统计时段说明

支持四种时间维度统计,基于自然时间划分:

时段类型 说明 重置时间
total 总统计(默认) 永不重置
year 年度统计 每年1月1日 00:00
month 月度统计 每月1日 00:00
day 每日统计 每天 00:00

可用命令列表

命令格式 功能说明 示例
/复读排行 [时段类型] 查看复读用户排行榜 /复读排行 month
/被复读排行 [时段类型] 查看被复读用户排行榜 /受害者排行 day
/复读词排行 [时段类型] 查看复读热词排行榜 /复读词排行 year

排行榜特性

  • 默认显示TOP 10排名
  • 相同次数按字母/数字顺序排列
  • 数据实时更新,即时反映最新复读情况

安装方式

使用 nb-cli 安装:

nb plugin install nonebot-plugin-repeater-count

或使用 pip 安装:

pip install nonebot-plugin-repeater-count

使用示例

基础使用

/复读排行
👉 显示总排行榜(total)

/复读统计 month
👉 显示本月复读排行

/被复读排行 day
👉 显示今日被复读用户排行

/复读词排行
👉 显示历史所有复读热词

典型输出格式

[total] 时段的复读机排行榜:

  1. 用户A - 42次
  2. 用户B - 38次
  3. 用户C - 35次

...

注意事项

⚠️ 重要说明

需要 OneBot V11 适配器支持

仅统计群聊消息,私聊消息不会触发记录

数据存储在 data/repeater_data.json 文件,重启后数据保留

每日0点自动重置日统计,每月/年同理

消息对比为纯文本比对(忽略图片/表情等富媒体内容)

🔒 数据存储方式:

使用 JSON 格式本地存储

自动创建 data 目录存放数据文件

采用 UTF-8 编码确保兼容性

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nonebot_plugin_repeater_count-0.1.2.tar.gz (6.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

File details

Details for the file nonebot_plugin_repeater_count-0.1.2.tar.gz.

File metadata

File hashes

Hashes for nonebot_plugin_repeater_count-0.1.2.tar.gz
Algorithm Hash digest
SHA256 2a36ac50ad70034f9e5e6ef0c85a084aa4485c57355dd377b07b92e1f73b869a
MD5 a278e449f2987ce981c7935d6d15ba83
BLAKE2b-256 78eb169c4459b1b635f7bf9663d5ec7413e284b5b39d0846aad860bc6fee61b3

See more details on using hashes here.

Provenance

The following attestation bundles were made for nonebot_plugin_repeater_count-0.1.2.tar.gz:

Publisher: python-publish.yml on name-is-hard-to-make/nonebot-plugin-repeater-count

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file nonebot_plugin_repeater_count-0.1.2-py3-none-any.whl.

File metadata

File hashes

Hashes for nonebot_plugin_repeater_count-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 f8f7144101ee5570a881685193807840ba066be37b7cde3707b378c6e685e31d
MD5 228b3202f507cff58bff746ce98e664c
BLAKE2b-256 dfea4eb3fd0d15bbddce18cd19d58d508f10740b47e0c71b2e63111063349562

See more details on using hashes here.

Provenance

The following attestation bundles were made for nonebot_plugin_repeater_count-0.1.2-py3-none-any.whl:

Publisher: python-publish.yml on name-is-hard-to-make/nonebot-plugin-repeater-count

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page