Is the computer AI (insane AI or custom AI) in any way affected by their enemy's actions? Such as, when their attack forces get killed really easily (because the enemy is really strong) they might speed up the attacks, or send forces via another route?
None.
I havn't looked too far into AI scripts, but as far as I know, they follow specific routines such as build this and build so many of those and then attack and what not. I'm relatively sure they wont try a different route because there arn't any scripts for specific locations and what not. I don't know that they'd really shorten the times in between attacks because you killed all their guys, but it would prompt them to build up again. I'm not sure about the custom script, but insane is told to build x amount of y unit before they attack, so no matter what it would depend on how long it took them to reach the specified x amount of that unit. But like I said, I'm no expert in this, so someone please correct me if I'm wrong.
None.
We can't explain the universe, just describe it; and we don't know whether our theories are true, we just know they're not wrong. >Harald Lesch
It really depends on the scripts. The campaign ais are tightly scripted that doesn't give much room for variation.
But what all AIs do is check who is the weakest player and attack him. Then they check if he has an expansion and attack that one. The AIs also consider the best path of approach. Especially when using drops they WILL find and use the gap in your defense.
Also IIRC the melee AI adapts to what units you build and when. If you have nothing they might rush you.