<commit_before>/**
 * Created by mikus on 2016.11.7.
 */

package lv.mikust.tehbot;

import twitter4j.*;

import java.io.IOException;

public class TweetBot {
    private static final Logger logger = Logger.getLogger(TwitterStream.class);

    public static void main(String[] args) throws TwitterException {
        TwitterStream twitterStream = new TwitterStreamFactory().getInstance();
        twitterStream.addListener(listener);
        twitterStream.user();
        WebRequests webRequests = new WebRequests();
    }

    // Stream listener

    private static UserStreamListener listener = new UserStreamListener() {
        @Override
        public void onStatus(Status status) {
            logger.info("Message: " + status.getUser().getScreenName() + " - " + status.getText());
            // Responds with help message
            if (status.getText().toLowerCase().contains("!help")) {
                sendResponse(status, "Awailable commands\n!d <domain> - returns webserver version\n!w <city> - returns current weather.");

            } else if (status.getText().toLowerCase().contains("!d")) {
                ExtractUri extractUri = new ExtractUri();
                if (extractUri.splitText(status.getText()) != null) {
                    String domainName = extractUri.splitText(status.getText());
                    logger.info("Sending GET / request to " + domainName);
                    try {<commit_msg>Added my name to output, as required<commit_after>/**
 * Created by mikus on 2016.11.7.
 */

package lv.mikust.tehbot;

import twitter4j.*;

import java.io.IOException;

public class TweetBot {
    private static final Logger logger = Logger.getLogger(TwitterStream.class);

    public static void main(String[] args) throws TwitterException {
        logger.info("TweetBot created by Mikus (c11)");
        TwitterStream twitterStream = new TwitterStreamFactory().getInstance();
        twitterStream.addListener(listener);
        twitterStream.user();
        WebRequests webRequests = new WebRequests();
    }

    // Stream listener

    private static UserStreamListener listener = new UserStreamListener() {
        @Override
        public void onStatus(Status status) {
            logger.info("Message: " + status.getUser().getScreenName() + " - " + status.getText());
            // Responds with help message
            if (status.getText().toLowerCase().contains("!help")) {
                sendResponse(status, "Awailable commands\n!d <domain> - returns webserver version\n!w <city> - returns current weather.");

            } else if (status.getText().toLowerCase().contains("!d")) {
                ExtractUri extractUri = new ExtractUri();
                if (extractUri.splitText(status.getText()) != null) {
                    String domainName = extractUri.splitText(status.getText());
                    logger.info("Sending GET / request to " + domainName);
                    try {
{'fraction_non_alphanumeric': 0.11670636270840422, 'fraction_numerical': 0.006124532153793808, 'mean_word_length': 2.607361963190184, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, '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': '4219927', 'n_tokens_mistral': 768, 'n_tokens_neox': 735, 'n_words': 191}