Build AI methods with your coding agent, then run them anywhere: as an MCP for chatbots, as a webapp for people, or via API for your software.
# =============================================================================
# PLXT Configuration
# =============================================================================
# Configures MTHDS/TOML formatting and linting behaviour for this project.
# Powered by the Pipelex extension (plxt / taplo engine).
#
# Docs: https://taplo.tamasfe.dev/configuration/
# =============================================================================
# ---------------------------------------------------------------------------
# File discovery
# ---------------------------------------------------------------------------
# Glob patterns for files to process.
include = ["**/*.toml", "**/*.mthds", "**/*.plx"]
exclude = [
".venv/**",
".mypy_cache/**",
".ruff_cache/**",
".pytest_cache/**",
"__pycache__/**",
"target/**",
"node_modules/**",
".git/**",
"*.lock",
# The `api/` workspace member's own environment and caches, which the patterns above name only at the root.
"api/.venv/**",
"api/.mypy_cache/**",
"api/.ruff_cache/**",
"api/.pytest_cache/**",
"api/site/**",
# Its vendored inference tree, which its own sync keeps byte-identical to the kit, so a reformat here
# would read as drift; the kit's copy is formatted and linted where it lives, in `pipelex/kit/`.
"api/.pipelex/inference/**",
# Its deliberately invalid sample bundles, whose faults are the point of the files.
"api/postman/sample-bundles/invalid/**",
# The MTHDS Test Corpus's schema-fault entries, and ONLY those. Every other deliberately invalid
# entry is linted like any other .mthds file in this repo: its fault needs the runtime to notice,
# so the schema has nothing to say about it and a clean lint is the correct outcome. The entries
# below are the exceptions — their fault is structural, so the schema rejects them as the very error
# they were written to trigger, and linting them would report a defect that is the entry's whole point.
#
# This list is not hand-maintained: it is gated against the corpus vocabulary's `fails_at` signal by
# tests/unit/pipelex/test_extras/test_mthds_corpus_plxt_exclusions.py, which fails if the two
# disagree. That is also what makes pipelex the signal's first consumer, and it closes the loop in
# the direction that matters — an error type mis-declared `runtime` leaves its entry linted, and
# `make plxt-lint` goes red naming it.
#
# Excluded rather than schema-exempted because a per-rule `exclude` does not lift the schema, only
# narrows which rule applies. What guards these entries instead is strictly stronger: the corpus's
# entry-validation gate runs the real validation engine over every entry in CI and is red both when
# an invalid entry fails differently and when it accidentally validates.
"**/mthds_corpus/entries/invalid_binding_step_batch_fields/*.mthds",
"**/mthds_corpus/entries/invalid_binding_step_dotted_batch_over_branch/*.mthds",
"**/mthds_corpus/entries/invalid_binding_step_dotted_batch_over_malformed/*.mthds",
"**/mthds_corpus/entries/invalid_binding_step_malformed_path/*.mthds",
"**/mthds_corpus/entries/invalid_binding_step_parallel_branch/*.mthds",
"**/mthds_corpus/entries/invalid_binding_step_pipe_and_from/*.mthds",
"**/mthds_corpus/entries/invalid_binding_step_result_not_plain/*.mthds",
"**/mthds_corpus/entries/invalid_binding_step_without_result/*.mthds",
"**/mthds_corpus/entries/invalid_input_name_batch_item_name_not_plain/*.mthds",
"**/mthds_corpus/entries/invalid_input_name_branch_batch_as_reserved/*.mthds",
"**/mthds_corpus/entries/invalid_input_name_branch_result_not_plain/*.mthds",
"**/mthds_corpus/entries/invalid_input_name_lone_dotted/*.mthds",
"**/mthds_corpus/entries/invalid_input_name_redundant_dotted/*.mthds",
"**/mthds_corpus/entries/invalid_input_name_step_batch_as_dotted/*.mthds",
"**/mthds_corpus/entries/invalid_input_name_step_result_not_plain/*.mthds",
"**/mthds_corpus/entries/invalid_missing_pipe_type/*.mthds",
"**/mthds_corpus/entries/invalid_unknown_pipe_type/*.mthds",
] # Glob patterns for files to ignore.
# These are evaluated relative to the config file location.
# =============================================================================
# Global formatting defaults
# =============================================================================
# These apply to every file matched by `include` unless overridden by a
# [[rule]].formatting section below. Every option is shown at its built-in
# default so you can tune any of them in one place.
[formatting]
align_entries = false # line up "=" signs across consecutive entries
align_comments = true # align end-of-line comments on consecutive lines
align_single_comments = true # also align lone comments (requires align_comments)
array_trailing_comma = true
array_auto_expand = true # go multiline when array exceeds column_width
array_auto_collapse = false # don't re-collapse multiline arrays that fit
inline_table_expand = true # expand inline tables exceeding column_width
compact_arrays = true # [1, 2] not [ 1, 2 ]
compact_inline_tables = false # keep spaces inside braces: { a = 1 }
compact_entries = false # keep spaces around "=": key = value
column_width = 80
indent_tables = false
indent_entries = false
indent_string = " "
trailing_newline = true
reorder_keys = false
reorder_arrays = false
reorder_inline_tables = false
allowed_blank_lines = 2
crlf = false
# =============================================================================
# Per-file-type rules
# =============================================================================
# Each [[rule]] can narrow its scope with `include` / `exclude` globs and
# provide its own [rule.formatting] overrides. Options not listed here fall
# back to the global [formatting] section above.
# ---------------------------------------------------------------------------
# Rule: TOML files
# ---------------------------------------------------------------------------
[[rule]]
# Which files this rule applies to (relative globs).
include = ["**/*.toml"]
# Per-rule formatting overrides — all at defaults so you can tweak them
# independently of .mthds files.
[rule.formatting]
# align_entries = false
# align_comments = true
# align_single_comments = true
# array_trailing_comma = true
# array_auto_expand = true
# array_auto_collapse = true
# inline_table_expand = true
# compact_arrays = true
# compact_inline_tables = false
# compact_entries = false
# column_width = 80
# indent_tables = false
# indent_entries = false
# indent_string = " "
# trailing_newline = true
# allowed_blank_lines = 2
# ---------------------------------------------------------------------------
# Rule: MTHDS files (Pipelex pipeline definitions)
# ---------------------------------------------------------------------------
[[rule]]
# Which files this rule applies to (relative globs).
include = ["**/*.mthds", "**/*.plx"]
# This repo is the source of truth for the MTHDS language: validate .mthds files
# against the locally generated schema, not the released one bundled with plxt
# (which lags behind whenever a language surface changes here).
# Generate it with: .venv/bin/pipelex-dev generate-mthds-schema
[rule.schema]
path = "derived/mthds_schema.json"
# Per-rule formatting overrides — all at defaults so you can tweak them
# independently of .toml files.
[rule.formatting]
align_entries = true
# align_comments = true
# align_single_comments = true
# array_trailing_comma = true
# array_auto_expand = true
# array_auto_collapse = true
# inline_table_expand = true
# compact_arrays = true
# compact_inline_tables = false
# compact_entries = false
# column_width = 80
# indent_tables = false
# indent_entries = false
# indent_string = " "
# trailing_newline = true
# allowed_blank_lines = 2