<commit_before>var EventEmitter = require('events').EventEmitter;
var inherits = require('util').inherits;

var WriteEmitter = require('./write_emitter');
var ReadEmitter = require('./read_emitter');

module.exports =
function createDuplexEmitter(stream) {
  return new DuplexEmitter(stream);
};

function DuplexEmitter(stream) {
  EventEmitter.call(this);

  this.read = this.readEmitter = ReadEmitter(stream);
  this.write = this.writeEmtter = WriteEmitter(stream);

  this.write.on('error', onError.bind(this));
}

inherits(DuplexEmitter, EventEmitter);


/// addListener and on

DuplexEmitter.prototype.addListener =
DuplexEmitter.prototype.on =
function addListener(event, listener) {
  return this.read.on(event, listener);<commit_msg>fix typo<commit_after>var EventEmitter = require('events').EventEmitter;
var inherits = require('util').inherits;

var WriteEmitter = require('./write_emitter');
var ReadEmitter = require('./read_emitter');

module.exports =
function createDuplexEmitter(stream) {
  return new DuplexEmitter(stream);
};

function DuplexEmitter(stream) {
  EventEmitter.call(this);

  this.read = this.readEmitter = ReadEmitter(stream);
  this.write = this.writeEmitter = WriteEmitter(stream);

  this.write.on('error', onError.bind(this));
}

inherits(DuplexEmitter, EventEmitter);


/// addListener and on

DuplexEmitter.prototype.addListener =
DuplexEmitter.prototype.on =
function addListener(event, listener) {
  return this.read.on(event, listener);
{'fraction_non_alphanumeric': 0.13396481732070364, 'fraction_numerical': 0.0, 'mean_word_length': 6.110576923076923, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '6280304', 'n_tokens_mistral': 455, 'n_tokens_neox': 471, 'n_words': 84}