We don't know what is necessary for human level intelligence, so let's take the human brain as a staryting point, and look at three characteristics:
- weight: our brains weigh about 1.5 kg. As noted by @Slarty, some humans show intelligence with almost half their brain removed, so there's probably some room to maneuver.
- calories: our brains require at least 260 kcal a day To function.
- blood supply: our brains require about 750 millilitres per minute, or 15% of the cardiac output
The largest animal known to be able to fly is the Quetzalcoatlus. Conservative estimates of its weight are around 80 kg, with 250 kg more likely. This puts it in range of a human body, so it makes it a good candidate.
Step one, brain weight. Can we put 1.5 kg of brain into the Quetzalcoatlus' head without breaking stuff? One promising target is the gigantic beak. If we change the intelligent bird's diet (and require them to speak) we may be able to get rid of 90% of the beak and replace that weight by a brain. I can't find the weight of a Quetzalcoatlus skull, but in humans, the entire skeleton is about 15% of our weight, and despite having hollow bones, birds' skeletons have roughly the same weight. With that figure, conservatively estimating the beak to be one twentieth of the skeleton, we get a weight saving of about 0.5kg if we shorten the beak by 90%, if the body weight is 70kg. For less conservative estimates of the body weight, we get closer to 1.5kg.
Next up, calories. For non-passerine birds, the calorie intake per kg is pretty similar to mammals. Assuming 70kg body weight, we get around 2000 kcal, assuming 200kg, we get 5000 kcal. Either way, the 260 kcal required for the brain to operate is a relatively small addition, which can probably be handwaved by making the available food a bit more nutritious (possibly as a result of the intelligence increasing with evolution, as it was for humans).
Finally, blood supply. The neck of the Quetzalcoatl is long, requiring a powerful heart to get enough blood up there. Giraffes have a similar configuration. Their brains weight half of what a human brain weighs, and they require an 11 kg heart to supply it with blood. Adding 10kg to a 70kg pterosaur might be a deal breaker. In a 200kg beast, there's probably a bit more wiggleroom.
One obvious solution is to shorten the neck. While many large birds have long necks, others, like bustards and condors have short necks, so the reason the Quetzalcoatlus had a long neck may be more to do with feeding than aerodynamics. So, starting with the (likely sizeable) heart the Quetzalcoatlus already had, if we shorten the neck and the beak, we can keep the cardiac output the same, sending more blood to the brain. As a bonus, since the smaller beak puts the center of mass of the skull closer to the end of the neck, less muscle tissue is required in the neck, which also means more blood for the brain.
I'm sure I've missed something, but looking at these considerations, it seems plausible to put a human brain into something ythat flies the way a Quetzalcoatlus did.
Update after comment
What can we do if we limit ourselves to the basic dimensions of a bald eagle? It is estimated that the maximum wing loading (amount of weight per unit of wing surface) for animals is 20 kg/m^2. I can't find the wing surface of a bald eagle but I recon that with a wing span of 2m, a single square meter is reasonable (the wings are about a quarter as deep as they are wide). In other words the bald eagle is much lighter than its maximum weight. Swans have roughly the same wingspan at twice the weight, so this bears out. They also have much more trouble taking off, so at 12kg we are probably approaching the limit of what nature can do with a 2m wingspan.
So, at 6kg for a standard bald eagle, there is plenty of room to fit in a 1.5kg brain and still be able to lift off.
A bald eagle's diet is about 150 kcal, so it would need to more than double its intake to 310. Cooked food and agriculture should get you some of the way there, but you can also give a much richer natural source of nutrition.
The total cardiac output of a pigeon is 200 ml/min at rest, and 1000 ml/min active. Assuming that this scales linearly, the bald eagle's heart produces about 1200ml/min at rest, which we need to almost double to accommodate the new brain (we can ignore the output required to supply the original 12 grams of brain). Heart mass and cardiac output have a linear relation so we need to double the size of the heart, and probably the lungs as well. The heart mass for anything weighing 6kg is no more than a few tens of grams, so that easily fits our weight budget. Lung mass is closer to a few hundred grams, but still easy enough to double without getting into trouble.
Finally, at this size the skull volume is a big problem. We need to up the cranial capacity from 16 to 1000 cubic cm. Note that this seems worse than it is, due to the cubic relation between scale and volume. Quadrupling the length, width and height of the head would be enough. This would change the proportion of the head and body to something like a toucan. Its head would be around 1/10 of its body. It would be difficult to keep this aerodynamic, but shrinking the brain to the minimum required for intelligence, putting much more brain matter in the nervous system, and elongating it into the neck will go a long way.
In short, I guess you'd end up with something that looks like a swan without a neck, and with giant head, but I think it can work.