It's not entirely clear to me that all of cognition isn't simply pattern matching with learned responses. It seems the human brain may just be doing more nuanced matching / responding.
I remember reading (don't remember where) that the current state of machine learning is a lot like the state of bridges a few thousand years ago. People basically try different approaches using intuition and sometimes if the results are good they'll tell other people about it, nowadays in the form of research papers getting published. However, the generalized equations that facilitate modern civil engineering were far from existing. Similarly, we don't yet have general equations to derive or optimize a machine learning algorithm for a given problem as input, we just choose an algorithm, choose parameters that we think make sense, go through a lot of trial and error, then let the algorithm run.
There's a lot that's still not understood about the brain. Even at the cellular level, microglia have gained attention recently for their contribution to human learning [1]. The NN algorithm was modeled after human neurons for having n inputs and 1 binary output. It's hard to say how cells that regulate the cellular environment and communicate with each other via cytokines would affect the abstraction of the brain to an algorithm or mathematical model. At least for this example, there's a book called "the other brain" about how glia, which make up ~85% of the brain, perform a myriad of operations beyond just keeping neurons together [2].
But you could also look at the brain through a genetic lens. A lot of the neurosystem is simply hardwired. The knee-jerk response is a reflex arc, which means the signal goes directly from the sensory nerve to the motor nerve (causing you to kick) before it even gets to your brain. That reflex response has been hardcoded into your DNA. How much of the rest of the brain is learned vs. predeterminantly structured?
Cognition can probably be reduced to just pattern matching with learned responses, but it's a bit like an ancient Roman looking at New York City skyscrapers and saying "these are just built using arches and a lot of nuance".