SAN FRANCISCO (AP) _ Convicted spy Jerry Whitworth is filled with remorse for divulging Navy secrets, and wants to rectify the harm he has caused, according to court papers quoting his first public statements about the case.

''My heart aches from the damage, pain and suffering I've caused,'' the former Navy communications officer was quoted as saying.

The papers, filed Tuesday by defense attorneys in U.S. District Court, also revealed that Whitworth had offered to plead guilty to two conspiracy charges. He is to be sentenced Thursday for his conviction on those charges plus 10 others, seven of which carry maximum life prison terms.

A jury last month convicted the 47-year-old Davis resident for selling Navy codes and communications secrets for $332,000 to the Soviet-controlled spy ring run for 17 years by his long-time Navy buddy John Walker Jr.

The Whitworth papers ask for a sentence no harsher than Walker's, which is pending.

Whitworth, who did not testify at his trial, was ''racked with guilt and remorse (and) dedicated to rectifying the harm he has caused this country,'' defense attorney James Larson said.

Since his conviction, Whitworth has been questioned by federal agents for three days, expects more sessions and is willing to take a lie-detector test, Larson said.

In the court papers, Dayle Carlson, an investigator hired by the defense, quoted Whitworth as saying:

''I have been fully aware of my mistakes in this matter, and the reality that my actions have been a betrayal of the trust given to me by my country, the Navy and the confidence of my wife, my family and my friends. ...

''I pray for an opportunity to redeem myself.''

Carlson also quoted Whitworth as saying he accepted Walker's recruiting offer in 1974 because Whitworth was disillusioned about events like Watergate and Vietnam.

He said Whitworth told him he believed Walker's statement that the secrets were being bought by Israel and that he was ''attracted by the mystique'' of spying for the Israelis.

Whitworth told Carlson he learned around 1980 that Walker had lied about Israel, but said he continued to supply material because of Walker's insistence, his own inability to confront Walker and Walker's threats.

Defense attorneys also made public a Feb. 21 letter to prosecutors in which Whitworth agreed to plead guilty to conspiracy to commit espionage and conspiracy to defraud the government out of tax revenue.

The letter said Whitworth knew more about the documents than Walker, and would agree to undergo a complete debriefing about what he had passed.

In return for the plea, the prosecution would have to agree to a life sentence, drop the remaining charges, tell the sentencing judge about Whitworth's cooperation and agree to bring no charges against Whitworth's wife, Brenda Reis. She was not charged.

The Justice Department would agree only to an unconditional guilty plea, the defense papers said.

On Monday, prosecutors asked Judge John Vukasin to sentence Whitworth to at least 150 years imprisonment without chance of parole for 50 years. With a life term, he would be eligible for parole in 10 years.

Larson asked that the sentence be no harsher than that of Walker.

Walker pleaded guilty to espionage last fall in a plea bargain in which prosecutors agreed to seek a life sentence with parole possible in 10 years, and a 25-year sentence for his son, Michael, who also pleaded guilty. Walker's brother Arthur has been sentenced to a life term for his espionage conviction.

John Walker's sentencing, originally scheduled for Thursday in Baltimore, has been postponed until Oct. 3.