You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Part of LeanerCloud/cloud-commitments-go#27 (commitment laddering automation). Phase 1 of 4: provider-neutral engine core in a new pkg/ladder package (sibling of pkg/exchange, no internal/ or provider imports). Pure logic, no cloud calls.
PRs:
Types + plan + capability interface: LayerType/LayerRole/ActionType/LadderMode/LadderCadence typed enums; LadderConfig, UsageBaseline (absent values as *float64, never 0-coerced), LayerState, PlannedAction (Rationale + DataSources + money as *big.Rat), LadderPlan.Explain() for the approval-email body; LadderCapability + narrow LadderStore interfaces. Table-driven tests.
Allocation algorithm (allocate.go): baseline low-water-mark -> target (default 100% of baseline) -> gap -> three-layer split (base/flex/buffer) with utilization-protection clamp (never commit above observed floor); fail-loud HOLD on nil baseline; named constants for all defaults, config-overridable. Table-driven tests covering nil baseline, zero gap, buffer > gap, expiring commitments, clamp at floor.
Tranche laddering (ladder.go): ramp schedule (reuse internal/config RampSchedule semantics) -> staggered tranche scheduled dates so term expiries never bunch up. Property-style tests on staggering.
PR 1 of 3 merged: #1338 (pkg/ladder core types, enums, plan rendering, capability interfaces) is in main. Remaining for phase 1: #1340 (allocation algorithm, now retargeted to main) and #1341 (tranche building, auto-follows). Recommend keeping this issue open until both land.
Verification sweep against main (101f099fb) on 2026-07-27 finds this already resolved.
Laddering phase 1 is complete: PRs #1338, #1340 and #1341 are all merged, and pkg/ladder has all 5 implementation files plus tests.
Evidence: PRs #1338, #1340, #1341.
Recommending close. Reopen if a later laddering phase needs its own tracking issue instead.
Verified resolved at 3c0f8ac: pkg/ladder contains the typed enums, plan and capability interfaces, the Allocate three-layer allocation algorithm and the BuildTranches staggered-tranche builder, each with tests. Evidence: pkg/ladder/allocate.go:122 and pkg/ladder/ladder.go:72 (#1338, #1340, #1341). Residual axes checked: later phases are tracked by LeanerCloud/cloud-commitments-platform#70 and LeanerCloud/cloud-commitments-go#28, not this phase-1 issue. Closing as completed; reopen if the behaviour recurs.
Activity
feat(ladder): add allocation algorithm with three-layer split and gua…
feat(ladder): build staggered tranches from allocations via ramp sche…
cristim commentedon Jul 3, 2026
PR 1 of 3 merged: #1338 (pkg/ladder core types, enums, plan rendering, capability interfaces) is in main. Remaining for phase 1: #1340 (allocation algorithm, now retargeted to main) and #1341 (tranche building, auto-follows). Recommend keeping this issue open until both land.
cristim commentedon Jul 27, 2026
Verification sweep against
main(101f099fb) on 2026-07-27 finds this already resolved.Laddering phase 1 is complete: PRs #1338, #1340 and #1341 are all merged, and pkg/ladder has all 5 implementation files plus tests.
Evidence: PRs #1338, #1340, #1341.
Recommending close. Reopen if a later laddering phase needs its own tracking issue instead.
cristim commentedon Sep 2, 2026
Verified resolved at 3c0f8ac: pkg/ladder contains the typed enums, plan and capability interfaces, the Allocate three-layer allocation algorithm and the BuildTranches staggered-tranche builder, each with tests. Evidence: pkg/ladder/allocate.go:122 and pkg/ladder/ladder.go:72 (#1338, #1340, #1341). Residual axes checked: later phases are tracked by LeanerCloud/cloud-commitments-platform#70 and LeanerCloud/cloud-commitments-go#28, not this phase-1 issue. Closing as completed; reopen if the behaviour recurs.