I was just going for a head-to-head comparison, that's the closest you can get in price/performance. The closest M4 Pro Mac Mini is already a lot more expensive than the baseline Framework Desktop.

The Framework Desktop Max+ 395 with 128 GB of RAM, and a 500 GB SSD costs around $2,147.00 USD before tax. The M4 Pro with the 20-core GPU, 64 GB of RAM, and a 512 GB SSD costs around $2,199.00 USD. That's still short 64 GB of RAM, of course.*

The lowest-end M4 Max Mac Studio that can support 128 GB of RAM seems to cost $3,499.00 with 128 GB of RAM and a 512 GB SSD. For that you get 546GB/s of maximum memory bandwidth according to Apple, which is definitely a step up from the 256GB/s maximum for the Ryzen AI Max+ 395, but obviously also at a price that is quite higher too.

Apparently though, 128 GB of RAM is currently the ceiling for the M4 Max right now. So it seems like if you were going for a maximum performance local AI cluster at any price, the M3 Ultra Mac Studios are definitely in the running, though at that point it probably is starting to get to the price where AMD and NVIDIA's data center GPUs start to enter the picture, and AMD Instinct cards measure memory bandwidth in terabytes per second.

* Regarding GPUs: The Framework Desktop Max+ 395 Radeon 8060S seems to be vastly faster than all of the non-Max M4 SKUs, for anyone that cares a lot about GPU performance. The M4 Max seems to outperform the 8060S by a bit though, and obviously it has some stand-out features like a shit load of video encoding/decoding hardware. This complicates the value comparison a lot. The Radeon core definitely gets a much better value for the performance in any case. I'm really impressed by what they managed to do there.