<commit_before>var toString = require('../lang/toString')
var lowerCase = require('./case-lower')
var upperCase = require('./case-upper')

// UPPERCASE first cha of each sentence and lowercase other chars

function sentenceCase (str) {
  str = toString(str)

  // replace first char of each sentence (new line or after '.\s+') to
  // UPPERCASE
  return lowerCase(str).replace(/(^\w)|\.\s+(\w)/gm, upperCase)
}

module.exports = sentenceCase<commit_msg>update string/case-paragraph adjust dependencies<commit_after>var stringify = require('./stringify')
var lowerCase = require('./case-lower')
var upperCase = require('./case-upper')

// replace first char of each sentence (new line or after '.\s+') to
// UPPERCASE and lowercase other chars

function sentenceCase (str) {
  return lowerCase(stringify(str)).replace(/(^\w)|\.\s+(\w)/gm, upperCase)
}

module.exports = sentenceCase
{'fraction_non_alphanumeric': 0.15550510783200908, 'fraction_numerical': 0.0, 'mean_word_length': 4.345454545454546, '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': '639031', 'n_tokens_mistral': 263, 'n_tokens_neox': 260, 'n_words': 78}