Time-weighted return, which removes the effect of contributions and withdrawals

One command in the Portfolio pack, available in the CLI, as an MCP tool and as a JavaScript import: portfolio twr.

What it needs, and why

Every input is checked before anything is calculated. valuations is required; the rest refine the answer.

InputRequiredThe question it asksWhy it matters
valuationsyesWhat was the portfolio worth at the start, at each contribution or withdrawal, and at the end?A valuation is needed at every external cash flow.

Requests it answers

An agent with this pack loaded picks the command from phrasing like that, asks for whatever input is missing, and reports the figures with the method that produced them.

Limits it inherits from wealth-portfolio

The full pack, its other 10 commands and what it deliberately leaves alone are on the Portfolio page.