The House and the Senate squared off again yesterday over last year's deficit-reduction legislation as Republicans and Democrats on the Senate Budget Committee edged warily toward a bipartisan compromise on a budget blueprint for next fiscal year.

A budget compromise under consideration last night would provide about $295 billion for defense, $25 billion less than President Reagan recommended and $4 billion less than the amount proposed earlier by committee Chairman Pete V. Domenici (R-N.M.) to keep pace with inflation. It would defy Reagan on taxes by proposing $18 billion in new revenues, slightly more than Domenici proposed last week.

Sources said the committee was close to agreement but "not there yet," as Domenici put it.

Meanwhile, the House defied administration veto threats and stood by its own version of a deficit-reduction measure left over from last year.

It voted 217 to 192 to reject a compromise worked out between the Senate and the president's Office of Management and Budget and then reaffirmed support for its own version, 331 to 76.

Within hours, the Senate voted by voice to insist on its version and shipped the measure back to the House. Senate Majority Leader Robert J. Dole (R-Kan.) said discussions on a compromise are under way with the House and predicted an agreement may be possible within a day or two.

But, earlier in the day, presidential spokesman Larry Speakes appeared to rule out compromise. He said the Senate measure is acceptable but added that "if there are any changes, and I underscore any changes . . . the president's senior advisers would recommend a veto."

The measure would save an estimated $18 billion over three years, about one-quarter of the savings anticipated last year before the bill got caught in House-Senate cross fire, exacerbated by administration objections to provisions proposed by both chambers.

In arguments yesterday, House Democrats criticized the Senate for negotiating with the White House rather than the House and twitted Senate Finance Committee Chairman Bob Packwood (R-Ore.) for modifying Medicare provisions to provide a windfall for Oregon hospitals. Republicans contended that the House was consigning the measure to a "dark hole" by sending it back to the Senate. The Senate's version, they said, was better than nothing.