Skip to content

Upgrade to segment-targeted net-benefit model + Retail/DMS view - #1

Merged
privatejoel merged 2 commits into
mainfrom
sync/portfolio-model-rewrite
Jun 3, 2026
Merged

Upgrade to segment-targeted net-benefit model + Retail/DMS view#1
privatejoel merged 2 commits into
mainfrom
sync/portfolio-model-rewrite

Conversation

@privatejoel

Copy link
Copy Markdown
Owner

What this does

Replaces the dealer-lot prototype with the national-portfolio analysis model.

Changes

  • src/App.tsx (437 → 1090 lines): rescaled to the national OEM pipeline (~$2.87B deployed). Adds:
    • Segment-specific DSI targets (Luxury 75 / EV 70 / SUV 60 / Volume 45) instead of one universal cutoff
    • A net-benefit decision engine — acts only when annual carrying cost avoided exceeds the one-time clearance loss
    • Strict TypeScript typing throughout (InventoryItem, ProcessedItem, Portfolio)
    • A new Retail & DMS view drilling the OEM thesis down to dealer floorplan economics (aging buckets, turn, recoverable burn)
  • README.md: answer-first rewrite with the "defensible metrics" framing.
  • METHODOLOGY.md (new): full formula derivation, assumptions, sensitivity analysis, and documented limitations.

Verification

  • tsc --noEmit — clean, no type errors
  • vite build — succeeds (185 kB JS / 57 kB gzipped)
  • No dependency changes required.

🤖 Generated with Claude Code

privatejoel and others added 2 commits June 3, 2026 20:11
Replace the dealer-lot prototype with the national-portfolio analysis:

- App.tsx: rescale to national OEM pipeline ($2.87B deployed); add
  segment-specific DSI targets, a net-benefit decision engine (act only
  when carrying cost avoided > clearance loss), strict typing, and a new
  Retail & DMS view drilling the thesis to dealer floorplan economics.
- README.md: answer-first rewrite with defensible-metrics framing.
- METHODOLOGY.md: new — full formulas, assumptions, sensitivity, limits.

Verified: tsc --noEmit clean, vite build succeeds.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
- Dashboard: the per-row Reallocate action now obeys the same
  net-benefit gate as "Execute all" — when clearing a pool costs more
  than the carrying cost it avoids (netFirstYear <= 0), the row shows a
  "Hold · net-negative" state instead of an actionable button, and
  executeOne guards against acting. Previously a single row could be
  cleared against the model's own act-only-when-it-pays rule (e.g. at an
  8% carrying rate). Matches METHODOLOGY.md §5/§8.
- CI: add a `tsc --noEmit` typecheck gate before build.
- Deploy: guard the GitHub Pages publish to push-to-main only, so
  pull_request builds no longer risk publishing un-merged code.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@privatejoel
privatejoel merged commit f62d3df into main Jun 3, 2026
1 check passed
@privatejoel
privatejoel deleted the sync/portfolio-model-rewrite branch June 3, 2026 14:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant