Did you or functionals already consider, and exclude, the MM Customizing options in Valuation and Account Assignment/Account Determination (some "Account Modification" key)
You could try some implicit enhancement at end of MR_ACCOUNT_ASSIGNMENT, the FM which identify account number from Customizing.
There is also a risk with FI/CO substitution, did you consider also CO document like commitment or inconsistencies between MSEG and BSEG, or inconsistencies if GR executed before or after IR?
Regards,
Raymond