[#67] Post-lending summary: won-loan aggregates + portfolio comparison #68

Merged
robertismo merged 1 commit from 67-loan-summary into master 2026-09-29 21:06:55 +00:00
Owner

Post-lending summary: what you actually won, against your portfolio

After each award the human now gets (interactive only):

  Bank 1: you won 7 loans this turn — capital 68,647 · effective rate 2.2852%/turn · effective term 8.6 turns
  ⚠ 3 of your winning bids could not be funded (33,772) — cash ran out in market order
  PORTFOLIO  book 68,647 (new book) · eff rate 2.2852%/turn · term left 8.6 turns

and once a book exists:

  Bank 1: you won 1 loan this turn — capital 9,289 · effective rate 2.8833%/turn · effective term 11.0 turns
  PORTFOLIO  book 70,251 (was 60,962) · eff rate 2.3688%/turn (was 2.2904%) · term left 8.1 turns (was 7.6)
  • Capital commitment = Σ awarded amounts; effective rate/term = amount-weighted; portfolio metrics = amount-weighted over the live book (dead loans weigh on book and term but yield 0).
  • The verdict line is now honest in three cases: wins, outbid ("someone bid a lower rate on everything you bid"), won-but-unfunded (the engine funds in market order until cash runs out — shown with the shortfall), and no bids placed.
  • Verified with a scripted interactive game (human bids 1% and actually wins): turn 1 shows 7 wins + 3 unfunded, turn 2 shows the before/after comparison. go build, go test ., go vet ./... green; spectate regression: 0 [ai errors, 0 divergences, no summary leaks into headless mode.
## Post-lending summary: what you actually won, against your portfolio After each award the human now gets (interactive only): ``` Bank 1: you won 7 loans this turn — capital 68,647 · effective rate 2.2852%/turn · effective term 8.6 turns ⚠ 3 of your winning bids could not be funded (33,772) — cash ran out in market order PORTFOLIO book 68,647 (new book) · eff rate 2.2852%/turn · term left 8.6 turns ``` and once a book exists: ``` Bank 1: you won 1 loan this turn — capital 9,289 · effective rate 2.8833%/turn · effective term 11.0 turns PORTFOLIO book 70,251 (was 60,962) · eff rate 2.3688%/turn (was 2.2904%) · term left 8.1 turns (was 7.6) ``` - Capital commitment = Σ awarded amounts; effective rate/term = amount-weighted; portfolio metrics = amount-weighted over the live book (dead loans weigh on book and term but yield 0). - The verdict line is now honest in three cases: wins, outbid ("someone bid a lower rate on everything you bid"), won-but-unfunded (the engine funds in market order until cash runs out — shown with the shortfall), and no bids placed. - Verified with a scripted interactive game (human bids 1% and actually wins): turn 1 shows 7 wins + 3 unfunded, turn 2 shows the before/after comparison. `go build`, `go test .`, `go vet ./...` green; spectate regression: 0 `[ai` errors, 0 divergences, no summary leaks into headless mode.
[#67] Post-lending summary: won-loan aggregates vs the portfolio
All checks were successful
build / build (push) Successful in 25s
ae40602ab4
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
Winnie/bankwars!68
No description provided.