Inflammation plays a causal role in dampening certain cognitive functions.
Healthy men that were given a typhoid vaccine that caused a temporary inflammatory response had lower brain activity related to staying alert compared to when they got a placebo injection. Other attention processes did not seem to be affected by inflammation. The authors of this study think that this could explain "brain fog" in people with chronic inflammation.
Other studies have used similar methods used in this study to show that inflammation plays a causal role in depression.