<commit_before>export interface Constraint {
    value: string|string[];
    type: string;   // add | subtract
}


/**
 * Companion object
 */
export class Constraint {

    public static convertTo(constraint: Constraint|string|string[]): Constraint {

        return (Array.isArray(constraint) || typeof(constraint) == 'string')
            ? { value: constraint, type: 'add' }
            : constraint;
    }
}<commit_msg>Extend Contraint with searchRecursively boolean<commit_after>export interface Constraint {

    value: string|string[];
    type: string;   // add | subtract
    searchRecursively?: boolean;
}


export class Constraint {

    public static convertTo(constraint: Constraint|string|string[]): Constraint {

        return (Array.isArray(constraint) || typeof(constraint) == 'string')
            ? { value: constraint, type: 'add', searchRecursively: false }
            : constraint;
    }
}
{'fraction_non_alphanumeric': 0.12144420131291028, 'fraction_numerical': 0.0, 'mean_word_length': 3.255813953488372, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '4303977', 'n_tokens_mistral': 252, 'n_tokens_neox': 244, 'n_words': 62}