The technical issue is that you need to double-escape the spaces in your script. The first backslash is interpreted by AppleScript to tell it to quote the next character and pass it to do shell script as-is. The trouble is that’s a space, and therefore it breaks.
To solve this you double-escape the space. The first slash tells AppleScript to escape the next character (the second slash) so that it’s passed through correctly, so;
do shell script "/path\ to/the\ script.sh"
Or, as kel suggests, quote the entire path:
do shell script (quoted form of "/path to/the script.sh")
which is always worth doing when passing filenames to ‘do shell script’.