npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

koishi-plugin-clag

v0.1.0

Published

功能丰富的禁言插件,提供了多种手动和自动禁言模式,增加了群组管理的趣味性和多样性。

Readme

koishi-plugin-clag

npm

功能丰富的禁言插件,提供了多种手动和自动禁言模式,增加了群组管理的趣味性和多样性。

📖 介绍

不仅仅是一个简单的禁言工具。它内置了多种禁言模式,你可以选择带有概率反噬的趣味禁言,也可以设置两败俱伤的模式。此外,插件还包含了“禁言轮盘”和“自我禁言”等娱乐指令。

除了手动指令,插件还具备强大的自动监听功能,可以设置为: 复读禁言:当群内出现多人复读时,自动禁言参与者。 随机禁言:在指定时间段内,每条消息都有一定概率触发对发送者的禁言。

所有功能的消息提示、禁言时长、触发概率等均支持高度自定义,让你能够根据自己的需求灵活配置。

✨ 功能特性

多种手动禁言模式 概率反噬 (random_success):执行禁言时,有一定概率禁言成功,否则将反噬自己。 两败俱伤 (both_mute):执行禁言时,必定会禁言目标,但自己也会被一起禁言。 娱乐性子命令 禁言轮盘 (clag.biu):玩一次轮盘赌,看看谁是下一个幸运儿(或倒霉蛋)。 自我禁言 (clag.me):主动申请禁言自己一段时间。 智能监听禁言 复读监听 (repeat):自动检测群内的复读行为,并根据配置禁言最后几个或随机几个参与者。 随机监听 (random):在设定的时间段内(如午夜),开启随机禁言模式,为群聊带来更多不确定性。 高度可配置 自定义最大禁言时长。 可选择固定概率或递增概率模式。 自定义所有场景下的成功与失败消息。 支持 {at}, {username}, {duration} 等消息占位符。 可设定监听模式的生效时间段。

🚀 命令说明

clag <target:text> [duration:number]

核心禁言指令。 target: 目标用户,可以是 @某人 或用户的 QQ 号。 duration: (可选) 禁言时长(单位:分钟)。如果未提供,将使用随机时长。 行为: 根据配置的 clagMode (禁言模式) 执行。

clag.biu

禁言轮盘。 执行此命令有概率禁言自己。 如果配置为递增概率模式,每次安全后,下次触发的概率会增加。

clag.me [duration:number]

自我禁言。 duration: (可选) 禁言时长(单位:分钟)。如果未提供,将使用随机时长。

⚙️ 配置项

开关配置

| 配置项 | 类型 | 默认值 | 描述 | | :--- | :--- | :--- | :--- | | clagEnabled | boolean | true | 是否启用 clag 手动禁言相关指令。 | | listenMode | string | 'off' | 监听禁言模式。可选值:off (关闭), repeat (复读禁言), random (随机禁言)。 | | listenTime | string | '22-6' | 监听模式生效的时段,格式为 "开始小时-结束小时"。例如 "22-6" 表示晚上10点到次日早上6点。 |

功能配置

| 配置项 | 类型 | 默认值 | 描述 | | :--- | :--- | :--- | :--- | | maxDuration | number | 15 | 最大禁言时长(分钟)。 | | probabilityInitial | number | 0.05 | 各种随机事件的初始概率 (0 到 1之间)。 | | probabilityMode | string | 'fixed' | 概率模式。可选值:fixed (固定概率), increasing (递增概率,失败后会增加)。 | | clagMode | string | 'random_success' | clag 指令的禁言模式。可选值:random_success (概率反噬), both_mute (两败俱伤)。 | | repeatMuteTarget | numberstring | 1 | 复读禁言的目标。如果是数字,则禁言最后几个参与者;如果是字符串形式的数字(如 '2'),则随机禁言对应数量的参与者。 |

消息配置

| 配置项 | 类型 | 默认值 | 描述 | | :--- | :--- | :--- | :--- | | showMessage | boolean | true | 是否在执行禁言后发送消息提示。 | | Message | Array | (见下方) | 禁言提示消息模板。 |

Message 默认配置示例:

[
  {"Success": "{at}被禁言{duration}", "Failure": "禁言失败!作为惩罚,{at}被禁言{duration}"},
  {"Success": "成功禁言{username}{duration}!", "Failure": "{username}你太倒霉了,被禁言{duration}"},
  {"Success": "{username}获得了{duration}的沉默术", "Failure": "禁言魔法反噬,{username}被禁言{duration}"}
]

Success: 禁言成功时(通常指目标被禁言)发送的消息。 Failure: 禁言失败时(通常指自己被禁言)发送的消息。 可用占位符: {at}: @消息的接收者。 {username}: 消息接收者的昵称。 {duration}: 格式化后的禁言时长 (例如 "5分钟", "1小时30分钟")。