Exploring cognition as a controlled hallucination reveals profound implications across various brain functions and machine learning. The concept of predictive coding highlights how sensory data is processed efficiently, akin to convolutional methods in AI. Additionally, beliefs and desires are updated through similar predictive mechanisms, emphasizing the parallels between human cognition and algorithmic models.