The United States and the Soviet Union began talks here yesterday about Afghanistan in the third round of an exchange of views between specialists of the two governments on various regional disputes in which they are involved.

U.S. officials, who refused to comment officially, were understood to view the talks primarily as an occasion to ascertain if there has been any change in the Soviet attitude toward a negotiated settlement of the 5 1/2-year Afghan war.

Indian Prime Minister Rajiv Gandhi told administration officials here last week that he thinks, based on his talks with Soviet leaders, that Moscow may be more seriously interested in negotiations.

"I think they would accept a neutral, nonaligned Afghanistan," Ghandi said on the "McNeil/Lehrer NewsHour" last Friday.

The Indian leader said the Soviets had shown an interest in discussing this, and he indicated that his government is prepared to help solve the conflict peacefully.

The administration reportedly remains unconvinced of any significant shift in Soviet policy toward Afghanistan since the advent of Soviet leader Mikhail Gorbachev, but is interested in seeing whether some inkling of change emerges during the two days of talks here.

The last talks on Afghanistan, held in Moscow in 1982, produced only an exchange of opposing views.

The talks here coincide with the opening today of further so-called "proximity talks" in Geneva between the Soviet-backed Afghan government and Pakistan under U.N. auspices. The last round was held there two years ago.

Those talks have produced no breakthrough but could be another occasion for the Soviets to signal whether they are more interested in a negotiated settlement.

Leading the U.S. delegation in talks here was Assistant Secretary of State Richard W. Murphy, head of the Near Eastern and South Asian Affairs bureau.

On the other side are Oleg M. Sokolov, minister-counselor of the Soviet Embassy, and Yuri Alekseyev, chief of the Middle East division of the Soviet Foreign Ministry.

The talks are being held at the State Department yesterday afternoon and this morning, according to State Department officials.

Murphy, who was in Vienna Feb. 19-20 for the first round of U.S.-Soviet talks on Middle East issues, brought up the question of Afghanistan then. But Moscow reportedly was not prepared to deal with the question then.

The second set of talks, in Paris last month, dealt with southern Africa.