Partially implemented top-level Stream handling.