Regenerate golden files with correct interest model #1

Open
opened 2026-08-07 14:22:44 +00:00 by hum3 · 0 comments
Owner

The golden files in products.md have multiple issues that need fixing once the interest model is implemented correctly in go-luca:

Ledger directions

  • Deposits should be Customer Liability -> Cash, not Equity:Capital -> Liability:Savings
  • Interest (savings) should be -ve Expense:Interest -> Customer Liability
  • Interest (lending) direction reversed accordingly

Interest arithmetic

  • Daily interest values appear to be truncated rather than correctly rounded
  • Need to verify against go-luca's actual rounding behaviour (or the new exact fraction mode)
  • Compounding effects in the examples may be wrong

Depends on

  • go-luca changes: accrual register with configurable precision (5dp/10dp/exact), day count conventions (actual/365, actual/actual), exact integer fraction mode (balance * rate_bps / (10000 * 365)), correct ledger movement directions
  • gobank-products: interest_application, day_count, accrual_precision parameters on InterestAccrual feature

Scope

  • Regenerate all six golden file examples in products.md (Easy Access, Fixed Term, ISA, Personal Loan, Mortgage, Overdraft)
  • Verify each against go-luca's actual output
  • See interest.md for the full specification

Migrated from Codeberg: originally #1, opened 2026-03-20.

The golden files in `products.md` have multiple issues that need fixing once the interest model is implemented correctly in go-luca: ### Ledger directions - Deposits should be `Customer Liability -> Cash`, not `Equity:Capital -> Liability:Savings` - Interest (savings) should be `-ve Expense:Interest -> Customer Liability` - Interest (lending) direction reversed accordingly ### Interest arithmetic - Daily interest values appear to be truncated rather than correctly rounded - Need to verify against go-luca's actual rounding behaviour (or the new exact fraction mode) - Compounding effects in the examples may be wrong ### Depends on - go-luca changes: accrual register with configurable precision (5dp/10dp/exact), day count conventions (actual/365, actual/actual), exact integer fraction mode (`balance * rate_bps / (10000 * 365)`), correct ledger movement directions - gobank-products: `interest_application`, `day_count`, `accrual_precision` parameters on `InterestAccrual` feature ### Scope - Regenerate all six golden file examples in `products.md` (Easy Access, Fixed Term, ISA, Personal Loan, Mortgage, Overdraft) - Verify each against go-luca's actual output - See `interest.md` for the full specification --- *Migrated from Codeberg: originally [#1](https://codeberg.org/hum3/gobank-products/issues/1), opened 2026-03-20.*
Sign in to join this conversation.
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
hum3/gobank-products#1
No description provided.