Budget director David A. Stockman signaled to Congress yesterday that there may be room in next year's budget for some compromise on tax cuts and defense spending, two areas where President Reagan earlier said he would not bend.

While Stockman ruled out any "fundamental retreat" on defense or tax policy, his testimony before the House Budget Committee drew praise from Democrats as the most "conciliatory" budget gesture thus far from the administration.

"I count it as progress and hope," said Committee Chairman James R. Jones (D-Okla.), who added that Stockman's testimony "gives running room to allow a compromise to evolve" although there is still "a long way to go."

Under pressure from Republicans as well as Democrats who are unhappy with his proposed 1983 budget, especially its $91.5 billion deficit, Reagan said last week that Congress had "running room" to consider changes in the spending plan so long as it didn't tamper with his tax and military buildup programs.

In nuances rather than specifics--"atmospherics," Stockman called them--the budget director appeared to go a little further yesterday in extending an olive branch to Congress.

"At this stage of the process, we've presented our best shot . . . we've got a good budget," he told the committee. "The next stage is up to you. I believe this administration, and I think this president, will look very carefully at a good faith, sincere effort on the part of the responsible leaders of Congress . . . to propose something different."

But, while congressional alternatives might include changes in the tax and defense programs, it would be a "grave mistake" to rely "mainly or solely" on these areas for major deficit reductions, Stockman added.

Asked by Rep. Les Aspin (D-Wis.) if the administration would reject a $10 billion cut in its $221 billion defense buildup program, Stockman said there "may be room" for additional savings but added that a cut of $20 billion to $30 billion would be unacceptable.

Aspin agreed but said he thought a cut of up to $10 billion would be "responsible." Stockman again dodged comment on a $10 billion cut, responding simply that the budget process is a "two-way street."

On the issue of the tax cuts that Congress approved last year at Reagan's behest, Stockman urged Congress to "take a look at the revenue code but don't reverse the important and fundamental changes" that it approved.

While this would rule out any tampering with the large individual tax cuts scheduled for 1982 and 1983, which some lawmakers want to defer or repeal to help reduce future deficits, the entire tax package wasn't "chiseled in stone," Stockman said.

His conciliatory tone helped defuse what had been billed in advance by some as a potentially explosive confrontation: Stockman's first appearance before the Democratic-controlled committee since his embarrassing admissions about preparation of the 1982 budget in a magazine interview late last year.

There were several questions about "credibility," and Rep. David R. Obey (D-Wis.) delivered a blistering attack on what he called the "crude economic Darwinism" of the budget and then refused to ask Stockman any questions on grounds that "very frankly, I wouldn't believe any answers you gave me."

But most of the salvos were aimed more at the budget than the budget director.

"I don't think there's anyone who thinks this budget's going to fly, and anyone who thinks that it will is nuts," said Rep. Leon E. Panetta (D-Calif.). Republicans are supposed to be against borrowing but "all you do is wind up borrowing for your programs," he added.

Moreover, he said, at least half the spending and revenue measures the administration has proposed to keep the deficit to $91.5 billion for next year are in trouble, which would mean a deficit of at least $120 billion for fiscal 1983.

"If we continue on the course we're on today," said Rep. Richard A. Gephardt (D-Mo.), "the deficits will stay high, and we'll wind up with the biggest damn mess you've ever seen."

Jones said the administration has a "major credibility problem" with Congress because of the budget and its projected deficits and warned that the alternative to compromise with Congress will be to "ride our economy and our people down to disaster."

Several Republicans rose to the defense of Stockman and the administration but few if any volunteered all-out support for the budget.

Rep. Delbert L. Latta of Ohio, ranking Republican on the committee, conceded he had been "shocked" by the deficit projections and asked Stockman for suggestions on how to reduce them.

Stockman said Congress should first be concerned with making enough spending cuts to assure that the deficits will not go even higher.