<commit_before>// Copyright 2014 <NAME>. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

// Package tcp implements TCP-level socket options.
//
// The package provides TCP-level socket options that allow
// manipulation of TCP connection facilities.
//
//
// Monitoring a TCP connection
//
// For now only Linux and FreeBSD kernels support the TCP information
// option. A custom net.Dial function that hooks up an underlying
// transport connection must be prepared before monitoring.
//
//	func dialWithTCPConnMonitor(network, address string) (net.Conn, error) {
//		d := net.Dialer{}
//		c, err := d.Dial(network, address)
//		if err != nil {
//			return nil, err
//		}
//		tc, err := tcp.NewConn(c)
//		if err != nil {
//			c.Close()
//			return nil, err
//		}
//		go tcpConnMonitor(tc) // launch a TCP connection monitor goroutine
//		return &tc.TCPConn, nil
//	}
//
// Also an application needs to construct a custom client such as a
// HTTP client containing a custom net.Dial function and get into a
// HTTP over TLS over TCP conversation.
//
//	tr := &http.Transport{
//		Dial:            dialWithTCPConnMonitor,<commit_msg>tcp: fix typo<commit_after>// Copyright 2014 <NAME>. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

// Package tcp implements TCP-level socket options.
//
// The package provides TCP-level socket options that allow
// manipulation of TCP connection facilities.
//
//
// Monitoring a TCP connection
//
// For now only Linux and FreeBSD kernels support the TCP information
// option. A custom net.Dial function that hooks up an underlying
// transport connection must be prepared before monitoring.
//
//	func dialWithTCPConnMonitor(network, address string) (net.Conn, error) {
//		d := net.Dialer{}
//		c, err := d.Dial(network, address)
//		if err != nil {
//			return nil, err
//		}
//		tc, err := tcp.NewConn(c)
//		if err != nil {
//			c.Close()
//			return nil, err
//		}
//		go tcpConnMonitor(tc) // launch a TCP connection monitor goroutine
//		return &tc.TCPConn, nil
//	}
//
// Also an application needs to construct a custom client such as an
// HTTP client containing a custom net.Dial function and get into an
// HTTP over TLS over TCP conversation.
//
//	tr := &http.Transport{
//		Dial:            dialWithTCPConnMonitor,
{'fraction_non_alphanumeric': 0.11922442244224422, 'fraction_numerical': 0.0033003300330033004, 'mean_word_length': 2.7949921752738653, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, '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': '5113192', 'n_tokens_mistral': 739, 'n_tokens_neox': 712, 'n_words': 299}