[R] How fresh are your blueberries? And what would you do if you knew?
https://oliverevans.dev/blog/blueberries-voi/
In this article, I look at fresh produce ordering strategies. I formulate an explicit "freshness" variable that decreases over time according to a Gamma process, with a temperature-dependent rate. I look at various observation scenarios (do we know when it was harvested? what the transit temperatures were? How is waste tracked in the store?, etc.)
I use a particle filter to estimate the latent freshness given these partial observations, and implement a controller to attempt optimal ordering given these beliefs.
But my controller is not that good! So I made a Jupyter notebook where you can try to implement your own controller against my simulator and filter, and try to beat mine.
I would love to hear your thoughts and solutions!
Posted Sep 4, 2026, 8:26 PM UTC