<commit_before>package comm

import (
	"bufio"
	"bytes"
	"fmt"
	"net"
	"strconv"
	"strings"
	"time"
)

// Comm is some basic TCP communication
type Comm struct {
	connection net.Conn
	writer     *bufio.Writer
	reader     *bufio.Reader
}

// New returns a new comm
func New(n net.Conn) *Comm {
	c := new(Comm)
	c.connection = n
	c.connection.SetReadDeadline(time.Now().Add(3 * time.Hour))
	c.connection.SetDeadline(time.Now().Add(3 * time.Hour))
	c.connection.SetWriteDeadline(time.Now().Add(3 * time.Hour))
	c.writer = bufio.NewWriter(n)
	c.connection = bufio.NewReader(n)
	return c
}
<commit_msg>use netconn<commit_after>package comm

import (
	"bufio"
	"bytes"
	"fmt"
	"net"
	"strconv"
	"strings"
	"time"
)

// Comm is some basic TCP communication
type Comm struct {
	connection net.Conn
	writer     *bufio.Writer
	reader     *bufio.Reader
}

// New returns a new comm
func New(n net.Conn) *Comm {
	c := new(Comm)
	c.connection = n
	c.connection.SetReadDeadline(time.Now().Add(3 * time.Hour))
	c.connection.SetDeadline(time.Now().Add(3 * time.Hour))
	c.connection.SetWriteDeadline(time.Now().Add(3 * time.Hour))
	c.writer = bufio.NewWriter(n)
	// c.connection = bufio.NewReader(n)
	return c
}

{'fraction_non_alphanumeric': 0.1489539748953975, 'fraction_numerical': 0.00502092050209205, 'mean_word_length': 3.8032128514056227, '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': '717360', 'n_tokens_mistral': 472, 'n_tokens_neox': 471, 'n_words': 101}