Total the lines of a quote or invoice

Total the lines of a quote or invoice in order, where each percent line names the base it multiplies (the line above, the lines since the last subtotal, or all above) and a subtotal line resets that base

action totals takes lines { kind_field?, value_field?, base_field?, order_field? } and row_ids or every row. A line's kind is a row of read-data/list-settlements.json line_totals.kinds (amount, percent, subtotal); a percent line must name its base. Answers each line with its amount, the base it used and the running total, and the total. It reads only the lists handed in.

What it asks for

Nothing: your AI starts it with your words.

Use it from your AI

Connect the AI you already use to Trillion once. Then ask in your own words; your AI finds this tool by what it does and runs it.

Say to your AI: “Use Trillion to total the lines of a quote or invoice in order, where each percent line names the base it multiplies (the line above, the lines since the last subtotal, or all above) and a subtotal line resets that base”