The -ScriptText parameter for Invoke-VMScript currently only allows a string of 2869 or fewer characters. Anything longer than that is rejected and ScriptOutput returns an empty string. Allowing more characters will allow for more complex scripts to be run inside the VM Guest. Currently, anything longer than that has to be broken up into multiple calls to Invoke-VMScript, and as we all know, those calls are expensive in terms of script runtime, so the fewer the better.