Implemented some of make_command_stream()