There's two ideas for growth/advancement in games, but, they're not mutually exclusive (ie, you can do both). You can grow more powerful/specialized (vertical), or you can grow more versatile/adaptable (horizontal). Once you hit Vice Admiral/Liet General, you sort of freeze in place (no more levels), but can still advance either way you want.
With STO, it seems like the Vertical advancement comes primarily through actual equipment: Mk XI, XII stuff, higher rarities, etc. Horizontal advancement comes through having a wider selection of ships, BOFFs, etc. And, certainly, I think your spec/build can reflect one, the other, or both.
So, which way do YOU prefer?
Personally, I've been preferring to advance Horizontally. I've been getting ships, getting them set up to my preferred playstyle, etc. I've got Bridge Officers suitable for the different types (Cruiser, Escort, Science) and how I want to play them, almost like a golf-bag full of clubs. I love being able to ask for a minute, change ships, and fill in whatever holes my friends might have in a team.
It depends really. I'd really have to say both. I've been playing Skyrim a lot recently, and while most end up very well rounded, I've been attempting a "No magic" run through. It... has not gone well.... But it has been a lot of fun.
But due to STO discouraging alting, it's not very easy to experiment.