SEATTLE, WASH. (AP)–Josh Fields knew he wasn’t as sharp as the previous two nights, when he saved games against the Mariners.

Kyle Seager noticed, as well, jumping on a first-pitch fastball and ending Houston’s hope of sweeping Seattle.

“As soon as he hit it, I knew he gave it a ride,” Fields said.

Seager hit a three-run homer with one out in the bottom of the ninth, and the Mariners rallied for a 5-3 win Wednesday that stopped an eight-game losing streak.

Fields had shut down Seattle, the club that originally drafted him, the previous two nights. But after giving up singles to Robinson Cano and Corey Hart to open the inning, Fields knew he was a little off.

Fields (0-1) recovered to strike out Justin Smoak but left his fastball over the plate for Seager.

“Just one of those days. I left a couple of balls up and paid for it,” Fields said. “I’m not going to go out there and throw zeroes every time. Now I’ve got to learn, look at what I did. Being the backend guy, it’s all about that short memory.”

Seager homered for his second straight at-bat after being mired in a slump for most of the season. Seager hit a two-run homer in the seventh off Jarred Cosart, then added the winning drive in the ninth.

It was the third multihomer game of Seager’s career, and the five RBIs were a career high. Seager had not homered since Sept. 3 of last season at Kansas City. Seager entered hitting just .156 with two RBIs.

“Any time you see the ball hit the ground, it’s obviously a big confidence booster,” Seager said. “It has felt better the last couple of days and today it showed up. Thankfully.”

Seattle’s late rally spoiled what was looking to be a sweep for the Astros.

Cosart took a shutout into the seventh after failing to make it out of the first inning in his previous start. The Astros got a two-run double from Jason Castro in the third inning and Chris Carter’s second homer of the series in the seventh to take a 3-0 lead.

Still, Houston’s batting average for the season dropped to .199 after managing just six hits.

Houston got its first two runs because of starter Chris Young’s struggle with control. Young finished with five walks, including a trio in the third inning. Young walked Matt Dominguez on a 3-2 pitch to start the inning, then did the same to Dexter Fowler with two outs. Castro followed with a line drive just fair down the right-field line and both runners scored.

Houston added another in the seventh when Carter hit a solo homer on a 3-2 pitch. Young had retired 11 of 12 batters prior to the Carter homer.

Cosart went 6 2-3 innings giving up four hits and struck out four. It was the opposite of his last start when he gave up seven runs and recorded only one out against Oakland.

But he was upset with the way he pitched in the seventh, giving up the single to Smoak that led to Seager’s first homer that pulled Seattle to 3-2.

“Basically comes down to I didn’t execute my pitches when I was ahead in the count,” Cosart said. “I went 3-2 on Seager. I wanted to go inside and left it over the plate.”

Fernando Rodney (1-1) got the victory, pitching the ninth.

“The most demoralizing loss in baseball is a late-inning loss, when you have the game won,” Houston manager Bo Porter said. “Since I’ve been here, we’ve had our share of them.”

NOTES: Seattle RHP Taijuan Walker (shoulder) and LHP James Paxton (back) will begin recovery throwing programs within the next week. Seattle manager Lloyd McClendon said Paxton has been cleared to start throwing Friday and Walker next Monday. … Carter has hit seven career homers at Safeco Field. … Seattle won on a walkoff homer for first time since last June 23 vs. Oakland.

Follow Breitbart Texas on Twitter for the latest headlines @BreitbartTexas