The bullpen mounds out in the right field corner sat empty, monuments to convention, as the Washington Nationals’ season unraveled. On the mound in the middle of the diamond, Aaron Barrett withered. The Nationals had surged during the regular season to the best record in the National League. They had assembled a deep pitching staff, made deeper by the possible use of Stephen Strasburg as a reliever. They had a tie score to protect because Bryce Harper had launched a baseball clear out of AT&T Park, hanging like one more star over McCovey Cove.

In the dugout, first-year Manager Matt Williams watched as their season ended like this: a rookie spiked a fastball with the bases loaded while the Nationals’ two best relievers and Strasburg watched from the bullpen. In a moment that demanded urgency, Williams chose orthodoxy.

A thrilling season melted into an agonizing National League Division Series for the Nationals, and it all reached a brutal conclusion Tuesday night. The 96-win Nationals packed for the winter after the San Francisco Giants’ 3-2 victory in Game 4, a loopy, riveting classic that sent the top-seeded Nationals home.

“Brutal,” reliever Tyler Clippard said. “It’s brutal. We played good enough to win probably every game, and came up a little short.”

Clad in red sweatshirts, the Nationals hung on the railing of the first base dugout and watched the Giants gather on the mound after Wilson Ramos’s grounder to second ended their season. They will spend the winter wondering what could have been different in a series in which all three losses came by one run. The Giants and the Nationals both scored nine runs in the series. But the Nationals still must fight the label many will affix to them. In two out of three years, they have posted the best record in the National League and failed to advance past the first round of the playoffs.

Washington Nationals players expressed a mixture of pride and regret after their loss to the Giants on Tuesday, with some already looking forward to spring training. (Whitney Leaming/The Washington Post)

“If I had the answer, I would have probably made the adjustment,” shortstop Ian Desmond said. “This is going to be something that we look back on when we regroup and find an answer to this question.”

The Nationals’ offense bears the brunt of the blame, scoring just nine runs in 45 innings. They scored a third of their runs on solo homers by Harper and received more than a quarter of their hits from Rendon. All series, they fouled off fat pitches and chased balls out of the zone. Jayson Werth — one of the only Nationals who declined to speak to reporters afterward — and Adam LaRoche, the Nationals’ No. 3-4 hitters, went a combined 2 for 35.

“It’s just tough, because we didn’t play to our ability, man,” center fielder Denard Span said. “Nobody did. We played our worst baseball these last three, four games. We had an opportunity to win every single game. But point-blank-period, we just didn’t step up. I didn’t step up. A lot of guys. That’s going to be tough going home, knowing we didn’t step up when it counted.”

But Game 4, the finale, will be remembered for the way Williams tried to coax the Nationals through the seventh inning. After Harper’s blast pulled the Nats evenin a do-or-die game, Williams stuck to the same plan he would have used in a July affair against the New York Mets. He called on veteran Matt Thornton and Barrett, the rookie.

“Because those are our seventh-inning guys,” Williams said. “That’s how we set this up. We had two lefties at the top of the inning, and if we got to the righties, we were going to Barrett. That’s what he’s done for us all year long. We’re certainly not going to use our closer in the seventh inning.”

Against Thornton, Joe Panik smacked a one-out single to left. Thornton stayed in to face right-hander Buster Posey, who followed with a rocket to center. Suddenly, the go-ahead run stood on second, Hunter Pence walked to the plate and the Nationals’ season hung in the balance.

Williams walked to the mound, turned to the bullpen and called not for Clippard, an all-star, or Drew Storen, who led the majors in relief ERA. He didn’t consider using Strasburg, whom he said was available before the game but afterward said would be used in “emergency only.”

“Anything’s possible in a game like that,” Clippard said. “Stras had his spikes on. Who knows?”

Williams did not veer from his season-long plan. He summoned Barrett.

“We have to have our guys there if we get a lead there,” Storen said. “We’ve had great late-inning success. Our hitters are still fighting. With the bullpen we have, I feel comfortable putting anybody in any situation.”

