I had always understood that green engines were original and yellow were replacements. I know when I was a motor officer (XO) replacement engines would usually be rebuilds, not new.
However... sometimes when unit level maintenance determined that an engine needed replacement, it was sent to direct support maintenance and no replacement engine was available. In that case a NEW engine was ordered to replace the worn out engine. The new one was off the factory line sitting in a warehouse waiting to fill the gap when no rebuilds were available. We always liked when new engines showed up as some of the rebuilds wouldnt last as long.
Back to the topic. My understanding was that the yellow engines were factory replacements to be used when rebuilds weren't available. In the past, Army rebuilds were not factory rebuilds, but depot level rebuilds of engines that were already in the Army supply system. Some items may get rebuilt at the factory, but most systems get rebuilt at an Army depot. As we have often witnessed in the MV hobby, and more often in the Army, depot level rebuilds sometimes are not quite to standard, and rarely are returned to the line like factory new.
So, when a replacement engine was ordered, a rebuilt engine would be sent to replace the broken engine. In return, the broken engine would be sent to a depot to be rebuilt and returned to stock to await the call from a unit for a new engine. There are new engines in stock to fill the gap when the demand for replacement engines exceeds the supply of rebuilt units, hence the need for factory new sitting on the shelves. Sometimes, new contracts are written for factory new engines to re-fill the supply lines when old broken engines aren't recovered for re-build like they're suppose to be.
I have no idea if this is why some are yellow and some are green, but this type of supply arrangement is common within the Army and that's the explanation I've understood as the reason behind the different colored A3 Cat engines.