<commit_before>#include <x0/source.hpp>
#include <x0/fd_source.hpp>
#include <x0/file_source.hpp>

#include <x0/sink.hpp>
#include <x0/file_sink.hpp>

#include <x0/filter.hpp>
#include <x0/null_filter.hpp>
#include <x0/uppercase_filter.hpp>
#include <x0/compress_filter.hpp>
#include <x0/chain_filter.hpp>

#include <x0/pump.hpp>

#include <iostream>
#include <memory>

#include <getopt.h>

inline x0::file_ptr getfile(const std::string ifname)
{
	return x0::file_ptr(new x0::file(
		x0::fileinfo_ptr(new x0::fileinfo(ifname))));
}

int main(int argc, char *argv[])
{
	struct option options[] = {
		{ "input", required_argument, 0, 'i' },
		{ "output", required_argument, 0, 'o' },
		{ "gzip", no_argument, 0, 'c' },
		{ "uppercase", no_argument, 0, 'U' },
		{ "help", no_argument, 0, 'h' },
		{ 0, 0, 0, 0 }
	};<commit_msg>adapted to changes in x0 api<commit_after>#include <x0/io/source.hpp>
#include <x0/io/fd_source.hpp>
#include <x0/io/file_source.hpp>

#include <x0/io/sink.hpp>
#include <x0/io/file_sink.hpp>

#include <x0/io/filter.hpp>
#include <x0/io/null_filter.hpp>
#include <x0/io/uppercase_filter.hpp>
#include <x0/io/compress_filter.hpp>
#include <x0/io/chain_filter.hpp>

#include <x0/io/pump.hpp>

#include <iostream>
#include <memory>

#include <getopt.h>

inline x0::file_ptr getfile(const std::string ifname)
{
	return x0::file_ptr(new x0::file(
		x0::fileinfo_ptr(new x0::fileinfo(ifname))));
}

int main(int argc, char *argv[])
{
	struct option options[] = {
		{ "input", required_argument, 0, 'i' },
		{ "output", required_argument, 0, 'o' },
		{ "gzip", no_argument, 0, 'c' },
		{ "uppercase", no_argument, 0, 'U' },
		{ "help", no_argument, 0, 'h' },
		{ 0, 0, 0, 0 }
	};
{'fraction_non_alphanumeric': 0.1963443396226415, 'fraction_numerical': 0.030070754716981132, 'mean_word_length': 4.954385964912281, 'pattern_counts': {'":': 0, '<': 31, '<?xml version=': 0, '>': 31, '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': '5958622', 'n_tokens_mistral': 765, 'n_tokens_neox': 731, 'n_words': 145}