<commit_before>#!/usr/bin/env node

'use strict';

var program = require('commander');
var request = require('request');
var URL = require('url');
var languages = require('./languages');

var defaultSource = process.env.JA_GTC_SOURCE
var defaultTarget = process.env.JA_GTC_TARGET
if (defaultSource === undefined) defaultSource = 'en'
if (defaultTarget === undefined) defaultTarget = 'es'
if (defaultSource === defaultTarget) {
	console.log('Error, environment variables "JA_GTC_SOURCE" and "JA_GTC_TARGET" are set to the same value.')
	console.log('Proceeding using default values.')
	defaultSource = 'en'
	defaultTarget = 'es'
}

/* Supported languages: https://cloud.google.com/translate/v2/translate-reference#supported_languages */

/* This function creates the URL to get the translation from Google's server
(source: https://ctrlq.org/code/19909-google-translate-api) */
function createTranslatorURL(sourceLang, targetLang, sourceText) {
  return URL.format({<commit_msg>Remove problematic error message<commit_after>#!/usr/bin/env node

'use strict';

var program = require('commander');
var request = require('request');
var URL = require('url');
var languages = require('./languages');

var defaultSource = process.env.JA_GTC_SOURCE
var defaultTarget = process.env.JA_GTC_TARGET
if (defaultSource === undefined) defaultSource = 'en'
if (defaultTarget === undefined) defaultTarget = 'es'

/* Supported languages: https://cloud.google.com/translate/v2/translate-reference#supported_languages */

/* This function creates the URL to get the translation from Google's server
(source: https://ctrlq.org/code/19909-google-translate-api) */
function createTranslatorURL(sourceLang, targetLang, sourceText) {
  return URL.format({
{'fraction_non_alphanumeric': 0.1317157712305026, 'fraction_numerical': 0.006932409012131715, 'mean_word_length': 5.873015873015873, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, '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': '3344224', 'n_tokens_mistral': 516, 'n_tokens_neox': 491, 'n_words': 135}