A stream divides delivery into chunks, and those chunks don't necessarily match the records your application needs. One line can arrive in two pieces, or one piece can contain several lines. Buffering and framing turn that transport detail into a stable input for later transformations.
These local exercises cover text framing, lazy generator transforms, async iteration, and bounded batching. They teach the same separation of responsibilities used with Node streams without pretending that a browser worker has an operating-system stream handle. Keep record boundaries distinct from chunk boundaries, preserve input order, and handle the final partial record or batch. Empty chunks are valid deliveries. The generator and async-generator tasks also check that the exposed element type remains useful to callers.