← Back to Skills Marketplace
liumeixin

Family Ledger

by liumeixin · GitHub ↗ · v1.0.1 · MIT-0
cross-platform ⚠ suspicious
155
Downloads
0
Stars
0
Active Installs
2
Versions
Install in OpenClaw
/install family-ledger
Description
家庭账本管理技能 - 日常记账、人情往来、借款报销
README (SKILL.md)

Family Ledger - 家庭账本

记账技能,全家人可以通过不同渠道使用。


账本文件位置

~/.openclaw/workspace/shared/ledger/
├── daily.json    # 日常账本
├── social.json   # 人情账本
└── borrow.json   # 借款报销账本

日常账本 (daily.json)

字段

字段 类型 说明
date string 日期,格式 YYYY-MM-DD
type string 类型:收入 / 支出
amount number 金额
category string 类别
recorded_by string 记录人:设计虱 / 大脸鱼
house string 房屋(可选):军龙苑/保利大都会/东方文创园/洛铜嘉苑/龙锦嘉园
child string 孩子(教育类别可选):根据用户设置
note string 备注

类别

支出:餐饮、交通、购物、工资、房租、水电、通讯、医疗、教育、娱乐、房屋维护、其他

收入:工资、奖金、投资、兼职、礼金、其他

教育类别特殊处理

当备注中包含教育相关关键词时(书本费、辅导书、辅导班、兴趣班、文具、学费、培训等):

  • 自动归类为"教育"
  • 新增 child 字段记录是给哪个孩子

孩子信息初始化

  • 首次记录教育类费用时,询问用户"家里有几个孩子?他们的昵称是什么?"
  • 只有一个孩子 → 默认记录在该孩子名下
  • 多个孩子 → 引导用户以后记录时说明是哪个孩子(如"记一笔教育账:200 学而思 给老大")

当前用户孩子信息

  • 果果(唯一孩子)
  • 家庭关系:大脸鱼是果果的妈妈,大脸鱼记教育账也记到果果名下

房屋与类别联动

当备注中包含以下地点时:

  • 军龙苑、保利大都会、东方文创园、洛铜嘉苑、龙锦嘉园
  • 自动归类为"房屋维护",并在 house 字段记录房屋名

人情账本 (人情.json)

字段

字段 类型 说明
date string 日期,格式 YYYY-MM-DD
type string 类型:压岁钱 / 随礼 / 其他
target string 给谁(谁收钱)
giver string 谁给的
giver_child string 给出方的孩子名字
amount number 金额
note string 备注

借款报销账本 (borrow.json)

字段

字段 类型 说明
date string 日期,格式 YYYY-MM-DD
type string 类型:借款 / 报销
direction string 方向:借出 / 借入 / 报销给我 / 我报销
person string 相关人
amount number 金额
due_date string 应还/应报销日期(可选)
status string 状态:未还 / 已还 / 待报销 / 已报销
note string 备注

用户ID映射

飞书用户ID与记录人对应关系:

~/.openclaw/workspace/shared/ledger/user-mapping.json

文件内容示例:

{
  "ou_7d82888fe950c222c78c4ba7e7ec9ab7": "设计虱",
  "ou_2d8827e13291607774e7d518d1b5bfe0": "大脸鱼"
}

技能自动从消息元数据中读取 sender_id,转换为记录人名称。


指令格式

记一笔账

自动判断账本类型

  • 包含"餐饮/交通/购物/工资/房租/水电/通讯/医疗/教育/娱乐/房屋维护" → 日常账
  • 包含"压岁钱/随礼/人情" → 人情账
  • 包含"借/还/报销" → 借款账

时间处理

  • 用户没说时间 → 默认今天(2026-03-22)
  • 用户说了时间 → 按用户说的

示例

记一笔账:50元 餐饮 午餐(自动使用当天日期)
记一笔账:2026-03-20 500 压岁钱 给儿子 张三 张小明
记一笔账:借出 李四 1000 借钱看病

# 如果用户提到房屋名称,需要确认:
用户:记一笔账:200 军龙苑 物业费
助手:你说的"军龙苑"是房屋名称吗?是否要记录为房屋维护?还有其他房产需要录入吗?
用户:是的,没有了
助手:已记录...

# 如果用户提到教育相关费用,需要确认孩子:
用户:记一笔账:500 学而思
助手:这是教育类费用,请问是给哪个孩子报的?家里有几个孩子,他们的昵称是什么?
用户:一个孩子,小明
助手:已记录,教育-小明...

用户:记一笔账:300 兴趣班
助手:请问是给哪个孩子报的?(之前记录有:小明)
用户:还是小明
助手:已记录,教育-小明...

查询记录

查日常账 [时间]
例如:查日常账 2026年3月
查人情账 [时间]
例如:查人情账 今年
查借款账 [状态]
例如:查借款账 未还

统计汇总

