<commit_before><?php
use \Httpful\Request;

class GtaaSearch {
    public static function lookupCombined($id) {
        $item = ORM::for_table('combined')->where('gtaa', $id)->limit(10)->find_array();
        return count($item) === 0 ? false : (object) $item[0];
    }

    public static function search($q) {
        $q = strtolower($q);
        return ORM::for_table('combined')->where_like('lookup', "%$q%")->limit(10)->find_array();
    }

    public static function getRecentItems() {
        return ORM::for_table('combined')->order_by_desc('id')->limit(10)->find_array();
    }
}<commit_msg>Only show recent items that are 'included'<commit_after><?php
use \Httpful\Request;

class GtaaSearch {
    public static function lookupCombined($id) {
        $item = ORM::for_table('combined')->where('gtaa', $id)->limit(10)->find_array();
        return count($item) === 0 ? false : (object) $item[0];
    }

    public static function search($q) {
        $q = strtolower($q);
        return ORM::for_table('combined')->where_like('lookup', "%$q%")->limit(10)->find_array();
    }

    public static function getRecentItems() {
        return ORM::for_table('combined')->where('included', 1)->order_by_desc('id')->limit(10)->find_array();
    }
}
{'fraction_non_alphanumeric': 0.1945556445156125, 'fraction_numerical': 0.013610888710968775, 'mean_word_length': 3.9019607843137254, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 22, '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': '1436992', 'n_tokens_mistral': 418, 'n_tokens_neox': 401, 'n_words': 73}