<commit_before><?php
    if (!empty($required_taxonomies)) {
        foreach ($required_taxonomies as $k => $v) {
            foreach ($tags as $tag) {
                $temp_tag = explode(':', $tag['Tag']['name']);
                if (count($temp_tag) > 1) {
                    if ($temp_tag[0] == $v) {
                        unset($required_taxonomies[$k]);
                        break;
                    }
                }
            }
        }
        if (!empty($required_taxonomies)) {
            echo sprintf(
                'Missing taxonomies: <span class="red bold">%s</span><br />',
                implode(', ', $required_taxonomies)
            );
        }
    }
?>
<span style="display:inline-block;">
    <?php
        $full = $isAclTagger && $tagAccess;
        $tagData = "";
        foreach ($tags as $tag) {
            if (empty($tag['Tag'])) {
                $tag['Tag'] = $tag;
            }
            if (empty($tag['Tag']['colour'])) {
                $tag['Tag']['colour'] = '#0088cc';
            }
            $aStyle = 'display:inline-block; background-color:' . h($tag['Tag']['colour']) . ';color:' . $this->TextColour->getTextColour($tag['Tag']['colour']) . ';';
            $aClass = $full ? 'tagFirstHalf' : 'tag';
            $aText = h($tag['Tag']['name']);
            if (!empty($tag['Tag']['id'])) {
                $aSearchTagUrl = $baseurl . '/events/index/searchtag: ' . h($tag['Tag']['id']);
                $span1 = sprintf('<a href="%s" style="%s" class="%s">%s</a>', $aSearchTagUrl, $aStyle, $aClass, $aText);
            } else {
                $aSpan1 = sprintf('<span style="%s" class="%s">%s</span>', $aStyle, $aClass, $aText);
            }
            $span2 = '';
            if ($full) {<commit_msg>chg: [reusability] Further modifications - have an on-demand static mode for ajaxTags<commit_after><?php
    if (!empty($required_taxonomies)) {
        foreach ($required_taxonomies as $k => $v) {
            foreach ($tags as $tag) {
                $temp_tag = explode(':', $tag['Tag']['name']);
                if (count($temp_tag) > 1) {
                    if ($temp_tag[0] == $v) {
                        unset($required_taxonomies[$k]);
                        break;
                    }
                }
            }
        }
        if (!empty($required_taxonomies)) {
            echo sprintf(
                'Missing taxonomies: <span class="red bold">%s</span><br />',
                implode(', ', $required_taxonomies)
            );
        }
    }
?>
<span style="display:inline-block;">
    <?php
        $full = $isAclTagger && $tagAccess && empty($static_tags_only);
        $tagData = "";
        foreach ($tags as $tag) {
            if (empty($tag['Tag'])) {
                $tag['Tag'] = $tag;
            }
            if (empty($tag['Tag']['colour'])) {
                $tag['Tag']['colour'] = '#0088cc';
            }
            $aStyle = 'display:inline-block; background-color:' . h($tag['Tag']['colour']) . ';color:' . $this->TextColour->getTextColour($tag['Tag']['colour']) . ';';
            $aClass = $full ? 'tagFirstHalf' : 'tag';
            $aText = h($tag['Tag']['name']);
            if (!empty($tag['Tag']['id'])) {
                $aSearchTagUrl = $baseurl . '/events/index/searchtag: ' . h($tag['Tag']['id']);
                $span1 = sprintf('<a href="%s" style="%s" class="%s">%s</a>', $aSearchTagUrl, $aStyle, $aClass, $aText);
            } else {
                $aSpan1 = sprintf('<span style="%s" class="%s">%s</span>', $aStyle, $aClass, $aText);
            }
            $span2 = '';
            if ($full) {
{'fraction_non_alphanumeric': 0.20363236103467253, 'fraction_numerical': 0.0049532195927352776, 'mean_word_length': 1.6806784660766962, 'pattern_counts': {'":': 0, '<': 23, '<?xml version=': 0, '>': 29, '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': '4487059', 'n_tokens_mistral': 1132, 'n_tokens_neox': 1098, 'n_words': 193}