统计日常账 [时间] [类别]
例如:统计日常账 2026年3月 餐饮
统计人情账 [时间]
例如:统计人情账 今年
统计借款账
例如:统计借款账

实现方式

通过读写 JSON 文件实现。

  • 读:使用 read 工具读取 JSON 文件
  • 写:使用 write 工具覆盖写入 JSON 文件(追加记录时先读后写)

注意事项

  1. 日期格式统一为 YYYY-MM-DD
  2. 金额为数字,单位 元
  3. 状态更新需要明确说明
  4. 查询时支持模糊匹配(如查询"彤彤家"会匹配包含"彤彤"的记录)
  5. 时间默认值:用户未指定日期时,自动使用当前日期(动态获取)
  6. 账本类型自动判断
    • 日常类关键词(餐饮/交通/购物/工资/房租/水电/通讯/医疗/教育/娱乐/房屋维护)→ 日常账
    • 人情类关键词(压岁钱/随礼/人情)→ 人情账
    • 借款类关键词(借/还/报销)→ 借款账
  7. 房屋名称确认:当用户提到的内容可能包含房屋名称(军龙苑/保利大都会/东方文创园/洛铜嘉苑/龙锦嘉园)时,询问用户确认后再记录。确认后可询问:"还有其他房产需要录入吗?"
    • 首次确认后,后续自动识别为房屋名称,无需再确认
Usage Guidance
This skill appears to implement what it says (a local family ledger), but the published metadata did not list the configuration paths it reads/writes. Before installing: (1) confirm you trust the skill owner or request a homepage/source code; (2) back up ~/.openclaw/workspace/shared/ledger/ if it exists; (3) inspect the contents and permissions of user-mapping.json and the ledger files after first run; (4) ensure the agent's read/write tools only access the intended ledger directory (verify sandboxing/isolation if available); (5) ask the author to update metadata to declare the required config paths and to document whether any data is ever transmitted externally. These checks will reduce privacy/risk concerns. Additional info (source code or a homepage) would raise confidence to "high."
Capability Analysis
Type: OpenClaw Skill Name: family-ledger Version: 1.0.1 The 'family-ledger' skill is a legitimate tool for managing household expenses, social gifts, and loans using local JSON storage. It operates within the designated workspace (~/.openclaw/workspace/shared/ledger/) and uses standard read/write operations to maintain records, with no evidence of data exfiltration, malicious execution, or harmful prompt injection.
Capability Assessment
Purpose & Capability
Name/description (家庭账本管理) align with instructions: creating/querying/updating three JSON ledgers (daily/social/borrow) and a user-mapping file. The file-based implementation is coherent with the stated purpose.
Instruction Scope
SKILL.md explicitly instructs the agent to read/write files under ~/.openclaw/workspace/shared/ledger/ and to use a user-mapping file to map sender_id → display name. However the skill metadata declared no required config paths. Instructions expect access to local user data and message metadata; that capability is reasonable for a ledger but the metadata omission is an inconsistency and a privacy surface to review.
Install Mechanism
No install spec and no code files (instruction-only). This minimizes installation risk — nothing is downloaded or written by an installer.
Credentials
The skill declares no environment variables or credentials and its functionality does not require external API keys. That is proportionate. Note: it does rely on platform-level read/write 'read'/'write' tools and message metadata (sender_id).
Persistence & Privilege
always:false and no special persistence or cross-skill configuration is requested. The skill does not claim autonomous permanent presence beyond normal agent invocation.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install family-ledger
  3. After installation, invoke the skill by name or use /family-ledger
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.1
- 新增“用户ID映射”说明,支持从消息元数据读取 sender_id 并自动转换为记录人名称(设计虱 / 大脸鱼)。 - 在日常账本 (daily.json) 字段说明中,补充 recorded_by 字段,并明确记录人选择规则。 - 更新文件结构说明,增加 user-mapping.json 文件示例及用途。 - 其他内容保持不变,指令用法和注意事项未变。
v1.0.0
Family Ledger v1.0.0 初版发布 - 提供家庭账本管理,支持日常记账、人情往来、借款报销三大类账本。 - 支持账本文件分为 daily.json(日常)、social.json(人情)、borrow.json(借款)分别存储。 - 智能识别教育及房屋类账目,自动归类并根据家庭成员动态问询和补充信息。 - 自然语言指令录入与查询,日期自动处理,支持模糊搜索与多维度汇总。 - 使用 JSON 文件本地读写,实现所有数据记录。
Metadata
Slug family-ledger
Version 1.0.1
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 2
Frequently Asked Questions

What is Family Ledger?

家庭账本管理技能 - 日常记账、人情往来、借款报销. It is an AI Agent Skill for Claude Code / OpenClaw, with 155 downloads so far.

How do I install Family Ledger?

Run "/install family-ledger" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Family Ledger free?

Yes, Family Ledger is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Family Ledger support?

Family Ledger is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Family Ledger?

It is built and maintained by liumeixin (@liumeixin); the current version is v1.0.1.

💬 Comments