// Generated by alef. Do not edit by hand.
@file:Suppress(
    "ktlint:standard:trailing-comma-on-call-site",
    "ktlint:standard:trailing-comma-on-declaration-site",
    "ktlint:standard:spacing-between-declarations-with-comments",
    "ktlint:standard:spacing-between-declarations-with-annotations",
    "ktlint:standard:when-entry-bracing",
    "ktlint:standard:blank-line-between-when-conditions",
    "ktlint:standard:blank-line-before-declaration",
    "ktlint:standard:chain-method-continuation",
    "ktlint:standard:annotation",
    "ktlint:standard:max-line-length",
    "ktlint:standard:no-semi",
    "ktlint:standard:statement-wrapping",
    "MaxLineLength",
    "TooManyFunctions",
    "FunctionParameterNaming",
    "LongParameterList",
    "CyclomaticComplexMethod",
    "LongMethod",
)

package dev.kreuzberg

import java.nio.file.Path

/**
 * Configuration for tree-sitter language pack integration.
 *
 * Controls grammar download behavior and code analysis options.
 *
 * # Example (TOML)
 *
 * ```toml
 * [tree_sitter]
 * languages = ["python", "rust"]
 * groups = ["web"]
 *
 * [tree_sitter.process]
 * structure = true
 * comments = true
 * docstrings = true
 * ```
 */
data class TreeSitterConfig(
    /**
     * Enable code intelligence processing (default: true).
     *
     * When `false`, tree-sitter analysis is completely skipped even if
     * the config section is present.
     */
    val enabled: Boolean = true,
    /**
     * Custom cache directory for downloaded grammars.
     *
     * When `null`, uses the default: `~/.cache/tree-sitter-language-pack/v{version}/libs/`.
     */
    val cacheDir: java.nio.file.Path? = null,
    /** Languages to pre-download on init (e.g., `["python", "rust"]`). */
    val languages: List<String>? = null,
    /** Language groups to pre-download (e.g., `["web", "systems", "scripting"]`). */
    val groups: List<String>? = null,
    /** Processing options for code analysis. */
    val process: TreeSitterProcessConfig = TreeSitterProcessConfig(),
)
