It could definitely be intolerances.
This website [
Food intolerance Network Has a heap of information on it. What you need to be looking at is Salicylate intolerance. This is an acid in fruits & vegetables, most concentration is just beneath the skin.
He might have a certain amount he can eat of pumpkin, so let him have a few days back on his original diet until he's sleeping better & then start introducing pumpkin again by small amounts & increase it daily to you find a level that he can eat. Intolerances improve with age as the body gets bigger.
What type of pumpkin did you use? The lowest salicylate pumpkin is butternut if you are making it yourself. I usually leave them to ripen for a few weeks before using ones I get at the supermarket.
Pears are also a great first food. I've found the baby food ones fine.
Specific pages.
Sleep disturbance
Feel free to ask questions, I live this daily.