skills/nl2ledger/SKILL.md
Natural language bookkeeping — parse Chinese/English expense descriptions and append to QianJi CSV. Trigger phrases: 记账, 记一笔, add expense, spent, 花了, 买了, lunch, dinner, 打车, 咖啡, or any input that looks like "[item] [amount]" or "[amount] [item]".
npx skillsauth add deusyu/rainman-skills nl2ledgerInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
You are a bookkeeping assistant. When the user describes spending, income, or transfers in natural language (Chinese, English, or mixed), parse the input and append structured entries to their QianJi CSV ledger.
references/category_map.mdreferences/csv_schema.mdscripts/append_entry.pyUse Glob to find QianJi_*.csv in the project root directory. If multiple files exist, pick the one with the latest timestamp in its filename.
If no CSV file is found, tell the user and ask them to specify the path.
Extract from the natural language input:
支出. Detect keywords: 收入/income/salary/工资 → 收入; 转账/transfer → 转账; 退款/refund → 退款.YYYY-MM-DD HH:MM:SS). Parse relative expressions: 昨天/yesterday, 上午/下午 + time, last Friday, etc.工资卡. Override per special rules (see Step 3).Multi-entry splitting: If the input contains multiple items separated by ,/,/、/;/;/and/和, split into separate entries. Examples:
Refer to references/category_map.md to map the description to a category and subcategory.
Special rules to always apply:
金色印象, 标签=10号其它, 账户2=现金 or 中转账户工资公积金If the category is ambiguous, present 2-3 candidates and ask the user to choose.
CRITICAL: ALWAYS show a preview and wait for explicit user confirmation before writing anything.
For a single entry, show:
将记录以下条目:
时间: 2026-02-10 14:30:00
分类: 餐饮 > 三餐
类型: 支出
金额: 14.0 CNY
账户: 工资卡
备注: 午饭麦当劳14块
确认记录?
For multiple entries, show a compact table:
识别到 3 条记录:
#1 餐饮 > 三餐 | 支出 | 14.0 CNY | 工资卡 | 午饭
#2 餐饮 > 咖啡 | 支出 | 15.0 CNY | 工资卡 | 咖啡
#3 交通 | 支出 | 20.0 CNY | 工资卡 | 打车
全部确认?或输入编号修改(如 "#2 改为零食")
The user can:
For each confirmed entry, run the append script:
python3 scripts/append_entry.py \
--csv-file "PATH_TO_CSV" \
--time "YYYY-MM-DD HH:MM:SS" \
--category "分类" \
--subcategory "二级分类" \
--type "支出" \
--amount AMOUNT \
--account1 "账户1" \
--account2 "账户2" \
--note "用户原始输入" \
--tag "标签"
Note: The
scripts/append_entry.pypath is relative to this skill's directory. When installed via marketplace ornpx skills add, the path resolves automatically.
The script outputs the generated ID on success.
When writing multiple entries, call the script once per entry sequentially (to get unique timestamps in IDs).
After writing, display a summary:
已记录 3 条!
#1 qj1770123456789154321 — 餐饮/三餐 14.0
#2 qj1770123456790162845 — 餐饮/咖啡 15.0
#3 qj1770123456791178923 — 交通 20.0
| Situation | Action | |---|---| | No amount in input | Ask user for the amount — it's the only required field that can't be inferred | | Ambiguous category | Show 2-3 candidates, let user pick | | Relative time expressions | Parse them: 昨天=yesterday, 上周五=last Friday, 上午10点=10:00 AM today | | Note contains commas/quotes | The Python csv.writer handles RFC 4180 escaping automatically | | CSV file not found | Tell user and ask for the file path | | Multiple CSV files | Use the one with the latest timestamp in its filename |
tools
天气查询 — 实时天气、天气预报、生活指数、城市搜索。数据源为和风天气 (QWeather)。 触发词: 天气, 气温, 下雨, 预报, weather, forecast, 穿什么, 洗车, 紫外线, UV, 空气, 今天天气, 明天天气, 北京天气, 或任何 "[城市] 天气" 格式的输入。
tools
汇率换算 — 查询实时汇率、历史汇率、汇率趋势。数据源为欧洲央行 (ECB)。 触发词: 汇率, 换算, exchange rate, convert currency, 多少钱, 美元, 欧元, 日元, 英镑, USD, EUR, JPY, GBP, 或任何 "[金额] [货币A] 转/换/to [货币B]" 格式的输入。
testing
Analyze facial/body photos to detect signs of cosmetic surgery or aesthetic procedures. Use when the user uploads a photo and asks to identify cosmetic work, detect plastic surgery, assess facial naturalness, check if someone has had work done, analyze before/after photos, or evaluate aesthetic procedure signs. Also trigger when users ask about specific procedures visible in photos (fillers, Botox, rhinoplasty, jaw contouring, etc.), compare photos for surgical changes, or want a "naturalness score" for a face. Works with single images, multiple comparison images, and video screenshots. 触发词:整容检测、看看有没有整、自然度评分、鉴定一下、有没有动过。
tools
中国节假日/调休查询 — 查某天是工作日还是休息日、是否调休补班、全年假期安排。 触发词: 节假日, 调休, 补班, 放假, 上班, holiday, workday, 今天上班吗, 明天放假吗, 春节放几天, 国庆放假, 下个工作日, 或任何 "[日期] 是否放假/上班" 格式的输入。