<commit_before><?php

namespace Berti;

use Symfony\Component\Console\Output\ConsoleOutputInterface;
use Symfony\Component\Console\Output\OutputInterface;
use Symfony\Component\Process\PhpExecutableFinder;
use Symfony\Component\Process\Process;
use Symfony\Component\Process\ProcessBuilder;

function server(
    OutputInterface $output,
    array $env = [],
    string $address = '127.0.0.1:8000'
): int
{
    $router = realpath(__DIR__ . '/../scripts/router.php');

    $finder = new PhpExecutableFinder();
<commit_msg>Use more robust path logic<commit_after><?php

namespace Berti;

use Symfony\Component\Console\Output\ConsoleOutputInterface;
use Symfony\Component\Console\Output\OutputInterface;
use Symfony\Component\Process\PhpExecutableFinder;
use Symfony\Component\Process\Process;
use Symfony\Component\Process\ProcessBuilder;

function server(
    OutputInterface $output,
    array $env = [],
    string $address = '127.0.0.1:8000'
): int
{
    $router = realpath(dirname(__DIR__) . '/scripts/router.php');

    $finder = new PhpExecutableFinder();

{'fraction_non_alphanumeric': 0.1234684260131951, 'fraction_numerical': 0.01885014137606032, 'mean_word_length': 4.966292134831461, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 2, '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': '5166573', 'n_tokens_mistral': 330, 'n_tokens_neox': 323, 'n_words': 62}