Started implementing new stream code