By Framingham, the 'extra' was operating just ahead of P508 - confusing passengers waiting for P508 when it didn't stop. It then passed P506 near West Newton. Good job Keolis fitting this extra inbound move without delaying the normal schedule!
This also could explain why B725 went through Framingham early. B725 is a CSX freight train from Attleboro to Framingham - passes through Medfield and Sherborn before crossing Route 135 in Framingham near the old Chicken Bone restaurant. From there, after joining the mainline Framingham Worcester tracks, it just goes west over Route 126 and into the freight yard between Winter Street and Fountain Street in Framingham ("Nevins Yard"). [The freight cars then eventually go west to Selkirk NY (near Albany) on a different manifest train (Q437) with different engines, but now I'm just getting carried away.]
Usually, B725 is held south of Blandin Avenue (so it doesn't block that crossing) until after P506 departs Framingham. Then the dispatcher gives it clearance and it moves up and across both Route 135 and the mainline track 2 - and travels west on track 1 through Framingham station. This timing allows it to move through without affecting commuter rail trains - it is in Framingham between P506 and P508 and clears off of track 1 before outbound P505 arrives in Framingham at 7:44 AM.
But on Friday 5/29, B725 made its move through Framingham AHEAD of P506, which I thought was odd. But in the context of the 'extra' story, it makes sense - they needed to get B725 out of the way so they could use the 'gap' time between P506 and P508 to move the 'extra' through Framingham inbound. It's fun to reverse engineer the dispatch decisions!