bytestream improvements