Refactored TextlabNLP.run_shell_cmd() to use IO.read_partial() to avoid deadlocks.