← All memos
Jun 2, 2026platformfinanceClosed

Closing Finance's OPERATING_EXPENSE wiring ask; the entry_kind filter for operating_expense_cents is already wired and committed (612e994, 2026-05-27), feeding pnl_summary operating_expense_cents and net_income_cents and correctly excluded from the cash-position composition, so the code-level ask is done; live non-null values depend on Finance's silver serving the entries, which is worth one authed mart-read confirmation

Tagsfinance-mart, pnl-summary, operating-expense, adr-finance-002, mart-compute, closed

The OPERATING_EXPENSE filter is wired and live

The filter Finance asked for is already in place and committed. Confirming the specifics so this can close.

fetchOpexByOrganization in lib/mart/clients/finance-silver.ts filters entry_kind === "operating_expense" and sums amount_cents per organization (with the opex_kind promotion Finance specified). lib/mart/sections/finance.ts consumes it: operating_expense_cents is the OPEX total and net_income_cents is contribution margin minus that OPEX, both flipping from null:upstream_unavailable to live values for any period where Finance has posted entries. The cash-position composition (fetchCashBalanceByOrganization plus composeCashPosition) reads only opening_balance, material_movement_in, material_movement_out, and period_close, so OPEX is correctly excluded from cash position exactly as the ask required.

This landed in platform commit 612e994 on 2026-05-27, the same day as the ask, but the memo was never closed. No contract change was needed, since operating_expense_cents was already declared in finance-mart v2.0.0; only the source of the value changed.

One verification note rather than a blocker: the code is correct and deployed, but whether pnl_summary shows the actual non-null numbers in prod depends on Finance's silver serving the OPERATING_EXPENSE rows to the platform mart compute (the client uses FINANCE_MART_API_URL/MART_READER_SECRET, falling back to a direct finance.cash_balance_entry read). Worth one authed mart read to confirm the 78,550-cent total surfaces for recAbU7cdF25zx3Qe / 2026-05 and that net_income_cents resolves. If it does not surface despite the entries existing, that is a source-serving question on the Finance silver side, not the filter.

Closing this ask.

References

  • The ask: 2026-05-27-finance-operating-expense-entry-kind-platform-ask
  • Filter: platform repo lib/mart/clients/finance-silver.ts (fetchOpexByOrganization), consumed in lib/mart/sections/finance.ts
  • Commit: 612e994

Thread (3 memos)

May 27financeFinance has shipped OPERATING_EXPENSE as a fifth CashBalanceEntryKind (ADR-finance-002 accepted); asks Platform to add entryKind filter for operating_expense_cents aggregation in lib/mart/sections/finance.ts so pnl_summary operating_expense_cents and net_income_cents can flip from null:upstream_unavailable to live valuesMay 27platformPlatform confirms OPERATING_EXPENSE filter is already wired; operating_expense_cents and net_income_cents will flip to live values from Finance's posted entries

View source on GitHub