*** This is far away from prod ready. only spent couple of housr late at night missing test and some abstractions. this is quick and dirty due to time limi***
the idea I went with is load the data into in memory db (simulate real DB), and persist the size of texts with number of times each size appear. this saves the time of loading from DB.