<commit_before>/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package com.kurniakue.telebot;

import com.kurniakue.common.Common;
import com.kurniakue.common.Tool;
import com.kurniakue.data.DbProp;
import com.kurniakue.data.KurniaKueDb;
import com.kurniakue.data.TheConfig;
//import static com.kurniakue.telebot.UpdateHandler.getHandler;
//import static com.kurniakue.telebot.UpdateHandler.getRegisteredHandler;
import com.pengrad.telegrambot.TelegramBot;
import com.pengrad.telegrambot.TelegramBotAdapter;
import com.pengrad.telegrambot.model.Update;
import com.pengrad.telegrambot.response.GetUpdatesResponse;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.List;
import java.util.concurrent.atomic.AtomicBoolean;
//import java.util.Map;
import java.util.concurrent.BlockingQueue;
import java.util.concurrent.LinkedBlockingQueue;
import java.util.concurrent.TimeUnit;
import com.kurniakue.data.DbProp.N;
import java.util.Date;

/**
 *
 * @author harun1
 */
@SuppressWarnings("CallToPrintStackTrace")
public class Main {

    private static final AtomicBoolean started = new AtomicBoolean(false);

    private static TelegramBot bot;
    private static TheConfig config;

    public static void main(String[] args) throws Exception {
        started.set(true);
        config = KurniaKueDb.getConfig();<commit_msg>Service<commit_after>/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package com.kurniakue.telebot;

import com.kurniakue.common.Tool;
import com.kurniakue.data.DbProp;
import com.kurniakue.data.KurniaKueDb;
import com.kurniakue.data.TheConfig;
//import static com.kurniakue.telebot.UpdateHandler.getHandler;
//import static com.kurniakue.telebot.UpdateHandler.getRegisteredHandler;
import com.pengrad.telegrambot.TelegramBot;
import com.pengrad.telegrambot.TelegramBotAdapter;
import com.pengrad.telegrambot.model.Update;
import com.pengrad.telegrambot.response.GetUpdatesResponse;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.List;
import java.util.concurrent.atomic.AtomicBoolean;
//import java.util.Map;
import java.util.concurrent.BlockingQueue;
import java.util.concurrent.LinkedBlockingQueue;
import java.util.concurrent.TimeUnit;
import com.kurniakue.data.DbProp.N;
import java.util.Date;

/**
 *
 * @author harun1
 */
@SuppressWarnings("CallToPrintStackTrace")
public class Main {

    private static final AtomicBoolean started = new AtomicBoolean(false);

    private static TelegramBot bot;
    private static TheConfig config;
    
    public static void start(String[] args) throws Exception {
        started.set(true);
        config = KurniaKueDb.getConfig();
        if (args.length == 0) {
            args = new String[]{"c:/harun/cfg/telebot.conf"};
        }
        String configPath = args[0];
        System.out.println("Config path: " + configPath);
        config.load(configPath);
        startBotting();
    }
    
    public static void stop(String[] args) throws Exception {
        started.set(false);        
        disconnectDb();
    }

    public static void main(String[] args) throws Exception {
        started.set(true);
        config = KurniaKueDb.getConfig();
{'fraction_non_alphanumeric': 0.10103926096997691, 'fraction_numerical': 0.0011547344110854503, 'mean_word_length': 4.26595744680851, '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': '4436844', 'n_tokens_mistral': 1072, 'n_tokens_neox': 1062, 'n_words': 238}