Brain in the Dark: Design Principles for Neuro-mimetic Learning and Inference