Barrett had been murder on right-handed hitters all season and had shown an ability to handle big moments — on opening day, in his major league debut, he pitched the ninth inning of a scoreless game. Barrett had not faced circumstances like this.

“It was a little more magnified than the other games, for sure,” Barrett said. “Since my debut, I came in that same situation, tie ballgame. All those outings that I’ve been through in those spots definitely prepared me for tonight.”

Barrett nibbled around the plate with his fastball and walked Pence to load the bases. The bullpen remained dormant, and so Barrett faced Pablo Sandoval — a hitter who flails against lefties but crushes right-handed pitchers.

With a 2-1 count, Barrett dumped a fastball in the dirt that scooted past Ramos. Panik charged home with the go-ahead run.

“I didn’t make my pitches,” Barrett said. “The spiked fastball is the one that hurt the most. I got lucky with the wild pitch over the backstop. The bottom line is, I didn’t make pitches when I had to, and it cost us the game.”

First base had opened, and Williams ordered Barrett to intentionally walk Sandoval as Rafael Soriano warmed up. Barrett — who as a rookie-ball pitcher years ago overcome the yips — went to throw the fourth ball. The pitch sailed over Ramos’s head.

The botch became a blessing. The wild pitch caromed off the backstop bricks and right into Ramos’s mitt. As Posey sprinted home, Ramos turned and fired to Barrett, who snagged the ball in front of the plate and slapped a tag on Posey’s legs. A sure insurance run had turned into the second out.

“As soon as the ball left my hand, I didn’t even feel it come out of my hand,” Barrett said. “I honestly have no idea what happened. I was just trying to get it to Ramos, and the next thing I know, it went over his head. It ended up working out. I don’t know how. Maybe I’ll have to practice that one in the offseason.”

With two runners on base, Williams kept Clippard and Storen holstered and called on demoted closer Rafael Soriano, who ended the inning. Clippard and Storen did not pitch the eighth either, and Williams stayed with Soriano. He delivered a scoreless inning. But in final game of the Nationals’ season, Clippard, Storen and Strasburg never saw the mound.

Promise had filled the top of the seventh. After Harper had hit a Hunter Strickland fastball into the third deck at Nationals Park in Game 1, Strickland told the San Francisco Chronicle he would pitch Harper the same way if he had the chance. With one out in the seventh, Harper walked to the plate.

Strickland fell behind, 3-1, and challenged Harper with a 97-mph fastball at the belt. Harper unleashed a malevolent swingfull of bad intentions. The ball launched down the right field line. Harper watched it as it hung in the air. The wind blew toward center field. Harper dropped his bat and started walking. The ball zoomed over the foul pole.

“I respect him giving me another 3-1 heater,” Harper said. “That takes a lot of cojones, to be able to do that. I tip my cap to him.”

The Nationals in the dugout pointed their hands and screamed fair, and the umpire stationed down the right field line agreed. Harper thrust his right fist in the air and pointed to the sky with his index finger as he circled first base. He glared at Strickland as he trotted to second.

As he concluded his third home run trot of the series, Harper stomped down the dugout steps and screamed in teammates’ faces, bruising hands with crazed high-fives. He hugged Werth, and the pair leapt up and down in full embrace, Werth smiling and Harper glowering. When they broke up, Harper turned toward the mound and screamed.

“That’s something you dream about,” Harper said. “To be able to do that, my emotion is I’m going crazy. I don’t even know what I’m doing you could say because I’m going so crazy and I’m so happy about it. They got the upper hand and they beat us, so that homer was nothing.”

Harper had also given the Nationals’ their first run. Desmond led off the top half with a laser to left field, the Nationals’ first hit of the night off Giants starter Ryan Vogelsong. Harper fell behind, 1-2, and refused to chase two pitches just off the outside corner. Vogelsong tried a slider on the outside edge, and Harper sent a hard grounder down the left field line. As the ball rattled around the corner, Harper sped to second and Desmond crossed with the Nationals’ first run, slicing the Giants’ two-run lead in half.

