<commit_before>// Logging using winston

'use strict';

const fs            = require('fs');
const path          = require('path');
const moment        = require('moment');
const stackTrace    = require('stack-trace');
const winston       = require('winston');
const winstonRotate = require('winston-daily-rotate-file');
// winston.emitErrs = true;



const lineFromStackTrace = function(stackLevel) {
  const sourceFileName    = path.basename(stackLevel.getFileName() || '');
  const sourceLineNumber  = stackLevel.getLineNumber();
//    const sourceFunction    = stackLevel.getFunctionName();

  const prefixText = `${sourceFileName}:${sourceLineNumber} `;<commit_msg>fix logging<commit_after>// Logging using winston

'use strict';

const fs            = require('fs');
const path          = require('path');
const moment        = require('moment');
const stackTrace    = require('stack-trace');
const winston       = require('winston');
const winstonRotate = require('winston-daily-rotate-file');
// winston.emitErrs = true;



const lineFromStackTrace = function(stackLevel) {
  let sourceFileName;
  let sourceLineNumber;
//  let sourceFunction;

  if(stackLevel && stackLevel.getFileName) {
    sourceFileName    = path.basename(stackLevel.getFileName() || '');
    sourceLineNumber  = stackLevel.getLineNumber();
//    sourceFunction    = stackLevel.getFunctionName();
  }

  const prefixText = `${sourceFileName}:${sourceLineNumber} `;
{'fraction_non_alphanumeric': 0.13573407202216067, 'fraction_numerical': 0.0, 'mean_word_length': 3.9827586206896552, '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': '4365473', 'n_tokens_mistral': 411, 'n_tokens_neox': 398, 'n_words': 88}