[Suggestion] Would it be possible to make a script that rewires to "Animation Layer" output track?

I am trying an auto-rigger script, and the rig is great and all, but it's custom attributes break as soon as I use animation layers. This happens because the wiring setup changes, due to the creation of animation layers. These problems are fixed if I manually re-wire all the parameters to their corresponding layer's output tracks. Unfortunately, there are dozens, possibly more than a hundred of these parameters, and even just tracking down the most necessary ones through the rig's "hidden nodes" is a huge amount of work.

Would it be difficult to create such a script? Might be useful for anyone that uses wire parameters, before deciding to use animation layers.