<commit_before><?php
namespace Grav\Common\Data;

use RocketTheme\Toolbox\ArrayTraits\Export;

/**
 * Blueprint handles the inside logic of blueprints.
 *
 * @author RocketTheme
 * @license MIT
 */
class Blueprint
{
    use Export;

    public $name;
    protected $items;
    protected $context;
    protected $fields;
    protected $rules = array();
    protected $nested = array();
    protected $filter = ['validation' => 1];

    /**
     * @param string $name
     * @param array  $data
     * @param Blueprints $context
     */
    public function __construct($name, array $data = array(), Blueprints $context = null)
    {
        $this->name = $name;
        $this->items = $data;
        $this->context = $context;
    }

    /**
     * Set filter for inherited properties.
     *
     * @param array $filter     List of field names to be inherited.
     */
    public function setFilter(array $filter)
    {
        $this->filter = array_flip($filter);
    }<commit_msg>Fix undefined variable in Data\Blueprint class<commit_after><?php
namespace Grav\Common\Data;

use RocketTheme\Toolbox\ArrayTraits\Export;

/**
 * Blueprint handles the inside logic of blueprints.
 *
 * @author RocketTheme
 * @license MIT
 */
class Blueprint
{
    use Export;

    public $name;

    public $initialized = false;

    protected $items;
    protected $context;
    protected $fields;
    protected $rules = array();
    protected $nested = array();
    protected $filter = ['validation' => 1];

    /**
     * @param string $name
     * @param array  $data
     * @param Blueprints $context
     */
    public function __construct($name, array $data = array(), Blueprints $context = null)
    {
        $this->name = $name;
        $this->items = $data;
        $this->context = $context;
    }

    /**
     * Set filter for inherited properties.
     *
     * @param array $filter     List of field names to be inherited.
     */
    public function setFilter(array $filter)
    {
        $this->filter = array_flip($filter);
    }
{'fraction_non_alphanumeric': 0.12315270935960591, 'fraction_numerical': 0.0009852216748768472, 'mean_word_length': 2.495697074010327, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 13, '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': '3301148', 'n_tokens_mistral': 597, 'n_tokens_neox': 582, 'n_words': 174}