<commit_before>package com.dlila.server.temperature;

import java.io.BufferedInputStream;
import java.io.IOException;
import java.nio.charset.StandardCharsets;

import com.dlila.server.common.FileServingHandler;
import com.dlila.server.common.ServerBuilder;
import com.sun.net.httpserver.HttpExchange;
import com.sun.net.httpserver.HttpHandler;

public class TemperatureService {

  public static ServerBuilder newBuilder() {
    // TODO(dlila): feels wrong to get the server's data from System.in. Maybe the temperature
    // parser should upload it through some API that is only exposed on the local machine.
    // (use grpc).

    // TODO(dlila): a better way of handling this type of thing (background services in non-request
    // threads) might be to use guava's service manager in the concurrency package (or maybe the
    // event manager).<commit_msg>Update TemperatureService.java<commit_after>package com.dlila.server.temperature;

import java.io.BufferedInputStream;
import java.io.IOException;
import java.nio.charset.StandardCharsets;

import com.dlila.server.common.FileServingHandler;
import com.dlila.server.common.ServerBuilder;
import com.sun.net.httpserver.HttpExchange;
import com.sun.net.httpserver.HttpHandler;

public class TemperatureService {
  
  private TemperatureService() {
    // static methods only. This class is similar to a guice module. I wonder how long I'll hold
    // out before guicifying/daggerifying this whole thing.
  }

  public static ServerBuilder newBuilder() {
    // TODO(dlila): feels wrong to get the server's data from System.in. Maybe the temperature
    // parser should upload it through some API that is only exposed on the local machine.
    // (use grpc).

    // TODO(dlila): a better way of handling this type of thing (background services in non-request
    // threads) might be to use guava's service manager in the concurrency package (or maybe the
    // event manager).
{'fraction_non_alphanumeric': 0.08247422680412371, 'fraction_numerical': 0.0, 'mean_word_length': 4.015503875968992, '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': '6611386', 'n_tokens_mistral': 537, 'n_tokens_neox': 513, 'n_words': 193}