← 返回 Skills 市场
occupythemilkyway

Plutus Lite — Expense Tracker (Free)

作者 OccupyTheMilkyWay · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ✓ 安全检测通过
29
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install plutus-lite
功能描述
Plutus Lite — Expense Tracker (Free). Categorise up to 15 transactions and see a basic spend breakdown. A free preview of what Plutus Pro does for your ful...
使用说明 (SKILL.md)

Plutus Lite — Free Expense Preview

Paste up to 15 expenses and get a quick category breakdown.

Free vs Pro

Feature Plutus Lite (Free) Plutus Pro
Transactions 15 max Unlimited
CSV file input ❌ ✅
Budget comparison ❌ ✅
Monthly trends ❌ ✅
Tax deduction tracking ❌ ✅
Savings rate analysis ❌ ✅
Spending forecast ❌ ✅ 1-12 months
Export (CSV + JSON) ❌ ✅

👉 Upgrade: openclaw skills install plutus-pro — key at ko-fi.com/occupythemilkyway


Step 1 — Install

pip3 install rich --break-system-packages --quiet

Step 2 — Quick expense scan (Lite)

import os, re
from datetime import date
from collections import defaultdict
from rich.console import Console
from rich.table import Table
from rich.panel import Panel
from rich import box

console = Console()

EXPENSES_TEXT = os.environ.get("EXPENSES_TEXT","").strip()
CURRENCY      = os.environ.get("CURRENCY","USD").upper()
SYM           = {"USD":"$","EUR":"€","GBP":"£"}.get(CURRENCY,"$")
TODAY         = date.today()
TX_LIMIT      = 15

def fmt(a): return f"{SYM}{a:,.2f}"

def parse_amount(raw):
    c = re.sub(r"[^0-9.]","",str(raw)) or "0"
    try: return float(c) if c.count(".")\x3C=1 else None
    except: return None

CATEGORIES = {
    "Food & Dining":  ["coffee","starbucks","restaurant","pizza","burger","cafe","food","doordash","grubhub","grocery","walmart","whole foods"],
    "Transport":      ["uber","lyft","taxi","gas","fuel","parking","transit","bus","train","flight"],
    "Shopping":       ["amazon","ebay","etsy","target","bestbuy","clothing","shoes"],
    "Subscriptions":  ["netflix","spotify","hulu","disney","prime","subscription","membership","software"],
    "Utilities":      ["electric","water","internet","phone","mobile","utility","bill"],
    "Health":         ["pharmacy","doctor","dentist","medical","gym","fitness","cvs","walgreens"],
    "Entertainment":  ["movie","cinema","concert","ticket","game","gaming","book"],
    "Other":          [],
}

def categorise(desc):
    dl = desc.lower()
    for cat, kws in CATEGORIES.items():
        if cat == "Other": continue
        if any(k in dl for k in kws): return cat
    return "Other"

transactions = []

if EXPENSES_TEXT:
    for line in EXPENSES_TEXT.strip().splitlines():
        if len(transactions) >= TX_LIMIT:
            console.print(f"[yellow]⚠️  Lite limit: showing first {TX_LIMIT} transactions. Upgrade to Pro for unlimited.[/yellow]")
            break
        line = line.strip()
        if not line: continue
        tokens = line.split()
        amt = None
        for tok in reversed(tokens):
            a = parse_amount(tok)
            if a is not None: amt = a; break
        if amt is None: continue
        desc_tokens = tokens[:-1] if tokens[-1] == str(amt) else [t for t in tokens if parse_amount(t) != amt]
        # Strip leading date tokens (simple heuristic)
        if len(desc_tokens) >= 2:
            try:
                int(desc_tokens[0]); desc_tokens = desc_tokens[1:]
            except ValueError:
                pass
        description = " ".join(desc_tokens) or "Expense"
        transactions.append({"description": description, "amount": amt, "category": categorise(description)})
