Calculation catalog › Cash flow and summary
Spending target requested annual
Target lifestyle spending requested for the projection year.
Field: targetSpending Unit: US dollars Basis: nominal dollars Computed by: Engine Status: Complete chain
Appears in: csv (targetSpending); results-table (Target column (layered spending))
Calculation records
-
Annual target-layer requested spending Composition record, justified by derivation
Purpose: The full no-cut request through the target lifestyle layer.
Statement: projection/internal/annualExpenseSummary.ts#annualExpenseSummary publishes YearExpenses.targetSpending as targetSpendingBase + skippedTargetNominal + skippedRequiredNominal, where targetSpendingBase = systemRequired + requiredLifestyle + targetLifestyle + targetGoalsFunded + requiredGoalsFunded. The base carries the FULL target lifestyle layer, not the guardrail-cut amount, and carries no skipped amount; the two skipped amounts are then added once each. Equivalently, published requiredSpending already contains skippedRequiredNominal, so targetSpending is requiredSpending + targetLifestyle + targetGoalsFunded + skippedTargetNominal. Units: nominal USD per year. Rounding: none.
Formula:
targetSpending = (systemRequired + requiredLifestyle + targetLifestyle + targetGoalsFunded + requiredGoalsFunded) + skippedTargetNominal + skippedRequiredNominal-
targetLifestyle: Full target lifestyle layer before any guardrail cut (unit: usd/year) (domain: nonnegative) -
targetGoalsFunded: Target-classified goals funded this year (unit: usd/year) (domain: nonnegative) -
skippedTargetNominal, skippedRequiredNominal: Nominal amounts of skipped goals in those two layers (unit: usd/year) (domain: nonnegative; counted once each)
Timing: once per projection year, at the expense summary
Rounding: none
Limits:
- Asserted at the annualExpenseSummary seam, which is the function that computes the field, because the worksheet states its inputs as already-folded year-row components rather than as plan inputs a single year could realize at those exact values
- The full target lifestyle layer is used here even in a cutting year; the cut amount appears in baseSpending instead, so a test that substitutes the cut layer is asserting a different field
- Both equivalent forms are asserted, so the "counted once each" clause is evidence rather than prose: starting from the published requiredSpending and adding skippedRequiredNominal again is one of the worksheet's wrong readings
Provenance: derived by
codex, implemented byclaude.Independent review:
cursorGates (6 of 6 pass): fixture registers a test: pass; pins resolve: pass; families exist: pass; worksheet exists: pass; mutation receipt exists: pass; provenance independent: pass
Worksheet: spending-target-requested-annual.md Mutation receipt: spending-target-requested-annual.mutation.md
Evidence tests: annualExpenseSummary.evidence.test.ts
Implemented in: annualExpenseSummary.ts
Is the number of: spending-target-requested-annual
-
Records that feed this number
-
Lifestyle required discretionary split Formula record, justified by derivation
Purpose: Partition lifestyle spending into a clamped required floor and discretionary remainder.
Statement: spending/layers.ts#splitLifestyle splits nominal annual lifestyle spending B into required R = min(max(required,0),max(B,0)) and discretionary D = max(B,0)-R, preserving dollars and clamping the floor to the target; no rounding is stated.
Formula:
R = min(max(required,0), max(B,0)); D = max(B,0) - R-
B: Lifestyle target (unit: nominal USD/year) (domain: finite >= 0) -
required: Requested required floor (unit: nominal USD/year) (domain: finite)
Timing: annual lifestyle partition
Rounding: none
Limits:
- The lifestyle-only partition feeds projection/internal/annualLifestyleLayers.ts; published requested spending also includes system costs and goals, so neither requested family is this helper alone.
Provenance: derived by
codex, implemented bycodex.Independent review:
cursorGates (6 of 6 pass): fixture registers a test: pass; pins resolve: pass; families exist: pass; worksheet exists: pass; mutation receipt exists: pass; provenance independent: pass
Worksheet: lifestyle-required-discretionary-split.md Mutation receipt: lifestyle-required-discretionary-split.mutation.md
Evidence tests: layers.evidence.test.ts
Implemented in: layers.ts
Feeds: spending-required-requested-annual, spending-target-requested-annual
-
Engine source: engine/src/projection/internal/types/result.ts
(YearResult.expenses.targetSpending)
The evidence links on this page (each record's worksheet, mutation receipt, evidence tests
and implementation, and the source links) are pinned to engine commit
2624dbdba9fd, committed 2026-10-11.
The live calculation index and
output-family census links point at the repository's main
branch, so you can check this snapshot against them.