Skip to main content

Pipelex Tools as a Python library — MTHDS lint & format, importable as `pipelex_tools`

Project description

pipelex-tools-py

Python bindings for Pipelex Tools. This package installs the importable pipelex_tools module for formatting and linting MTHDS content in-process, without shelling out to the plxt CLI.

What is MTHDS? MTHDS is an open standard for defining AI methods as typed, composable, human-readable TOML files. A .mthds file describes what an AI should do: its inputs, outputs, logic, and data types. Pipelex is the runtime that executes them.

Installation

pip install pipelex-tools-py
uv add pipelex-tools-py

Usage

import pipelex_tools

formatted = pipelex_tools.format_mthds("a=1")
print(formatted["formatted"])
# a = 1

linted = pipelex_tools.lint_mthds("""
domain = "example"

[concept]

[pipe]
""")
print(linted["diagnostics"])

API

format_mthds(content: str, *, options: dict | None = None) -> dict

Returns:

{
    "formatted": str,
    "changed": bool,
    "diagnostics": list[dict],
}

lint_mthds(content: str, *, source: str | None = None) -> dict

Returns:

{
    "diagnostics": list[dict],
}

Diagnostics use this shape:

{
    "kind": "syntax" | "semantic" | "schema",
    "severity": "error",
    "message": str,
    "location": str | None,
    "range": {
        "start_offset": int,
        "end_offset": int,
        "start_line": int,
        "start_col": int,
        "end_line": int,
        "end_col": int,
    } | None,
}

Malformed MTHDS content is returned as diagnostics, not raised as an exception. Malformed formatter option values may raise ValueError.

CLI package

This is the Python library package. To install the plxt command-line tool, use the separate pipelex-tools package:

uv tool install pipelex-tools

Links

TOML support built on Taplo.