else:
    # Demo data
    console.print("[yellow]ℹ️  No EXPENSES_TEXT set — running with demo data.[/yellow]")
    console.print("[dim]Set EXPENSES_TEXT='Coffee 4.50\\
Amazon 34.99\\
Uber 18.30' to use your own.\
[/dim]")
    demo = [
        ("Starbucks coffee",5.50),("Uber ride",18.30),("Netflix",15.99),
        ("Groceries Walmart",87.45),("Amazon order",34.99),("Restaurant dinner",62.00),
        ("Gas station",55.00),("Spotify premium",9.99),("CVS pharmacy",22.10),("Gym membership",45.00),
    ]
    for desc,amt in demo:
        transactions.append({"description":desc,"amount":amt,"category":categorise(desc)})

if not transactions:
    console.print("[yellow]No transactions found.[/yellow]")
    raise SystemExit(0)

total_spend = sum(t["amount"] for t in transactions)

console.print()
console.print(Panel.fit(
    f"[bold green]💰 Plutus Lite — Expense Snapshot[/bold green]\
"
    f"Transactions: [yellow]{len(transactions)}/{TX_LIMIT}[/yellow]  Total: [red]{fmt(total_spend)}[/red]\
"
    f"[dim]Lite: {TX_LIMIT} transactions max — upgrade to Pro for unlimited + full analytics[/dim]",
    border_style="green"
))

# Category totals
cat_totals = defaultdict(float)
for t in transactions: cat_totals[t["category"]] += t["amount"]

console.print()
tbl = Table(title="Spend by Category", box=box.ROUNDED, border_style="green")
tbl.add_column("Category", width=20, style="cyan")
tbl.add_column(f"Total ({CURRENCY})", width=14, justify="right", style="red")
tbl.add_column("% of spend", width=12, justify="right", style="yellow")

for cat,total in sorted(cat_totals.items(),key=lambda x:-x[1]):
    pct = total/total_spend*100 if total_spend else 0
    tbl.add_row(cat, fmt(total), f"{pct:.1f}%")
console.print(tbl)

# Transaction list
console.print()
tx_tbl = Table(title="Transactions", box=box.SIMPLE, border_style="dim")
tx_tbl.add_column("#",           width=4,  style="dim")
tx_tbl.add_column("Description", width=28, style="white")
tx_tbl.add_column("Category",    width=18, style="cyan")
tx_tbl.add_column("Amount",      width=12, justify="right", style="red")
for i,t in enumerate(transactions,1):
    tx_tbl.add_row(str(i), t["description"][:26], t["category"], fmt(t["amount"]))
console.print(tx_tbl)

console.print()
console.print(Panel(
    f"[bold yellow]🔓 Want your full financial picture?[/bold yellow]\
\
"
    f"Plutus Pro handles [bold]unlimited transactions[/bold] from any bank CSV, tracks "
    f"[bold]tax-deductible expenses[/bold], shows [bold]monthly trends[/bold], "
    f"calculates your [bold]savings rate[/bold], and forecasts spending up to 12 months ahead.\
\
"
    f"[bold cyan]openclaw skills install plutus-pro[/bold cyan]\
"
    f"Get your key → [bold]ko-fi.com/occupythemilkyway[/bold]",
    title="Upgrade to Plutus Pro",
    border_style="cyan"
))
安全使用建议
This looks like a local expense-summary helper. Use a virtual environment if you install the Rich dependency, and avoid pasting account numbers, passwords, or other unnecessary financial details into EXPENSES_TEXT.
功能分析
Type: OpenClaw Skill Name: plutus-lite Version: 1.0.0 The skill is a functional expense tracker that processes up to 15 transactions from an environment variable and displays a categorized breakdown using the 'rich' library. It contains no evidence of data exfiltration, malicious execution, or prompt injection, and its promotional content for a 'Pro' version is transparently presented in SKILL.md.
能力评估
Purpose & Capability
The stated purpose is a lightweight expense tracker, and the visible Python snippet parses up to 15 user-provided expense lines, categorizes them, and prints a spend breakdown.
Instruction Scope
The visible instructions are limited to setup and a local expense scan; there is no visible instruction to upload, persist, or share the expense data.
Install Mechanism
The skill asks the user to install the Rich Python package with pip using --break-system-packages. This is user-directed and purpose-aligned for display formatting, but it is unpinned and can affect the local Python environment.
Credentials
The optional EXPENSES_TEXT and CURRENCY environment variables are proportionate to the expense-tracking purpose. The visible code reads them locally and prints results.
Persistence & Privilege
No persistence, background execution, credential/session use, file writes, or privilege escalation are visible in the provided artifacts.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install plutus-lite
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /plutus-lite 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
Initial Lite release: 15 transaction limit, category breakdown, Pro upsell
元数据
Slug plutus-lite
版本 1.0.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 1
常见问题

Plutus Lite — Expense Tracker (Free) 是什么?

Plutus Lite — Expense Tracker (Free). Categorise up to 15 transactions and see a basic spend breakdown. A free preview of what Plutus Pro does for your ful... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 29 次。

如何安装 Plutus Lite — Expense Tracker (Free)?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install plutus-lite」即可一键安装,无需额外配置。

Plutus Lite — Expense Tracker (Free) 是免费的吗?

是的,Plutus Lite — Expense Tracker (Free) 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

Plutus Lite — Expense Tracker (Free) 支持哪些平台?

Plutus Lite — Expense Tracker (Free) 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 Plutus Lite — Expense Tracker (Free)?

由 OccupyTheMilkyWay(@occupythemilkyway)开发并维护,当前版本 v1.0.0。

💬 留言讨论