<commit_before>
var express = require('express');
var compression = require('compression');
var bodyParser = require('body-parser');
var forceDomain = require('forcedomain');
var moment = require('moment');
var async = require('async');
var memCache = require('memory-cache');
var bunyan = require('bunyan');
var bunyanFormat = require('bunyan-format')({ outputMode: 'short' });
var coding = require('./lib/codingFileSystem');
var rssOptions = require('./lib/rssOptions');
var Rss = require('./lib/rss');
var RssBuilder = require('rss');
var ItemStore = require('./lib/itemStore');
var ZhuanlanStore = require('./lib/zhuanlanStore');
var RecommendItems = require('./lib/recommendItems');
var StatsStore = require('./lib/statsStore');

var log = bunyan.createLogger({name: 'zr', stream: bunyanFormat});

var dbDir = (process.env.OPENSHIFT_DATA_DIR || coding() || (__dirname + '/data'));
var itemStore = new ItemStore(dbDir + '/item', log.child({store:'item'}));
var zhuanlanStore = new ZhuanlanStore(dbDir + '/zhuanlan', log.child({store:'zhuanlan'}));
var statsStore = new StatsStore(dbDir + '/stats', itemStore, log.child({store:'stats'}));
var recommend = new RecommendItems(statsStore, itemStore, log.child({store:'recommend'}));

var memCacheTime = rssOptions.ttl * 60 * 1000;

var startTime = new Date().getTime();

var app = express();

app.set('port', (process.env.OPENSHIFT_NODEJS_PORT || process.env.PORT || 5000));<commit_msg>Edit bunyan format<commit_after>
var express = require('express');
var compression = require('compression');
var bodyParser = require('body-parser');
var forceDomain = require('forcedomain');
var moment = require('moment');
var async = require('async');
var memCache = require('memory-cache');
var bunyan = require('bunyan');
var bunyanFormat = require('bunyan-format')({ outputMode: 'simple', color: false });
var coding = require('./lib/codingFileSystem');
var rssOptions = require('./lib/rssOptions');
var Rss = require('./lib/rss');
var RssBuilder = require('rss');
var ItemStore = require('./lib/itemStore');
var ZhuanlanStore = require('./lib/zhuanlanStore');
var RecommendItems = require('./lib/recommendItems');
var StatsStore = require('./lib/statsStore');

var log = bunyan.createLogger({name: 'zr', stream: bunyanFormat});

var dbDir = (process.env.OPENSHIFT_DATA_DIR || coding() || (__dirname + '/data'));
var itemStore = new ItemStore(dbDir + '/item', log.child({store:'item'}));
var zhuanlanStore = new ZhuanlanStore(dbDir + '/zhuanlan', log.child({store:'zhuanlan'}));
var statsStore = new StatsStore(dbDir + '/stats', itemStore, log.child({store:'stats'}));
var recommend = new RecommendItems(statsStore, itemStore, log.child({store:'recommend'}));

var memCacheTime = rssOptions.ttl * 60 * 1000;

var startTime = new Date().getTime();

var app = express();

app.set('port', (process.env.OPENSHIFT_NODEJS_PORT || process.env.PORT || 5000));
{'fraction_non_alphanumeric': 0.1839557399723375, 'fraction_numerical': 0.006915629322268326, 'mean_word_length': 6.475452196382429, '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': '386665', 'n_tokens_mistral': 918, 'n_tokens_neox': 874, 'n_words': 217}