<commit_before>stream-utils
============
Stream utilities with support for stream resets.


exports
-------
 * through([write], [end], [reset]) - creates a new "through" Streams which readable and writable that acts based on the given write, end, and reset handler functions.
 * duplex(writable, readable) - combines a writable stream and a readable stream into a through Stream.
 * pipeline(stream1, stream2, ...) - creates a new Stream that sends data to all of the given Streams.


Examples
--------
Here's a simple and somewhat contrived example of how you might use the through stream helper to apply a math operation.
```javascript
var su = require("stream-utils");

var inputs = [1, 2, 3],
  outputs = [],
  doubler = su.through(function(val){ // on data queue doubled value
    this.queue(val * 2);
  })
    .on("data", function(val2){ // on data push into outputs
      outputs.push(val2);
    });

inputs.forEach(doubler.write);

// --> outputs is: [2, 4, 6]
```


Why?
----
I needed a set of Stream utilities that would make it easier to build and reuse chains of complex Object stream mutators.
Originally I used the `event-stream` package but I ran into a few issues with my use cases that drove me to roll my own solution based on what I had learned from that code.


License
-------
MIT / Apache2<commit_msg>Attempting to make NPM happy with the README again<commit_after>stream-utils
============
Stream utilities with support for stream resets.


exports
-------
 * through([write], [end], [reset]) - creates a new "through" Streams which readable and writable that acts based on the given write, end, and reset handler functions.
 * duplex(writable, readable) - combines a writable stream and a readable stream into a through Stream.
 * pipeline(stream1, stream2, ...) - creates a new Stream that sends data to all of the given Streams.


Examples
--------
Here's a simple and somewhat contrived example of how you might use the through stream helper to apply a math operation.

```javascript
var su = require("stream-utils");

var inputs = [1, 2, 3],
  outputs = [],
  doubler = su.through(function(val){ // on data queue doubled value
    this.queue(val * 2);
  })
    .on("data", function(val2){ // on data push into outputs
      outputs.push(val2);
    });

inputs.forEach(doubler.write);

// --> outputs is: [2, 4, 6]
```


Why?
----
I needed a set of Stream utilities that would make it easier to build and reuse chains of complex Object stream mutators.
Originally I used the `event-stream` package but I ran into a few issues with my use cases that drove me to roll my own solution based on what I had learned from that code.


License
-------
MIT / Apache2
{'fraction_non_alphanumeric': 0.11549925484351714, 'fraction_numerical': 0.00894187779433681, 'mean_word_length': 3.4453642384105962, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3240832', 'n_tokens_mistral': 764, 'n_tokens_neox': 712, 'n_words': 361}