LOS ANGELES — The decision, in the words of Giants manager Tony Vitello, took guts.

Last Friday, with two out in the bottom of the ninth, Jonah Cox stepped to the plate against San Diego Padres All-Star closer Mason Miller. Cox’s job, by any means necessary, was to reach base for Rafael Devers and keep the rally alive. With the count at 0-1, Miller fired a triple-digit fastball. And Cox, to the surprise of just about everyone in the ballpark, squared to bunt.

The bunt was perfect. Third baseman Manny Machado was playing way back, and with Cox’s elite speed, the Giants rookie outfielder was at first base by the time Machado picked up the ball. The Giants ultimately lost the game, but the play was a microcosm of the moments that are quickly making Cox a lock for next year’s Opening Day roster.

“Anybody that has the kind of toolset that he does is incredibly exciting to watch because you don’t know what the ceiling is going to be,” said hitting coach Hunter Mense. “You have no idea how high or how far he’s going to be able to take it. A lot of people get limited by what they can do based upon their physical capabilities or inabilities, but he has a lot of possessive traits that can take him to places that not a lot of guys can go to.”

Cox, 25, has been one of the few bright spots in such a dreary season. Despite playing just 53 games, Cox is tied with Drew Gilbert for the most WAR among Giants outfielders (1.4), per Baseball-Reference. Much of Cox’s value derives from the most lethal weapon in Cox’s toolset: his speed.

Cox ranks in the 99th percentile in sprint speed, per Baseball Savant. He’s one of just 10 qualified players in the majors with an average sprint speed of at least 30 feet per second, which is considered elite. As he’s proven so often, he’s not afraid to turn on the jets and push the envelope.

With a pair of steals in Wednesday’s 6-5 win, Cox has swiped 13 bags on 17 attempts. Despite appearing in just 53 games, Cox eclipsed Jung Hoo Lee (12) for the most steals on the team. It’s both a testament to Cox’s willingness to run, as well as the roster’s dearth of base stealers.

The Giants haven’t had a player with both elite speed and a willingness to run in quite some time. Tyler Fitzgerald had elite speed but wasn’t aggressive at stealing; Thairo Estrada had back-to-back 20-steal seasons in 2022 and 2023, but lacked top-end speed. With Cox, though, the Giants have a player with a souped-up engine and the willingness to floor it.

“The one thing we try to do as far as how do you accentuate a strength is make sure a guy understands what he can do to utilize those things, whether it’s an arm in the outfield, or things Jonah can do,” said manager Tony Vitello.

Steals are far from the only way that Cox uses his legs. In last Wednesday’s comeback win against the St. Louis Cardinals, Cox turned an inning-ending groundout into an RBI single that kept the rally going.

Or, take this bunt single by Cox on Tuesday night against the Cardinals, who are probably glad they don’t have to see Cox again this year. Cox raced from home to first in 3.63 seconds, the second-fastest time by a right-handed hitter this year. And when Cox has a full head of steam, he’s usually reaching base safely with time to spare.

Cox’s speed doesn’t just play on the bases. Entering Wednesday, Cox was worth +4 outs above average (a cumulative range-based stat). That’s tied with Gilbert for the most among Giants outfielders, but Gilbert has played nearly 600 more innings in the outfield. Combine Cox’s range as a center fielder with an ability to play a smooth second base, and it’s not hard to see his defensive upside.

The 25-year-old didn’t need much time to show off his plus speed and plus defense, but Cox didn’t exactly hit the ground running at the plate.

Called up directly from Double-A Richmond in late May, Cox didn’t draw a single walk and struck out more than half the time (51.7% K%) over his first 29 plate appearances. Cox sustained a left oblique strain in early July, then played a handful of games with Triple-A Sacramento before returning to the majors on Aug. 14. In his first six games back, Cox struck out 10 times over 17 plate appearances, which included a stretch of nine consecutive strikeouts.

Cox, in the midst of a glacier-cold slump, made some pretty significant changes to his setup. Here’s Cox on Aug. 21:

Now, here’s Cox on Aug. 23:

The changes are striking. Along with changing his hand placement, Cox went from having a big kick stride to effectively no stride at all.

Cox assessed that he could “get away with some bigger moves” in the minors against left-handed pitchers. In the majors, however, Cox struggled against hard-throwing lefties, going 7-for-32 with 18 strikeouts in his first 33 plate appearances versus lefties.

Before the team traveled to Boston, Cox and Mense talked about implementing a wider base with no stride. When Cox tried it out in the cage, Mense recalled him three straight line drives up the middle.

Cox introduced his refurbished mechanics on Aug. 23 and saw immediate results. In his first at-bat of the game, Cox turned on a four-seam fastball from the Red Sox’s Jake Bennett — a left-hander — and sent the heater over the Green Monster.

“He’s really good at what he does, and I trusted him,” Cox said. “I kind of messed around with it for a day or two. Then, I guess I got lucky and caught one over the plate. So, we’ve just been working daily, trying to refine it and kind of tweak it. Hopefully, we keep it going.”

To Mense, Cox’s willingness to make significant midseason adjustments is all the more impressive considering how Cox performed in the minors.

When the Giants called Cox up from Double-A, he was hitting .400/.453/.644 over 44 games. Including his brief stint with Sacramento, Cox has a .415 batting average in the minors this season. Despite that success, Cox initiated an opportunity to address a weakness.

Since making the change, Cox is hitting .329 with an .839 OPS. He’s finally drawn some walks (6) and has cut his strikeout rate to a more manageable 27.1 percent. And with Cox, more times on base equates to more opportunities to create chaos.

With nine games remaining, Cox will have a few more opportunities to continue solidifying a spot on next year’s roster. Cox and Gilbert have the makings of a fine center field platoon, and Cox’s elite speed and defensive versatility fit on any roster. And speed, of course, is the one tool that never slumps.

“He’s got so many tools in the tool bag that he’d be doing himself a disservice if he only pigeonholed himself into being able to do one thing,” Mense said. “He can just do so many things, and there are so many weapons he has in the toolbox.”