<commit_before>package com.github.jhanne82.documenttree.simulation.configuration;

import com.github.jhanne82.documenttree.simulation.configuration.enumeration.Distribution;
import com.github.jhanne82.documenttree.simulation.configuration.enumeration.SearchType;



public class Parameter {


    private static final int MAX_COUNT_OF_CREATED_DOCUMENTS             = 1000;
    private static final int MAX_COUNT_OF_CREATED_SEARCHES              = 1000000;
    private static final int MAX_COUNT_OF_TERMS_USED_TO_DEFINE_VECTOR   = 1000;
    private static final int MAX_COUNT_OF_TERMS_WITH_QUANTIFIER         = 3;
    private static final int LIMIT_FOR_LOCAL_KNOWLEDGE                  = 300;
    private static final int NUMBER_OF_SEARCHES_BEFORE_REPOSITIONING    = 20;
    private static final int THRESHOLD                                  = 100;



    private SearchType   searchType;
    private Distribution distributionForDocument;
    private Distribution distributionForSearch;
    private boolean      cluster;



    public Parameter( SearchType   searchType,
                      Distribution distributionForDocument,
                      Distribution distributionForSearch,
                      boolean      cluster  ) {

        this.searchType = searchType;
        this.distributionForDocument = distributionForDocument;
        this.distributionForSearch = distributionForSearch;
        this.cluster = cluster;
    }



    public int getMaxCountOfCreatedDocuments() {
        return MAX_COUNT_OF_CREATED_DOCUMENTS;
    }



    public int getMaxCountOfCreatedSearches() {
        return MAX_COUNT_OF_CREATED_SEARCHES;
    }



    public int getMaxCountOfTermsUsedToDefineVector() {
        return MAX_COUNT_OF_TERMS_USED_TO_DEFINE_VECTOR;
    }



    public int getMaxCountOfTermsWithQuantifier() {
        return MAX_COUNT_OF_TERMS_WITH_QUANTIFIER;
    }



    public int getLimitForLocalKnowledge() {
        return LIMIT_FOR_LOCAL_KNOWLEDGE;
    }



    public int getNumberOfSearchesBeforeRepositioning() {
        return NUMBER_OF_SEARCHES_BEFORE_REPOSITIONING;
    }



    public int getTHRESHOLD() {
        return THRESHOLD;
    }



    public SearchType getSearchType() {
        return searchType;
    }



    public Distribution getDistributionForDocument() {
        return distributionForDocument;
    }



    public Distribution getDistributionForSearch() {
        return distributionForSearch;
    }



    public boolean isCluster() {
        return cluster;
    }



    @Override
    public String toString() {

        StringBuffer buffer = new StringBuffer();

        buffer.append( String.format( "Search Type: %20s%n", searchType ) );
        buffer.append( String.format( "Search Distr.: %14s%n", distributionForSearch ) );
        buffer.append( String.format( "Document Distr.: %12s%n", distributionForDocument ) );
        buffer.append( String.format( "Cluster: %18s%n", cluster ) );

        return buffer.toString();
    }
}<commit_msg>- relace StringBuilder by String<commit_after>package com.github.jhanne82.documenttree.simulation.configuration;

import com.github.jhanne82.documenttree.simulation.configuration.enumeration.Distribution;
import com.github.jhanne82.documenttree.simulation.configuration.enumeration.SearchType;



public class Parameter {


    private static final int MAX_COUNT_OF_CREATED_DOCUMENTS             = 1000;
    private static final int MAX_COUNT_OF_CREATED_SEARCHES              = 1000000;
    private static final int MAX_COUNT_OF_TERMS_USED_TO_DEFINE_VECTOR   = 1000;
    private static final int MAX_COUNT_OF_TERMS_WITH_QUANTIFIER         = 3;
    private static final int LIMIT_FOR_LOCAL_KNOWLEDGE                  = 300;
    private static final int NUMBER_OF_SEARCHES_BEFORE_REPOSITIONING    = 20;
    private static final int THRESHOLD                                  = 100;



    private SearchType   searchType;
    private Distribution distributionForDocument;
    private Distribution distributionForSearch;
    private boolean      cluster;



    public Parameter( SearchType   searchType,
                      Distribution distributionForDocument,
                      Distribution distributionForSearch,
                      boolean      cluster  ) {

        this.searchType = searchType;
        this.distributionForDocument = distributionForDocument;
        this.distributionForSearch = distributionForSearch;
        this.cluster = cluster;
    }



    public int getMaxCountOfCreatedDocuments() {
        return MAX_COUNT_OF_CREATED_DOCUMENTS;
    }



    public int getMaxCountOfCreatedSearches() {
        return MAX_COUNT_OF_CREATED_SEARCHES;
    }



    public int getMaxCountOfTermsUsedToDefineVector() {
        return MAX_COUNT_OF_TERMS_USED_TO_DEFINE_VECTOR;
    }



    public int getMaxCountOfTermsWithQuantifier() {
        return MAX_COUNT_OF_TERMS_WITH_QUANTIFIER;
    }



    public int getLimitForLocalKnowledge() {
        return LIMIT_FOR_LOCAL_KNOWLEDGE;
    }



    public int getNumberOfSearchesBeforeRepositioning() {
        return NUMBER_OF_SEARCHES_BEFORE_REPOSITIONING;
    }



    public int getTHRESHOLD() {
        return THRESHOLD;
    }



    public SearchType getSearchType() {
        return searchType;
    }



    public Distribution getDistributionForDocument() {
        return distributionForDocument;
    }



    public Distribution getDistributionForSearch() {
        return distributionForSearch;
    }



    public boolean isCluster() {
        return cluster;
    }



    @Override
    public String toString() {

        return String.format("Search Type: %20s%n", searchType) +
               String.format("Search Distr.: %14s%n", distributionForSearch) +
               String.format("Document Distr.: %12s%n", distributionForDocument) +
               String.format("Cluster: %18s%n", cluster);
    }
}
{'fraction_non_alphanumeric': 0.060013600816048965, 'fraction_numerical': 0.01292077524651479, 'mean_word_length': 2.7495219885277247, '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': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4640464', 'n_tokens_mistral': 1767, 'n_tokens_neox': 1548, 'n_words': 329}