How does a man like retired Lieutenant General Mike Flynn—who spent his life sifting through information and parsing reports, separating rumor and innuendo from actionable intelligence—come to promote conspiracy theories on social media?

Perhaps it’s less Flynn who’s changed than the circumstances in which he finds himself—thriving in some roles, and flailing in others.

In diagnostic testing, there’s a basic distinction between sensitivity, or the ability to identify positive results, and specificity, the ability to exclude negative ones. A test with high specificity may avoid generating false positives, but at the price of missing many diagnoses. One with high sensitivity may catch those tricky diagnoses, but also generate false positives along the way. Some people seem to sift through information with high sensitivity, but low specificity—spotting connections that others can’t, and perhaps some that aren’t even there.

Take, for example, Ray Stanford—the Maryland man who, as The Washington Post memorably put it, “sees things other people don’t.” Stanford found real fossilized dinosaur footprints where scientists said they couldn’t be, and where others saw only dimpled rocks. Hundreds of them. His work has rewritten scientific understanding of dinosaurs on the east coast. But that’s not all he sees. His real passion, it turns out, is spotting UFOs. His first encounter came in 1954.

Then there’s the legendary investigative reporter Seymour Hersh. From the My Lai massacre to Project Jennifer, Hersh has assembled a shelf-full of journalistic prizes by unearthing secrets, documenting cover-ups, and breaking stories that others dismissed as too crazy to be true. But critics allege that some of his work—particularly stories written without the fact-checking apparatus of The New Yorker, like his biography of JFK, or his investigation of the killing of Osama bin Laden—shows excessive credulousness.

Much of Flynn’s military career was equally brilliant and distinguished. As director of intelligence for the military’s Joint Special Operations Command, he fearlessly challenged convention. As Dana Priest has reported, when JSOC staged raids, Flynn had personnel gather scraps of intelligence—cell-phone numbers, addresses, pocket trash. They relayed what they found back to Flynn and his analysts, who took these disparate data points and drew connections among them, spotting patterns and creating actionable intelligence. JSOC began rolling up networks it hadn’t been able to crack.

But there was another ingredient, equally crucial to Flynn’s success. General Stanley McChrystal, then Flynn’s boss, harnessed his remarkable capacity for drawing connections while working to contain it, Priest reported:

He “boxed him in,” someone who had worked with both men told me last week, by encouraging Flynn to keep his outbursts in check and surrounding him with subordinates who would challenge the unsubstantiated theories he tended to indulge.

That reporting suggests that McChrystal saw the extraordinary value in Flynn’s sensitivity, recognizing that Flynn might spot things others would miss, so long as he was embedded in a system that could supplement it with specificity, knocking down suppositions and leaving only the solid claims standing. But, as The New York Times wrote, once Flynn found himself in command of the Defense Intelligence Agency, his sensitivity was no longer balanced by specificity—there was no one to steer him away from false positives:

His dubious assertions are so common that when he ran the Defense Intelligence Agency, subordinates came up with a name for the phenomenon: They called them “Flynn facts.”

Flynn soon found himself embroiled in controversy, and he was forced out of the DIA a year early. His allies blamed an intransigent bureaucracy, resistant to his efforts at reform. His critics tell a different story, describing a man who brooked little dissent, and indulged in conspiratorial thinking. Sources told The New York Times about one such incident, after the Benghazi attack:

Iran had a role in the attack, he told them. Now, he added, it was their job to prove it—and, by implication, to show that the White House was wrong about what had led to the attack.

Despite Flynn’s insistence, solid evidence tying Iran to the attacks never surfaced. To his critics, the episode illustrates a tendency to connect dots to form patterns that don’t exist. Flynn himself has perhaps reinforced that case by repeatedly claiming to have been pushed out over his views on radical Islam—despite a lack of evidence to support that claim.

Flynn doesn’t lack for defenders, who dismiss such attacks. Jason Criss Howk, who worked with him in Afghanistan, described him as an “eager listener who quickly saw flaws in plans and questioned ideas that were weak.” But Sarah Chayes, who also worked with Flynn in Afghanistan, described him to the Times as “a very talented information gatherer” whose “thinking process is not sufficiently analytical to test some streams against others and make sense of it, or draw consistent conclusions.”

Now, Flynn has been tapped to serve as President-elect Donald Trump’s national-security adviser, a position in which he’ll be charged with coordinating the nation’s complicated and competing national-security agencies, in addition to overseeing his own staff of hundreds. Flynn’s advocates point to his distinguished service as evidence he’s equal to the job, and his critics insist that his recent conspiratorial tweets prove he’s unsuited to the role.

But the question isn’t whether Flynn is the right choice, but whether Trump will scope and define his job in the right way—enabling him to succeed. At JSOC, he reported to a commander who apparently demanded that he discipline his outbursts and empowered his subordinates to rigorously test his ideas. He performed brilliantly. At the DIA, by contrast, he ran his own show, and reportedly demanded that his subordinates validate his ideas. He was promptly forced out.

One way to read Flynn’s record is as a reminder that our greatest assets are often also our greatest flaws—and it’s the circumstances in which we’re placed that enable success, or trigger failure.