Lightweight Telegram Keyword Alert Bot for Personal Use

Preface I previously used a Telegram keyword alert bot project . After using it, I felt the functionality was a bit heavy. The original project was designed for multi-user use, where different users follow different keywords and different groups. Therefore, the original project required a database. I plan to develop a lightweight Telegram keyword alert bot suitable for personal use. I'll write the code with the help of the powerful GPT. The first version of the code was generated using the free Claude. Subsequent code debugging was done using the free M$ Copilot. Designed Features The bot only accepts control commands from users or groups with specified IDs,  After the bot detects a keyword, it sends a notification message to the user, group, or channel with the specified ID, The list of followed keywords supports regular expressions The list of excluded keywords supports regular expressions Both the list of followed keywords and the list of excluded keywords are updated and saved ...

开发电报关键词提醒机器人 telegram keyword monitor bot

前言 之前使用了一个 电报关键词提醒机器人项目 . 使用下来觉得功能有点重. 原项目考虑到多人使用, 不同的用户关注不同的关键字和不同的群组. 所以原项目需要用到数据库. 我准备自己开发一个轻量的适合个人使用的电报关键词提醒机器人. 借助现在强大的gpt的力量写代码. 第一版代码生成是用的免费的 claude 后续代码调试是用的免费的 M$ copilot

Fixing NBSP Issue in Blogger Code Block Copy Button

In the previous post I mentioned discovering that the code blocks in my blog posts may contain NBSP issues. Today I happened to discover that clicking the copy button on a code block yields a result that contains NBSP. For example, the following. Selecting with the mouse and copying from the right-click menu gives the result on the left. Clicking the copy button on the code block gives the result on the right. (Contains some NBSP characters) I took my code and the problem description to ask Claude. Solution 1: Change innerText to textContent Implementation https://crazypeace.github.io/blogger-replace-blockquote-to-pre/blockquote-add-copy-button1.js The test result was wrong. Not only did it still contain NBSP, but the line breaks were also gone. I took the above problem and continued asking Claude

Blogger/blogspot 不换行空格NBSP问题的后续

上一篇讲到我发现了我的博文的代码段有可能含有NBSP的问题. 今天偶然发现, 复制代码段的按钮, 得到的结果会含有NBSP. 比如, 下面的例子. 用鼠标选择, 右键菜单复制, 得到的结果是左边的. 点击代码段的复制按钮, 得到的结果是右边的. (包含一些NBSP字符) 我拿我的代码和问题描述去问 claude. 方案1 将innerText改为textContent 具体实施 https://crazypeace.github.io/blogger-replace-blockquote-to-pre/blockquote-add-copy-button1.js 测试结果不对. 不仅继续含有NBSP, 而且换行也没有了. 拿上面的问题继续问 claude

SillyTavern World Book: Force Chinese Output for All Cards

Previously, we implemented making SillyTavern output Chinese . However, when searching for / trying out character cards, we often need to try a large number of them, and some character cards you just don't want to continue using after saying a sentence or two. If you have to go through that operation to output Chinese for every single character card, it would feel a bit troublesome. So, is there any way to set it up once and apply it to every character card? We can use the World Book (Lorebooks) feature. In the SillyTavern interface, click World Book - New Use any name you like * This name is only for management convenience. It does not affect the final effect. At this point, you should see the World Book you just created selected. (If not, you need to select it from the dropdown menu) Then click the New Entry button on the right Configure this new entry 1. The entry's title, set whatever you want. * This title is only for management convenience, it does not affect the final ef...

酒馆SillyTavern 玩英文角色卡 也能以中文输出 设置世界书Lorebooks

之前 我们实现了 让酒馆SillyTavern输出中文 . 不过, 我们在寻找/试用角色卡的时候, 常常要试用大量的角色卡, 而有些角色卡你说上一两句话就不想继续用了. 如果每个角色卡都那样操作一遍输出中文的话, 会觉得有点麻烦. 那么, 有没有什么方法可以设置一次, 就应用到每一个角色卡呢? 我们可以使用 世界书Lorebooks 这个功能.