<commit_before><?php

namespace Migraine\Type;

use Migraine\Config;
use Symfony\Component\OptionsResolver\OptionsResolver;
use Symfony\Component\OptionsResolver\OptionsResolverInterface;

abstract class Type implements TypeInterface
{
    /**
     * @var Config
     */
    protected $config;

    /**
     * @var array
     */
    protected $options;

    public function __construct(Config $config)
    {
        $this->config = $config;

        $resolver = new OptionsResolver();
        $this->setDefaultOptions($resolver);
        $this->options = $resolver->resolve($config->options);
    }

    protected function setDefaultOptions(OptionsResolverInterface $resolver)
    {
    }
}<commit_msg>Added init method for types<commit_after><?php

namespace Migraine\Type;

use Migraine\Config;
use Symfony\Component\OptionsResolver\OptionsResolver;
use Symfony\Component\OptionsResolver\OptionsResolverInterface;

abstract class Type implements TypeInterface
{
    /**
     * @var Config
     */
    protected $config;

    /**
     * @var array
     */
    protected $options;

    public function __construct(Config $config)
    {
        $this->config = $config;

        $resolver = new OptionsResolver();
        $this->setDefaultOptions($resolver);
        $this->options = $resolver->resolve($config->options);

        $this->init();
    }

    protected function init()
    {
    }

    protected function setDefaultOptions(OptionsResolverInterface $resolver)
    {
    }
}
{'fraction_non_alphanumeric': 0.11178451178451178, 'fraction_numerical': 0.0, 'mean_word_length': 3.016216216216216, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 14, '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': '3071371', 'n_tokens_mistral': 412, 'n_tokens_neox': 398, 'n_words': 84}