UNTIL THIS SUMMER, just about everybody happily assumed that past legislation had put the budget deficit on a path pointed safely downward. That pleasant thought naturally induced a degree of relaxation in Congress and at the White House. People in both places, but especially at the White House, saw less necessity for painful compromises and more opportunity for posturing.

Then the Congressional Budget Office began quietly warning its employers that the pattern had changed since last winter. The path no longer leads downward. On the contrary, if there's no further action, the deficit will soon start rising again. The CBO offered this new forecast in detail in the annual midsummer review that it published last week.

To get the deficit moving down again will require legislation to carry out the budget resolution that Congress passed in June, or something similar. But the budget resolution was designed by the Democratic leadership over vehement Republican objections and, because it requires a substantial tax increase, President Reagan has repeatedly promised to veto any bills that try to implement it. The deadlock now looks a good deal more dangerous than it did a month ago.

CBO says that it changed its earlier forecast for two reasons. First, because of last year's tax reform act people are rushing to cash in their capital gains before the preferential rate fades away. That's raising revenues much higher than the forecasters expected in the current fiscal year -- which ends in six weeks -- but means lower revenues in the following years.

Beyond that, interest rates and inflation are both running higher than CBO anticipated six months ago, and both push spending up automatically. The result is that, instead of the $176 billion that CBO forecast last winter, this fiscal year's deficit will be only about $156 billion. But in the year beginning Oct. 1, in the absence of more deficit-cutting legislation, it will be back up around $183 billion with no improvement visible in the years beyond.

Over the past year the American economy has benefited enormously from the general belief that the federal government has at last found the political will to bring its budget deficit down, surely and steadily. If President Reagan and the Democratic leadership of Congress between them now allow that belief to evaporate, they will invite the kind of leap in interest rates that can throw the country into a recession. The fault for the present deadlock lies chiefly with Mr. Reagan. But if it cannot be broken promptly this fall, the costs next year will reach far beyond politicians' reputations