<commit_before># -------------------------------------------------------------------------------------------------------------
## Import Statements
# -------------------------------------------------------------------------------------------------------------
from __future__ import print_function

import sys

from .utils import get_builds, get_ggd_channels, get_species

SPECIES_LIST = sorted(get_species(update_files=False))
GENOME_BUILDS = sorted(get_builds("*"))
CHANNEL_LIST = [x.encode("ascii") for x in get_ggd_channels()]

# -------------------------------------------------------------------------------------------------------------
## Argument Parser
# -------------------------------------------------------------------------------------------------------------
def add_search(p):

    c = p.add_parser(
        "search",
        help="Search for a ggd data package",
        description="Search for available ggd data packages. Results are filtered by match score from high to low. (Only 5 results will be reported unless the -dn flag is changed)",
    )
    c.add_argument(
        "search_term",
        nargs="+",
        help="**Required** The term(s) to search for. Multiple terms can be used. Example: 'ggd search reference genome'",
    )
    c.add_argument(
        "--search-type",
        default = "both",
        choices = ["both", "combined-only", "non-combined-only"],
        help = ("(Optional) How to search for data packages with the search terms provided. Options = 'combined-only', 'non-combined-only', and 'both'."
                " 'combined-only' will use the provided search terms as a single search term. 'non-combined-only' will use the provided search to search for"
                " data package that match each search term separately. 'both' will use the search terms combined and each search term separately to search"
                " for data packages. Default = 'both'")
    )
    c.add_argument(
        "-g",
        "--genome-build",
        default=[],
        action="append",
        choices=[str(x) for x in GENOME_BUILDS],
        help="(Optional) Filter results by the genome build of the desired recipe",
    )
    c.add_argument(
        "-s",
        "--species",
        default=[],
        action="append",
        help="(Optional) Filter results by the species for the desired recipe",
        choices=[str(x) for x in SPECIES_LIST],
    )
    c.add_argument(
        "-dn",
        "--display-number",<commit_msg>Fix detail<commit_after># -------------------------------------------------------------------------------------------------------------
## Import Statements
# -------------------------------------------------------------------------------------------------------------
from __future__ import print_function

import sys

from .utils import get_builds, get_ggd_channels, get_species

SPECIES_LIST = sorted(get_species(update_files=False))
GENOME_BUILDS = sorted(get_builds("*"))
CHANNEL_LIST = [x.encode("ascii") for x in get_ggd_channels()]

# -------------------------------------------------------------------------------------------------------------
## Argument Parser
# -------------------------------------------------------------------------------------------------------------
def add_search(p):

    c = p.add_parser(
        "search",
        help="Search for a ggd data package",
        description="Search for available ggd data packages. Results are filtered by match score from high to low. (Only 5 results will be reported unless the -dn flag is changed)",
    )
    c.add_argument(
        "search_term",
        nargs="+",
        help="**Required** The term(s) to search for. Multiple terms can be used. Example: 'ggd search reference genome'",
    )
    c.add_argument(
        "--search-type",
        default = "both",
        choices = ["both", "combined-only", "non-combined-only"],
        help = ("(Optional) How to search for data packages with the search terms provided. Options = 'combined-only', 'non-combined-only', and 'both'."
                " 'combined-only' will use the provided search terms as a single search term. 'non-combined-only' will use the provided search term to search for"
                " data package that match each search term separately. 'both' will use the search terms combined and each search term separately to search"
                " for data packages. Default = 'both'")
    )
    c.add_argument(
        "-g",
        "--genome-build",
        default=[],
        action="append",
        choices=[str(x) for x in GENOME_BUILDS],
        help="(Optional) Filter results by the genome build of the desired recipe",
    )
    c.add_argument(
        "-s",
        "--species",
        default=[],
        action="append",
        help="(Optional) Filter results by the species for the desired recipe",
        choices=[str(x) for x in SPECIES_LIST],
    )
    c.add_argument(
        "-dn",
        "--display-number",
{'fraction_non_alphanumeric': 0.2702702702702703, 'fraction_numerical': 0.0004033884630899556, 'mean_word_length': 1.4907081868407834, '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': '860287', 'n_tokens_mistral': 1187, 'n_tokens_neox': 1166, 'n_words': 407}