David Stockman's account of his days as President Reagan's budget director should be required reading for all ideologues who conspire by legal means to subvert, undermine or take over a democratic government.

In "The Triumph of Politics: Why the Reagan Revolution Failed," Stockman is self-cast as a young knight who vows to do battle with the dragon of Big Government. He is surrounded by a boob of a king and cowardly and incompetent retainers. Eventually, he is vanquished by the dragon, but his life is spared because the king turns out to be tender-hearted as well as witless.

As Stockman's engrossing fable ends, we leave King Reagan and Company living in a fool's paradise where the happy populace is unaware that the realm is threatened by the shades of Herbert Hoover. The once-proud knight has, in his strange words, checked his "intellectual valuables" into a handy safe and is busy making money hand over fist. The reader wonders why the errant knight seems so unhappy.

What I am wondering is why this book stirs my sympathies for Reagan and makes me so jittery about Stockman. As a journalist, I appreciate Stockman's candor, intelligence and accessibility. As a Reagan biographer, I value Stockman's insights and suspect that his score-settling will inspire other books that go beyond happy talk. As a citizen, I wish that White House officials would stop cheerleading and show some of Stockman's belated concern for balancing the nation's books.

All that said, this memoir raises troubling questions about Stockman's values and gives reassurance about Reagan's. It is comforting to learn that neither the president nor the cadre of advisers whom Stockman despises had any stomach for the human hardship they would have caused by dismantling the federal welfare state. I suspect that many people less bright than Stockman figured this out during Reagan's two terms as governor of California and realized that he would not try to undo the New Deal even if he could.

As Stockman leads us through changes of the heart, head and economic strategy, he consistently exhibits the essential characteristics of an elitist. He doubts that many others are his equal, either in intellect or motives. When he comes across an item of common wisdom, as in the observation that Reagan prefers ancedote to analysis, he breathlessly presents it as an original discovery. He does not respect the political process.

Stockman told me last week that he had determined that Reagan was a "revolutionary" by listening to his advisers and reading some of his radio speeches. If he were less elitist, he would have paid more attention to Reagan's actual record. It is fair to say that Reagan would have self-destructed politically during his first term as governor if rhetoric had been the only measurement of his governance.

Those of us who think that politics is the essence of democracy rather than a barrier to its operation should be reassured by the incident described by Stockman in which Reagan tells Republican congressional leaders that he won't cut Social Security because he had promised not to do so during the 1980 campaign. But it is disturbing to learn that Stockman ceased to believe in 1981 in the "Reagan Revolution" he claims to have created -- and then stayed on for nearly four more years practicing his magic tricks with the budget. If Stockman believed in ideas as much as he proclaims, he might have quit on principle and made it difficult for Reagan to seek reelection on the empty slogan of "You ain't seen nothing yet."

Stockman told me he still considers himself a Republican conservative. I wonder why, in view of the case he makes for a humane social democracy in the closing pages of his book. Maybe he is the remnant of the ideologue described in his memoir, wealthy now and still seeking a talisman that will describe the workings of the world. Maybe he does not believe in anything very much.

As for Reagan, Stockman richly documents his ignorance. What eludes Stockman is an appreciation of Reagan's values and Reagan's political gift of sensing when it is time to change course or represent a compromise as victory. Reagan believes in the system more than Stockman does. Thank God that Reagan is a politician.

Reaganism of the Week: Asked by columnists last Wednesday why he thought the Soviets won't establish a naval base in Libya, the president said: "I think maybe they have a case of the smarts."