My recollection is that the destination of a lot of the freight service in the area is the Quincy Shipyard on the Fore River. Unfortunately, that means it needs to cross the paths of all three OCR branches if originating from the national rail network (and not traveling via Boston).
So you basically have to maintain at least one freight track along the Middleboro Line, plus at least a little bit on the Greenbush Line, far enough to enable the reverse move onto the branch line. Triple tracking the Middleboro doesn't seem impossible, but it's definitely not trivial, particularly in Brockton. Once upon a time,
maybe you could have maintained/rebuilt the connection between the Randolph Branch and Stoughton, and used that for freight...
...but much of that ROW is a ghost today:
There's some underlying tension in the idea of Red-eats-OCR too: rapid transit presumably should go where there is highest density and demand, but that would (I believe) be along the Middleboro Line which a) is the path to Cape Cod, and I don't think Red-to-Hyannis really makes sense, and b) sees relatively high ridership all the way to Middleboro, over 30 miles from downtown. BART does that, but arguably as the exception that proves the rule that rapid transit isn't well-suited to those distances.
I think the Cape Cod issue really is the most acute here, unfortunately. Red-to-Brockton seems like the strongest idea of the mix, but where do Hyannis trains go if the Red Line eats the ROW to Brockton? Even if you could triple-track, that still means lengthy single track segments for the Regional Rail line, which doesn't seem good.
The only idea I've managed to scrounge up is to route outer Middleboro trains over the long-abandoned East Bridgewater Branch to join up with the Kingston/Plymouth Line.
But... like the Randolph Branch south of Randolph, this ROW barely exists anymore either.
In all of these cases, the alternative being compared to is something like 7 miles max of double tracking in Boston and Quincy. The East Bridgewater Branch alone is something like 6 miles,
and you'd have all the costs of Red-to-Brockton. In terms of solving the bottleneck issue, I don't think the cost-benefit analysis works out well. (Now, if you wanted to come at this from the angle of extending the Red Line to Brockton
on its own merits, I think you'd have a stronger case, but it's still a tall order.)
Also worth noting that I count 22 crossings on the Greenbush Line, and 24 crossings on the Kingston Line (excluding Plymouth Branch which has several more over a short stretch). That's a bunch of grade crossings that need separation if the Red Line were to eat either of those. (The Middleboro Line, for its part, has much better grade separation through Brockton.) These would not be inexpensive conversions.