"Pipelex" is a trademark of Evotis S.A.S.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pipelex_tools_py-0.1.1.tar.gz (114.7 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

pipelex_tools_py-0.1.1-cp38-abi3-win_amd64.whl (2.6 MB view details)

Uploaded CPython 3.8+Windows x86-64

pipelex_tools_py-0.1.1-cp38-abi3-win32.whl (2.4 MB view details)

Uploaded CPython 3.8+Windows x86

pipelex_tools_py-0.1.1-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (2.6 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.17+ x86-64

pipelex_tools_py-0.1.1-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (2.5 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.17+ ARM64

pipelex_tools_py-0.1.1-cp38-abi3-manylinux_2_12_i686.manylinux2010_i686.whl (2.7 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.12+ i686

pipelex_tools_py-0.1.1-cp38-abi3-macosx_11_0_arm64.whl (2.4 MB view details)

Uploaded CPython 3.8+macOS 11.0+ ARM64

pipelex_tools_py-0.1.1-cp38-abi3-macosx_10_12_x86_64.whl (2.5 MB view details)

Uploaded CPython 3.8+macOS 10.12+ x86-64

File details

Details for the file pipelex_tools_py-0.1.1.tar.gz.

File metadata

  • Download URL: pipelex_tools_py-0.1.1.tar.gz
  • Upload date:
  • Size: 114.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pipelex_tools_py-0.1.1.tar.gz
Algorithm Hash digest
SHA256 ec1f5e30fe666417f210a5bb1013394cef8b0c246d070037d78cf8dfcd086603
MD5 f6b439bdeb3ce98694f4f6495af22d38
BLAKE2b-256 1c7a475d5314cf2c8a402ff646ebf435ccc9d51b9d4e3c52eb063b37130e6ee5

See more details on using hashes here.

Provenance

The following attestation bundles were made for pipelex_tools_py-0.1.1.tar.gz:

Publisher: releases.yaml on Pipelex/vscode-pipelex

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pipelex_tools_py-0.1.1-cp38-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for pipelex_tools_py-0.1.1-cp38-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 a925bdc2e0ee00dde3adc9fe360e227f2968376b2ed0bbe4e14bb82014d9ac7e
MD5 1a9e921577135da686902ab3a3e4a544
BLAKE2b-256 9816aa4ad4790c29d2f7d0a9160e3fe2faf1b8be12d9dde081f989654038fc63

See more details on using hashes here.

Provenance

The following attestation bundles were made for pipelex_tools_py-0.1.1-cp38-abi3-win_amd64.whl:

Publisher: releases.yaml on Pipelex/vscode-pipelex

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pipelex_tools_py-0.1.1-cp38-abi3-win32.whl.

File metadata

File hashes

Hashes for pipelex_tools_py-0.1.1-cp38-abi3-win32.whl
Algorithm Hash digest
SHA256 b26e93fd975682b7dc15d0d300ddb540650cfdf9dff917a6e4880cc1283e83c8
MD5 315a7ecd2ef3a113493cdb159e1da311
BLAKE2b-256 8d724a68e0b3f3c758c0808a888db40299d46af1f79b23aa0c3fcc442f3a68de

See more details on using hashes here.

Provenance

The following attestation bundles were made for pipelex_tools_py-0.1.1-cp38-abi3-win32.whl:

Publisher: releases.yaml on Pipelex/vscode-pipelex

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pipelex_tools_py-0.1.1-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for pipelex_tools_py-0.1.1-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 0f89c17a9c58161ff0ff515bc7054bfc58710c9edec3d4dfc842d07966f239ba
MD5 dcc306f80aa10acdc48697e4da9464aa
BLAKE2b-256 b94f53f3e3e10391d3035bbc84966a80439277b04a9efc8cab09e890871a3cfe

See more details on using hashes here.

Provenance

The following attestation bundles were made for pipelex_tools_py-0.1.1-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: releases.yaml on Pipelex/vscode-pipelex

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pipelex_tools_py-0.1.1-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for pipelex_tools_py-0.1.1-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 902b69127df66a91f80d3b3158217ff29aa40c2ad86917b46de7e9640a6f81ab
MD5 8f00971e469f2512e3784697bbe0fcee
BLAKE2b-256 43aa31f70c2ef5b7417d0b46c3b1079f797d3d42a2fc60ceaf176a8a9d52938f

See more details on using hashes here.

Provenance

The following attestation bundles were made for pipelex_tools_py-0.1.1-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl:

Publisher: releases.yaml on Pipelex/vscode-pipelex

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pipelex_tools_py-0.1.1-cp38-abi3-manylinux_2_12_i686.manylinux2010_i686.whl.

File metadata

File hashes

Hashes for pipelex_tools_py-0.1.1-cp38-abi3-manylinux_2_12_i686.manylinux2010_i686.whl
Algorithm Hash digest
SHA256 29b818d6af5af6510bf25505acbe7d3cdca309f1443cd95299c61b0b7fd0e180
MD5 8196af8f5ad244f01e3e2905bed1fe3a
BLAKE2b-256 ea796d235117695c803946ae0fdcb5ad9410c11ed70f7182bf7a01460bf4d410

See more details on using hashes here.

Provenance

The following attestation bundles were made for pipelex_tools_py-0.1.1-cp38-abi3-manylinux_2_12_i686.manylinux2010_i686.whl:

Publisher: releases.yaml on Pipelex/vscode-pipelex

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pipelex_tools_py-0.1.1-cp38-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for pipelex_tools_py-0.1.1-cp38-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 fe07dbf840deace1fa8bebe8154fef0abb4284177aae89961437edf9bddf3257
MD5 4c8442ff250c62843a955cb5c7b10fb7
BLAKE2b-256 b04f3f28ffe46d8a31760841f29a773519794b86c3e4a1d4eec70c9b74f97282

See more details on using hashes here.

Provenance

The following attestation bundles were made for pipelex_tools_py-0.1.1-cp38-abi3-macosx_11_0_arm64.whl:

Publisher: releases.yaml on Pipelex/vscode-pipelex

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pipelex_tools_py-0.1.1-cp38-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for pipelex_tools_py-0.1.1-cp38-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 69e930881da8787259cf3040eb33b669dfb4bd4ed13c8a68f082ee284f4fa3a7
MD5 c6b16b9edda0728804a5aa66e74ebef0
BLAKE2b-256 6b51701114de4b1744dbddf37ec172ab97649177d6c7c761d75689a4b1ea6788

See more details on using hashes here.

Provenance

The following attestation bundles were made for pipelex_tools_py-0.1.1-cp38-abi3-macosx_10_12_x86_64.whl:

Publisher: releases.yaml on Pipelex/vscode-pipelex

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page