Expose account runtime metrics

This commit is contained in:
boris
2026-04-23 20:03:49 -07:00
parent 9f10afddec
commit e0a5d0c945
7 changed files with 367 additions and 19 deletions

View File

@@ -70,6 +70,17 @@ current alignment pass.
- [x] final order object lookup by order id
- [x] order average fill price and transaction cost aggregation
### Phase 9: Account / portfolio API parity
- [x] stock-account runtime view (`ctx.account()` / `ctx.portfolio_view()`)
- [x] `cash`, `available_cash`, `frozen_cash`, `market_value`, `total_value`
exposed to strategy runtime and DSL
- [x] `unit_net_value`, `static_unit_net_value`, `daily_pnl`,
`daily_returns`, `total_returns`, `transaction_cost`, `trading_pnl`,
and `position_pnl` exposed to strategy runtime and DSL
- [ ] explicit deposit / withdraw API
- [ ] financing liability / repay API
## Execution Order
1. Close the explicit order API gap with target-shares / `order_to` parity.
@@ -80,10 +91,10 @@ current alignment pass.
6. Finish position accounting parity.
7. Continue stock data-source API parity.
8. Continue order object API parity.
9. Continue parity audit for remaining account APIs.
9. Continue account / portfolio API parity.
## Current Step
Active implementation target: continue parity audit for remaining account APIs
after order object lookup, status, unfilled quantity, average fill price, and
transaction cost aggregation are covered.
Active implementation target: continue account parity after exposing the stock
account runtime view and core Portfolio fields; next gaps are explicit
deposit/withdraw and financing liability APIs.