Even within a market there is top down planning. What gets produced is decided by makers who use the feedback of the market to change what they make. The consumers usually have no say about what gets made and how it's made outside the narrow, low information way of the spot trade.
In othet words, people would not have created markets sans their explicit imposition by states. They are not a bottom up structure because no sane person would participate in them if they didn't have to.
Prior to markets were webs of debt relations. See 'Debt the first 5000 years' by David Graeber.