Proposal: forecast-based reorder points and shortage allocation ("Replenishment Planner")
Maintainer antworten meist innerhalb von 1 Tag
Bewertung
- Schwierigkeit
- 5/5
- Geschätzter Aufwand
- Über eine Woche
- Anfängerfreundlichkeit
- 25/100
- Issue-Typ
- Feature
- Klarheit
- Muss geklärt werden
- Aktivitätsstatus
- Aktiv
- Bereich
- analytics, data, full-stack
Rechercherichtung
Start by reading the proposal, the linked docs/replenishment.md write-up, and the prototype under app/services/replenishment/. Review the proposed service objects, controller, views, sidebar link, and specs, then seek maintainer decisions on scope and the PR breakdown. Done would mean an agreed feature direction and an approved, testable implementation plan.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Hi, I'm Arnav, a developer interested in Ruby for Good's mission. I've built a prototype feature on a fork and would love feedback on whether it's something Human Essentials would want, and how you'd like it broken into PRs.
Problem
Today banks set on_hand_minimum_quantity by hand and LowInventoryQuery flags items below it. That number doesn't update as demand changes, so slow items can have high minimums (cash and shelf space tied up) while fast movers have none (surprise stockouts). There's also no help deciding how to split an item across partners when requests exceed what's on hand.
What the prototype does
- Demand forecast per item: builds a monthly series from the last 24 complete months of distributions (or partner requests). It tries a few simple models (moving average, exponential smoothing, damped-trend Holt, seasonal naive) and picks the one with the lowest out-of-sample error on a rolling backtest.
- Reorder point + suggested order: a standard periodic-review inventory policy. Safety stock scales with forecast error, lead time and a chosen service level (e.g. 95%). Items are flagged "Order now / Reorder / OK", shown next to the bank's existing manual minimum for comparison.
- Shortage allocation: on an item page, if open requests exceed stock, it shows two suggested splits (proportional vs. max-min fair) with fill rates. It's advisory only and never changes requests or distributions.
It's read-only: no migrations, no changes to existing models or inventory events. New code lives in app/services/replenishment/, plus one controller, two views, a sidebar link, and specs.
- Write-up with the math: https://github.com/arnavt687/human-essentials/blob/main/docs/replenishment.md
- Code: https://github.com/arnavt687/human-essentials/tree/main/app/services/replenishment

Proposed PR plan (small pieces)
- Forecasting / reorder / allocation service objects + unit specs (no UI)
- Replenishment page behind a Flipper flag + request specs
- Item detail page with the allocation suggestion
Questions for maintainers
- Is this a direction you'd want in the app? Should it start behind a feature flag?
- Is there a better place in the nav (e.g. under Inventory or Reports)?
- Would any banks be willing to try it and give feedback?
- Vorherrschende Sprache
- Ruby
- Sterne
- 594
- Forks
- 596
- Ø Merge
- 2 T. 15 Std.
- Gemergte PRs (30 T.)
- 13
Entwicklungsumgebung
Startet den Dev-Container des Projekts im Browser, mit Ihrem eigenen GitHub-Konto.
- Kein Dockerfile und keine Docker-Compose-Datei
- Hat eine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus rubyforgood/human-essentials
-
[BUG]: Export Donations button state not updatingEvtl. vergeben @yashiyadav hat das vor 3 Tagen übernommen. Offen🐞 Bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 64/100
rubyforgood/human-essentials#5744 · 3 Kommentare ·
Maintainer antworten meist innerhalb von 1 Tag
-
Export button on annual report should revert to "Export Report" from "Please Wait..." once report generated.Evtl. vergeben @costajohnt hat das vor 30 Tagen übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 74/100
rubyforgood/human-essentials#5691 · 1 Kommentar · 1 zugewiesene Person ·
Maintainer antworten meist innerhalb von 1 Tag
-
On Distributions, fix line-item column headers wrapping and alignment on narrow screensEvtl. vergeben @Sinkleberg hat das vor 13 Tagen übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 68/100
rubyforgood/human-essentials#5603 · 8 Kommentare · 1 zugewiesene Person ·
Maintainer antworten meist innerhalb von 1 Tag
-
Difficulty—Beginner
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 58/100
rubyforgood/human-essentials#5749 ·
Maintainer antworten meist innerhalb von 1 Tag
-
🐞 Bug
Schwierigkeit 3/5 1-2 Tage Anfängerfreundlichkeit 67/100
rubyforgood/human-essentials#5745 ·
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in rubyforgood/human-essentials
Ähnliche Issues
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
up-for-grabs/up-for-grabs.net#6330 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 75/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 1/5 1-3 Stunden Anfängerfreundlichkeit 72/100
TheOdinProject/curriculum#31490 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Documentation: RSpecRails/FileFixture and RSpecRails/ReceivePerformLater cops missing from websiteOffen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
rubocop/rubocop-rspec_rails#136 ·
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 68/100
hotwired/turbo-rails#791 ·