Generations: We currently have three generations of Apple Silicon available on Macs: M1 (the original), M2, and M3. Late this fall we'll get M4. Apple has been using the reduction of semiconductor process size to drive each new generation. In general, they've been balancing performance versus power usage.
Types: We have the base silicon (say M3, the baby bear). We also have expanded versions (larger semiconductors with more transistors) that comprise M3 Pro (Goldilocks) and M3 Max (daddy bear). With more territory you can fit in more RAM and more cores.
CPU Cores: The main ARM-based computation is done either by a Performance core (speed) or an Efficiency core (power conservation). Some tasks you need performed quickly should be done by a Performance core (macOS and apps parcel this out as needed). Otherwise, tasks on a laptop that don't need a lot of computation (e.g text editing) should be using Efficiency cores. The number of CPU cores Apple lists for a chip are split, often somewhere near half and half between types.
GPU Cores: Graphic Processing Units evolved as special purpose processors, typically ones that, duh, deal with graphics.
NPU Cores: Neural Processing Units evolved to handle specific needs of AI, ML, and other similar tasks. They aren't there to crunch numbers, they're there to do brain-like things with data (e.g. neural network).
The good news is that all of the Apple Silicon has a handful (or more) of each type of core. The more cores it has for a job, the faster it will process the job (assuming the software engineers were paying attention). For instance, video compression is usually—but not always, since Apple Silicon now also has dedicated compression cores!—handled by GPUs. The more of those you have the faster the compression is done.
All that said, much of the time your computer is basically just using a Performance CPU core for most of what you're doing. Moreover, even the simplest Apple Silicon chip has more than enough "power" to handle most things most users do. If you're going to do regressive analysis on a big data set, compress or decompress 8K video, or some other "big" task, well, then should be considering one of the higher end chips.
Along with cores of various sorts, Apple also puts all memory used by the computer on the same Apple Silicon chip, which is why you have to be careful about how much memory you buy on day one: you cannot increase it.
The reason Apple did this is performance (and efficiency). By having all memory on the single processing chip all those cores and other things built into the chip have direct and extraordinarily fast access to the memory.
That said, pretty much no matter how much memory you buy, you're going to eventually run a task that needs more. No worries. Apple has basically taken the approach my team did with a product called RAM Doubler: (1) free up memory blocks that aren't being used at all; (2) compress blocks that haven't been accessed in awhile; and (3) if you still need more "memory" the system swaps out to the SSD. All this is why I say buy memory before cores, make sure you buy plenty of SSD (typically at least 1TB).
So, if I want to future proof my purchase as much as possible,
This is the part where you'll find many of us Mac experts disagreeing. We're right now in a very fast iteration cycle that's producing strong gains each iteration. With Apple adding things like Apple Intelligence and who knows what next, there's a pretty strong feeling among some that trying to buy a 10-year futureproof machine these days is a bit of fools folly. Others think there's no real issue coming. My advice has been to not get too deep into cores, make sure you have a lot of memory, and don't skimp on an SSD. Those latter two things make a Mac more futureproof at the moment.
and want to be able to process 45 megapixel images and use all the AI features in Lightroom Classic without wanting to wait many minutes for the images to process, what computer features/specifications are critical that I should shop for?
That's a trickier question than you think, as Adobe tends to be pretty inefficient in initial offerings and it's only over time that they figure out how to make their features into more hot rods than sluggish rods. However, that said, on an M1Max 64GB MacBook 14" I've never felt like I'm waiting for Adobe. But even on my M1 16GB MacBook Air I don't really see any real issues with speed, as long as the images I'm working on are on the internal SSD (which is far faster than any external SSD at the moment).
For example, would a 14 inch M2 Pro, 12 core chip, 16GB RAM, 19 core GPU be fast enough?
I'd say yes. But make sure you're not skimping on the SSD.
Or should I opt for 24GB of RAM but scale back to a 8 core chip with 10 core GPU for about the same money?
For a photographer doing image processing: memory before cores.