<commit_before><?php include "conf.php"; /* load a local configuration */ ?>
<?php include "modulekit/loader.php"; /* loads all php-includes */ ?>
<?php call_hooks("init"); /* initialize submodules */ ?>

<?php
$explorer = new Explorer($base_path);

$ex_path = $explorer->get(array_key_exists('path', $_REQUEST) ? $_REQUEST['path'] : null);
$body = $ex_path->render();

Header("Content-Type: text/html; charset=utf-8");
?>
<!DOCTYPE HTML>
<html>
  <head>
    <title>Modulekit Explorer</title>
    <?php print modulekit_to_javascript(); /* pass modulekit configuration to JavaScript */ ?>
    <?php print modulekit_include_js(); /* prints all js-includes */ ?>
    <?php print modulekit_include_css(); /* prints all css-includes */ ?>
    <?php print_add_html_headers(); /* print additional html headers */ ?>
  </head>
  <body>
  <pre>
<? print $body; ?>
  </pre>
  </body>
</html>
<commit_msg>Index: if file not found, warn<commit_after><?php include "conf.php"; /* load a local configuration */ ?>
<?php include "modulekit/loader.php"; /* loads all php-includes */ ?>
<?php call_hooks("init"); /* initialize submodules */ ?>

<?php
$explorer = new Explorer($base_path);

$ex_path = $explorer->get(array_key_exists('path', $_REQUEST) ? $_REQUEST['path'] : null);
if($ex_path == null)
  $body = "File not found!";
else
  $body = $ex_path->render();

Header("Content-Type: text/html; charset=utf-8");
?>
<!DOCTYPE HTML>
<html>
  <head>
    <title>Modulekit Explorer</title>
    <?php print modulekit_to_javascript(); /* pass modulekit configuration to JavaScript */ ?>
    <?php print modulekit_include_js(); /* prints all js-includes */ ?>
    <?php print modulekit_include_css(); /* prints all css-includes */ ?>
    <?php print_add_html_headers(); /* print additional html headers */ ?>
  </head>
  <body>
  <pre>
<? print $body; ?>
  </pre>
  </body>
</html>

{'fraction_non_alphanumeric': 0.19172932330827067, 'fraction_numerical': 0.0010741138560687433, 'mean_word_length': 4.33810888252149, 'pattern_counts': {'":': 0, '<': 43, '<?xml version=': 0, '>': 47, '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': '587183', 'n_tokens_mistral': 603, 'n_tokens_neox': 592, 'n_words': 154}