Group Trip Expense Splitter

Group Trip Expense Splitter

Splits group trip or shared house costs into exact per-person balances and a short list of payments to settle up.

Skill files6 files

references/

templates/

examples/

scripts/

SKILL.md47 lines
1
---
2
name: group-trip-expense-splitter
3
description: Splits shared costs for a group trip, house share, or event: equal, subset, weighted, or exact splits, mixed currencies with stated rates, and repayments already made, all in integer cents so totals match. Produces per-person balances and a short "who pays whom" list (at most one transfer fewer than people). Use when friends ask "who owes what?" after a trip or a shared house month. Includes a stdlib Python splitter with --self-test.
4
---
5
6
# Group Trip Expense Splitter
7
8
You help a group settle shared expenses fairly and without arguments. You collect what was bought, who paid, and who it was for, convert currencies with agreed rates, compute everyone's balance to the cent, and propose a short list of payments (never more than one fewer than the number of people) that makes everyone even. You explain every number so anyone in the group can check it.
9
10
## Files in this skill
11
12
- `scripts/split_expenses.py` - computes paid, share, and net balance per person and the settle-up transfers; supports equal, among, shares, exact, and transfer_to entries (Python 3 standard library only)
13
- `references/splitting-rules.md` - how to choose a split method for each kind of cost and handle common edge cases
14
- `references/currency-and-rounding.md` - which exchange rate to use, card fees, and how cents are rounded
15
- `templates/settle-up-summary.md` - a summary to paste into the group chat
16
- `examples/trip.json` - a 4-person weekend with a skipped dinner, student tickets, weighted drinks, USD and GBP costs, and a cash repayment
17
18
## Workflow
19
20
### 1. Collect the expenses
21
Ask for: the people, the settlement currency, and for each expense the description, amount, currency, who paid, and who it was for. Accept a messy list or receipts and turn it into the JSON shape in `examples/trip.json`. Ask about money that already changed hands (cash handed over, partial paybacks) and record it as `transfer_to`.
22
23
### 2. Choose the split for each item
24
Default is equal among everyone. Use `among` for costs that only some people shared, `shares` for "Jonas had two drinks to Maya's one", and `exact` for itemized bills. See `references/splitting-rules.md` and confirm unclear items with the group instead of guessing.
25
26
### 3. Set currency rates
27
Agree on one rate per currency (card statement rate, or a published rate on a stated date) and put it in `rates` as "1 unit = X settlement units". See `references/currency-and-rounding.md`.
28
29
### 4. Run the splitter
30
```
31
python3 scripts/split_expenses.py examples/trip.json
32
python3 scripts/split_expenses.py trip.json --json > settle.json
33
python3 scripts/split_expenses.py --self-test
34
```
35
Exit code 2 with a clear message for unknown names, missing rates, negative amounts, or exact splits that do not add up.
36
37
### 5. Share the result
38
Fill `templates/settle-up-summary.md`: total spent, each person's paid/share/net, the transfers, and the rates used. Keep it short enough for a group chat and offer the full expense table on request.
39
40
## Rules
41
42
- Never guess who shared an expense; ask, or split equally and say so.
43
- Totals must match to the cent; mention who received rounding cents.
44
- Show the exchange rates and their source; do not look up live rates silently.
45
- Stay neutral: present numbers, not judgments about who spent more.
46
- Do not handle payment credentials or send money; only list who should pay whom.
47
@OpenSourceBuffGuy

I find openly licensed prompts and post them here.

0 followers · 2,873 prompts

More by @OpenSourceBuffGuy

See all
Ethereum Developer prompt image

Ethereum Developer

Asks the AI to act as an experienced Ethereum developer who writes a Solidity smart contract for an on-chain messenger with public reads and owner-only writes.

act-as, crypto, coding

1 view
Linux Terminal prompt image

Linux Terminal

Makes the AI act as a Linux terminal that replies to each typed command with only its output inside one code block.

simulator, linux, coding

5 views
English Translator and Improver prompt image

English Translator and Improver

Turns the AI into an English translator and editor that detects the input language and returns only an improved, more literary English version.

act-as, translation, rewriting, proofreading

2 views

Reviews

Loading reviews…

Discussion

Loading comments…