Negotiators are expected Sunday to reach a provisional agreement that could curb Iran's nuclear program in exchange for sanctions relief.

According to two diplomats quoted by the Associated Press, the final details of the deal were still being worked out Sunday afternoon. A formal agreement still awaits a review from the capitals of the seven nations at the talks — Iran, the United States, Russia, China, Germany, France and Britain — with hopes the deal could be announced on Monday.

A senior U.S. official told AP that "major issues remain to be resolved in these talks" and he declined to speculate on the timing of any agreement.

Other senior U.S. and Iranian officials cast doubt on the claims. All of the officials spoke anonymously to the AP because they are not authorized to speak about the negotiations publicly.

"We are working hard, but a deal tonight is simply logistically impossible," Alireza Miryousefi, a spokesman for the Iranian delegation, wrote on Twitter. "This is a 100-page document, after all."

U.S. Secretary of State John Kerry, who had threatened to walk away earlier in the week, said Sunday "a few tough things" still stand in the way of a deal but that "we're getting to some real decisions."

He said twice he was "hopeful" after a "very good meeting" Saturday with Iranian Foreign Minister Mohammad Javad Zarif Saturday. The AP spoke to Kerry en route to Mass at Vienna's Gothic St. Stephens Cathedral.

"I hope that we are finally entering the last phase of this negotiation," French Foreign Minister Laurent Fabius told reporters Sunday, sounding cautiously optimistic, reported the AP.

The current round of negotiations in Vienna have taken more than two weeks and blown three deadlines.

The long-term comprehensive deal aims to restrict Tehran's nuclear program in exchange for sanctions relief.