Skip to main content

Python SDK for the ACLI (Agent-friendly CLI) specification

Project description

acli-spec

Python SDK for the ACLI (Agent-friendly CLI) specification.

Build CLI tools that AI agents can discover, learn, and use autonomously.

Installation

pip install acli-spec

Quick Start

from pathlib import Path
from acli import ACLIApp, acli_command, OutputFormat
import typer

app = ACLIApp(name="myapp", version="1.0.0")

@app.command()
@acli_command(
    examples=[
        ("Run a task", "myapp run --file task.yaml"),
        ("Dry-run a task", "myapp run --file task.yaml --dry-run"),
    ],
    idempotent=False,
)
def run(
    file: Path = typer.Option(..., help="Path to task file. type:path"),
    dry_run: bool = typer.Option(False, help="Preview without executing."),
    output: OutputFormat = typer.Option(OutputFormat.text, help="Output format."),
) -> None:
    """Execute a task from a YAML file."""
    ...

if __name__ == "__main__":
    app.run()

What you get automatically

  • introspect command with full command tree as JSON
  • .cli/ folder generation (README, examples, schemas)
  • JSON error envelope on --output json
  • Semantic exit codes (0-9)
  • --version with semver output

License

EUPL-1.2

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

acli_spec-0.4.1.tar.gz (24.1 kB view details)

Uploaded Source

Built Distribution

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

acli_spec-0.4.1-py3-none-any.whl (19.9 kB view details)

Uploaded Python 3

File details

Details for the file acli_spec-0.4.1.tar.gz.

File metadata

  • Download URL: acli_spec-0.4.1.tar.gz
  • Upload date:
  • Size: 24.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for acli_spec-0.4.1.tar.gz
Algorithm Hash digest
SHA256 1b9e57e76b27e454fc95523c2422fa71a4a7eba71a98e83a83cd9dbd7ac2f2d0
MD5 f94603ad29098027a772b56524d8078e
BLAKE2b-256 f31b94fa8cad32b5b806e8de42a605ddd4e8cdc39ee1fcaee44fe6debde324c0

See more details on using hashes here.

Provenance

The following attestation bundles were made for acli_spec-0.4.1.tar.gz:

Publisher: release.yml on alpibrusl/acli

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

File details

Details for the file acli_spec-0.4.1-py3-none-any.whl.

File metadata

  • Download URL: acli_spec-0.4.1-py3-none-any.whl
  • Upload date:
  • Size: 19.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for acli_spec-0.4.1-py3-none-any.whl
Algorithm Hash digest
SHA256 55ed125e07e15d7c917ace6a7998f7c90770dbe333f85822e6df7e84dcef73f0
MD5 e3b3c2f3052d4be163d6f98e5473e615
BLAKE2b-256 84dfd7ad11ac68c8b2a19f540d337487d02425734652a436e7c0b0cabe4d11ea

See more details on using hashes here.

Provenance

The following attestation bundles were made for acli_spec-0.4.1-py3-none-any.whl:

Publisher: release.yml on alpibrusl/acli

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