Refer to [here]. The contents of the ROM within the IBM 5154 make any colour changes.
As for 200-line mode (a.k.a. CGA, a.k.a. mode 1), IBM have published the RGBI-to-rgbRGB mapping done by the ROM.
That mapping is shown in a table on page 4 (PDF page 8 ) of IBM's technical document for the IBM 5154 (at [here]).
In the 'Brown' row of that table, the reduction of green to achieve brown results from 'Gg' being '01' (G=0,g=1).
It would be '10' for yellow.
Regarding EGA, and the 5154 in particular... is it possible to establish the actual relationship between the primary (MSB) and secondary (LSB) signals, in terms of levels? (Modulo any funny business with contrast controls.)
I've been assuming that 'G' is twice as bright as 'g', so that 'Gg' in turn is three times as bright. That's how the 6-bit RGB model is usually interpreted. But thinking about it, there's no reason to strictly mandate that exact relationship, and I couldn't find anything in IBM's documentation for the EGA and ECD to clarify this.
Sams Computerfacts for the 5154 VDU could probably help, since it clearly draws up the signal path through the Red/Green/Blue amps to the CRT board. But admittedly, I'm less than competent in interpreting these schematics.