<commit_before><?php

/** @var \Illuminate\Database\Eloquent\Factory $factory */
$factory->define(App\User::class, function (Faker\Generator $faker) {
    static $password;

    return [
        'name'           => $faker->name,
        'email'          => $faker->unique()->safeEmail,
        'password'       => $password ?: $password = <PASSWORD>('<PASSWORD>'),
        'remember_token' => str_random(10),
    ];
});

$factory->define(Larafolio\Models\Project::class, function (Faker\Generator $faker) {
    $name = $faker->unique()->string;

    $types = ['web', 'github', 'volunteer'];

    $index = rand(0, 2);

    return [
        'name'  => $name,
        'type'  => $types[$index],
        'slug'  => strtolower(snake_case($name)),
        'order' => rand(0, 10),
    ];
});

$factory->define(Larafolio\Models\Image::class, function (Faker\Generator $faker) {
    $project = factory(Larafolio\Models\Project::class)->create();

    return [
        'path'       => str_random(20).'.jpg',
        'name'       => $faker->word,
        'project_id' => $project->id(),
    ];
});

$factory->define(Larafolio\Models\TextBlock::class, function (Faker\Generator $faker) {
    $text = $faker->paragraph(5, true);

    return [<commit_msg>Change project factory name to simple random string.<commit_after><?php

/** @var \Illuminate\Database\Eloquent\Factory $factory */
$factory->define(App\User::class, function (Faker\Generator $faker) {
    static $password;

    return [
        'name'           => $faker->name,
        'email'          => $faker->unique()->safeEmail,
        'password'       => $password ?: $<PASSWORD>'),
        'remember_token' => str_random(10),
    ];
});

$factory->define(Larafolio\Models\Project::class, function (Faker\Generator $faker) {
    $name = str_random(30);

    $types = ['web', 'github', 'volunteer'];

    $index = rand(0, 2);

    return [
        'name'  => $name,
        'type'  => $types[$index],
        'slug'  => strtolower(snake_case($name)),
        'order' => rand(0, 10),
    ];
});

$factory->define(Larafolio\Models\Image::class, function (Faker\Generator $faker) {
    $project = factory(Larafolio\Models\Project::class)->create();

    return [
        'path'       => str_random(20).'.jpg',
        'name'       => $faker->word,
        'project_id' => $project->id(),
    ];
});

$factory->define(Larafolio\Models\TextBlock::class, function (Faker\Generator $faker) {
    $text = $faker->paragraph(5, true);

    return [
{'fraction_non_alphanumeric': 0.19734726688102894, 'fraction_numerical': 0.008842443729903537, 'mean_word_length': 2.835130970724191, 'pattern_counts': {'":': 0, '<': 8, '<?xml version=': 0, '>': 52, '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': '5900756', 'n_tokens_mistral': 855, 'n_tokens_neox': 827, 'n_words': 136}