<commit_before>package nl.hannahsten.texifyidea.util.magic

import nl.hannahsten.texifyidea.lang.DefaultEnvironment.*

object EnvironmentMagic {

    val listingEnvironments = hashSetOf(ITEMIZE, ENUMERATE, DESCRIPTION).map { it.env }

    val tableEnvironments = hashSetOf(TABULAR, TABULAR_STAR, TABULARX, ARRAY, LONGTABLE, TABU).map { it.env }

    /**
     * Map that maps all environments that are expected to have a label to the label prefix they have by convention.
     *
     * environment name `=>` label prefix without colon
     */
    val labeled = mapOf(
            FIGURE.env to "fig",
            TABLE.env to "tab",
            EQUATION.env to "eq",
            ALGORITHM.env to "alg",
            LISTINGS.env to "lst",
            VERBATIM_CAPITAL.env to "verb",
    )

    /**
     * Environments that define their label via an optional parameter<commit_msg>Add table environments to fix #1889<commit_after>package nl.hannahsten.texifyidea.util.magic

import nl.hannahsten.texifyidea.lang.DefaultEnvironment.*

object EnvironmentMagic {

    val listingEnvironments = hashSetOf(ITEMIZE, ENUMERATE, DESCRIPTION).map { it.env }

    val tableEnvironments = hashSetOf(TABULAR, TABULAR_STAR, TABULARX, ARRAY, LONGTABLE, TABU, MATRIX, BMATRIX, PMATRIX, VMATRIX, VMATRIX_CAPITAL).map { it.env }

    /**
     * Map that maps all environments that are expected to have a label to the label prefix they have by convention.
     *
     * environment name `=>` label prefix without colon
     */
    val labeled = mapOf(
            FIGURE.env to "fig",
            TABLE.env to "tab",
            EQUATION.env to "eq",
            ALGORITHM.env to "alg",
            LISTINGS.env to "lst",
            VERBATIM_CAPITAL.env to "verb",
    )

    /**
     * Environments that define their label via an optional parameter
{'fraction_non_alphanumeric': 0.08971553610503283, 'fraction_numerical': 0.002188183807439825, 'mean_word_length': 2.680080482897384, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, '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': '5010110', 'n_tokens_mistral': 589, 'n_tokens_neox': 546, 'n_words': 163}