let in_channel_to_item_stream ?zlib_buffer_size ?buffer_size inp =
let t1 = Transform.string_to_raw ?zlib_buffer_size () in
let t2 = Transform.raw_to_item () in
Biocaml_transform.(
in_channel_strings_to_stream ?buffer_size inp
(compose_results t1 t2 ~on_error:(function `left x -> x | `right x -> `bam x))
)