The Nationals had a chance to tie the game with a man on second and no outs, and an only-in-October moment played out. Because Nationals starter Gio Gonzalez’s spot would come up, Tanner Roark sprinted to the bullpen. Because Vogelsong showed even a glimmer of struggle, Game 2 relief hero Yusmeiro Petit ran to the bullpen. Both managers had drawn a line — Williams by necessity, Bruce Bochy by choice.

Ramos walked to the plate 1 for 14 in the series, needing to push Harper to third base with one out. He hit a weak flare to shortstop, failing to advance Harper. Both bullpens whirred as Asdrubal Cabrera grounded to shortstop. Two outs.

Williams fired a bullet: pinch hitter Nate Schierholtz, the only lefty on his bench, walked to the plate. Gonzalez’s mostly excellent, briefly horrendous night had ended. Schierholtz took two pitches high to run the count to 3-2. He took a deep breath and called time. Posey trotted to the mound for a quick conference. Vogelsong threw the pitch they decided on, a curveball in the dirt, and Schierholtz took it for ball four.

Bochy stuck with Vogelsong, even as he tired and Petit pumped warmup pitches in foul territory. Denard Span had concentrated in Game 3 on being less anxious. On a 2-2 curve at his shins, he did exactly what he did not want to do — he hooked a pitch out of the zone to first base. Brandon Belt vacuumed the ball, stepped on first and ended the threat.

The bottom half of the inning only elevated the tension. Tanner Roark loaded the bases with one out before he got Sandoval to pop up. Williams turned to left-hander Jerry Blevins to face Belt. Blevins continued his monster series with a strikeout and a fist pump, stranding the bases loaded. For good measure, Blevins added a 1-2-3 sixth inning.

The Nats’ loss was seeded in the second inning. Brandon Crawford flared a single to left field. Juan Perez, the weakest hitter in either lineup, hit a masse shot off the end of his bat, a squib with wicked spin back up the middle. Gonzalez crouched to field the double play ball, but it ricocheted off his glove, squirted through his legs and trickled toward the right side of the infield.

“I thought the ball was hit harder than it was,” Gonzalez said. “Almost like a change-up coming at you. I saw it all the way to my glove and just picked it up right at the end.”

A potential double play had become a catalyst. Before Gonzalez could shake his error, the Nationals’ first of the series, the Nationals committed another calamity. Vogelsong pushed a sacrifice bunt down the third base line. Anthony Rendon charged forward.

Gonzalez scampered toward the ball and raised his hand, calling for it. Rendon backed off and yelled, “One, one, one!” But Gonzalez heard, “I got it! I got it!” The awkward dance ended with Rendon picking up the ball and grimacing while Vogelsong cruised across first base.

On two balls that traveled approximately 120 feet combined, the Nationals had turned a quiet inning into a train wreck. With the bases loaded and one out for the top of the Giants’ lineup, Gonzalez walked Gregor Blanco on four pitches. Blanco dropped his bat and clapped at the Giants’ dugout. Pitching coach Steve McCatty headed to the mound to chat with Gonzalez.

Panik grounded an 0-2 pitch to first, a roller too weak for LaRoche to turn a double play, and Perez raced home. While Roark warmed up in the bullpen, Posey grounded to third and Gonzalez escaped without further damage. But the inning had left a mark: The Giants sent seven batters to the plate. One hit the ball out of the infield. They turned a scoreless tie into a 2-0 lead.

The Nationals had made comebacks all season, and they would charge back again. In the end, their season unraveled with a rookie on the mound.

Afterward, Williams explained his reasoning in a small room. He walked out into a concourse flooded with Giants fans. Many of them remembered Williams the player, the third baseman who starred for them in the ’90s.

“We still love you,” one yelled.

“We love you, Matt Williams!” another hollered.

Williams pursed his lips and nodded. He turned left down a staircase and out to the field. Behind, the Giants popped champagne bottles in their clubhouse. Williams paced across the dimly lit expanse, into an offseason that had come too soon.