返回顶部
b

birthday-reminder生日提醒

Manage birthdays with natural language. Store birthdays in /home/clawd/clawd/data/birthdays.md, get upcoming reminders, calculate ages. Use when the user mentions birthdays, wants to add/remember someone's birthday, check upcoming birthdays, or asks about someone's age/birthday. Understands phrases like "X hat am DD.MM. Geburtstag", "Wann hat X Geburtstag?", "Nächste Geburtstage".

作者: admin | 来源: ClawHub
源自
ClawHub
版本
V 1.0.0
安全检测
已通过
2,522
下载量
免费
免费
1
收藏
概述
安装方式
版本历史

birthday-reminder

生日提醒技能

自然地管理生日。存储在 data/birthdays.md 中,支持自然语言查询。

存储

生日存储在 /home/clawd/clawd/data/birthdays.md 中:

markdown

生日

  • - 瓦伦蒂娜 - 14.02.2000(将满26岁)
  • 马克斯 - 15.03.1990

自然语言模式

添加生日

当用户说出类似:
  • - 瓦伦蒂娜的生日是2月14日
  • 添加:马克斯,1990年3月15日
  • X出生于1985年5月10日

操作:

  1. 1. 解析姓名和日期
  2. 提取年份(如有提供)
  3. 计算即将到来的年龄:生日年份 - 出生年份
  4. 追加到 /home/clawd/clawd/data/birthdays.md
  5. 确认并附带年龄信息

查询生日

当用户询问:
  • - 瓦伦蒂娜的生日是什么时候?
  • 接下来有哪些生日?
  • 瓦伦蒂娜将满多少岁?
  • 下一个生日

操作:

  1. 1. 读取 /home/clawd/clawd/data/birthdays.md
  2. 解析所有条目
  3. 计算距离每个生日的天数
  4. 按即将到来的日期排序
  5. 如果知道年份,显示将满的年龄

列出所有

当用户说:
  • - 显示所有生日
  • 列出我的生日

操作:

  1. 1. 读取文件
  2. 显示格式化列表,附带距离每个生日的天数

日期解析

支持多种格式:

  • - 2月14日 → 14.02
  • 14.02. → 14.02
  • 14.02.2000 → 14.02.2000
  • 14.2.2000 → 14.02.2000

年龄计算

python
from datetime import datetime

def calculateturningage(birthyear, birthdaymonth, birthday_day):
today = datetime.now()
birthdaythisyear = today.replace(month=birthdaymonth, day=birthdayday)

if today.date() <= birthdaythisyear.date():
birthday_year = today.year
else:
birthday_year = today.year + 1

return birthdayyear - birthyear

距离生日的天数

python
def days_until(month, day):
today = datetime.now()
birthday = today.replace(month=month, day=day)
if birthday < today:
birthday = birthday.replace(year=today.year + 1)
return (birthday - today).days

自动提醒

用于定时任务/提醒,每日检查生日并在以下时间通知:

  • - 提前7天
  • 提前1天
  • 当天

使用 scripts/reminder.py 中的 check_reminders() 逻辑。

文件格式

每行:- 姓名 - DD.MM.YYYY(将满X岁) 或 - 姓名 - DD.MM.

保持文件按日期(月/日)排序,以便于阅读。

标签

skill ai

通过对话安装

该技能支持在以下平台通过对话安装:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 birthday-reminder-1776375164 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 birthday-reminder-1776375164 技能

通过命令行安装

skillhub install birthday-reminder-1776375164

下载

⬇ 下载 birthday-reminder v1.0.0(免费)

文件大小: 5.36 KB | 发布时间: 2026-4-17 15:05

v1.0.0 最新 2026-4-17 15:05
Birthday Reminder Skill initial release.

- Manage birthdays using natural language input.
- Store birthdays in `/home/clawd/clawd/data/birthdays.md`.
- Add, query, and list birthdays, including parsing dates in multiple formats.
- Calculate current age and days until upcoming birthdays.
- Supports automatic reminders for birthdays (7 days before, 1 day before, and on the day).
- Returns formatted, sorted lists of birthdays with relevant info.

SKILL.md
• scripts/birthday.py
• scripts/reminder.py
• references/ (Ordner)

Archiver·手机版·闲社网·闲社论坛·羊毛社区· 多链控股集团有限公司 · 苏ICP备2025199260号-1

Powered by Discuz! X5.0   © 2024-2025 闲社网·线报更新论坛·羊毛分享社区·http://xianshe.com

p2p_official_large
返回顶部